Alex Crichton
daf5f5a4d1
Drop the '2' suffix from logging macros
...
Who doesn't like a massive renaming?
2013-10-22 08:09:56 -07:00
bors
3f240fedec
auto merge of #9926 : Kimundi/rust/future_result_bad_sig, r=huonw
2013-10-18 06:11:18 -07:00
Marvin Löbel
3011801256
Made std::task::TaskBuilder::future_result() easier to use
2013-10-18 10:43:41 +02:00
Brian Anderson
34d376f3cf
std: Move size/align functions to std::mem. #2240
2013-10-17 17:31:35 -07:00
Daniel Micay
ac1faba4df
make small ty_struct immediate
...
Closes #9651
2013-10-08 07:11:08 -04:00
Alex Crichton
a8ba31dbf3
std: Remove usage of fmt!
2013-09-30 23:21:18 -07:00
Alex Crichton
817576ee70
Register new snapshots
2013-09-18 11:07:22 -07:00
Daniel Micay
4e161a4d40
switch Drop to &mut self
2013-09-16 22:19:23 -04:00
Daniel Micay
05bb4c4e1b
reduce the size of UnsafeArc from 2 words to 1
2013-08-29 20:29:02 -04:00
Patrick Walton
8693943676
librustc: Ensure that type parameters are in the right positions in paths.
...
This removes the stacking of type parameters that occurs when invoking
trait methods, and fixes all places in the standard library that were
relying on it. It is somewhat awkward in places; I think we'll probably
want something like the `Foo::<for T>::new()` syntax.
2013-08-27 18:47:57 -07:00
Huon Wilson
a79575529d
std: use ArcData rather than c_void in UnsafeArc.
...
This means that fewer `transmute`s are required, so there is less
chance of a `transmute` not having the corresponding `forget`
(possibly leading to use-after-free, etc).
2013-08-27 22:24:34 +10:00
Huon Wilson
71448d7c37
Rename UnsafeAtomicRcBox to UnsafeArc. Fixes #7674 .
2013-08-27 20:12:39 +10:00
Brian Anderson
4c75d36d0e
std: Reduce TLS access
2013-08-23 21:19:59 -07:00
Vadim Chugunov
12ecdb6381
Enabled unit tests in std and extra.
2013-08-22 20:02:20 -07:00
Niko Matsakis
0479d946c8
Add externfn macro and correctly label fixed_stack_segments
2013-08-19 07:13:15 -04:00
Kevin Ballard
418e1ebae6
Reserve 'yield' keyword
...
Rename task::yield() to task::deschedule().
Fixes #8494 .
2013-08-16 13:26:50 -07:00
Ben Blum
ee5cfb0c2d
Don't use unkillable in UnsafeArc dtor when there's no unwrapper. Close #8382 .
2013-08-12 13:19:17 -04:00
Brian Anderson
b75915d0ca
Remove the C++ runtime. Sayonara
2013-08-09 16:45:50 -07:00
Brian Anderson
d392556160
std: Fix perf of local allocations in newsched
...
Mostly optimizing TLS accesses to bring local heap allocation performance
closer to that of oldsched. It's not completely at parity but removing the
branches involved in supporting oldsched and optimizing pthread_get/setspecific
to instead use our dedicated TCB slot will probably make up for it.
2013-08-09 01:15:31 -07:00
Daniel Micay
1008945528
remove obsolete foreach keyword
...
this has been replaced by `for`
2013-08-03 22:48:02 -04:00
bors
986df44753
auto merge of #8195 : bblum/rust/task-cleanup, r=brson
...
In the first commit it is obvious why some of the barriers can be changed to ```Relaxed```, but it is not as obvious for the once I changed in ```kill.rs```. The rationale for those is documented as part of the documenting commit.
Also the last commit is a temporary hack to prevent kill signals from being received in taskgroup cleanup code, which could be fixed in a more principled way once the old runtime is gone.
2013-08-02 07:31:52 -07:00
Daniel Micay
234acad404
replace range with an external iterator
2013-08-02 00:51:14 -04:00
Ben Blum
880246618b
Relax some atomic barriers. Loosen up all that tension. There, doesn't that feel good?
2013-08-01 16:52:37 -04:00
blake2-ppc
78cde5b9fb
std: Change Times trait to use do instead of for
...
Change the former repetition::
for 5.times { }
to::
do 5.times { }
.times() cannot be broken with `break` or `return` anymore; for those
cases, use a numerical range loop instead.
2013-08-01 16:54:22 +02:00
bors
18d124b9b5
auto merge of #8158 : bblum/rust/task-cleanup, r=brson
...
r? @brson
2013-08-01 06:01:39 -07:00
Daniel Micay
1fc4db2d08
migrate many for loops to foreach
2013-08-01 05:34:55 -04:00
Ben Blum
bc7cee7bbf
Move atomically to unstable::sync, and document what it actually does. Close #7872 .
2013-07-31 14:37:22 -04:00
Ben Blum
6b75e92afe
UnsafeArc methods return unsafe pointers, so are not themselves unsafe.
2013-07-30 13:19:26 -04:00
Ben Blum
cccfa8acc4
Add test cases for select
2013-07-30 13:19:25 -04:00
Ben Blum
f34fadd126
Implement select() for new runtime pipes.
2013-07-30 13:19:25 -04:00
Steven Stewart-Gallus
39b3a0561f
Fix nits.
2013-07-27 22:06:29 -07:00
Steven Stewart-Gallus
d0b7515aed
Change concurrency primitives to standard naming conventions
...
To be more specific:
`UPPERCASETYPE` was changed to `UppercaseType`
`type_new` was changed to `Type::new`
`type_function(value)` was changed to `value.method()`
2013-07-27 22:06:29 -07:00
Ben Blum
621bc79d0d
Fix warnings in stdtest and extratest. Maybe somebody will care.
2013-07-20 05:12:05 -04:00
Ben Blum
2a7273c71e
Stash a spare kill flag inside tasks, to save two atomic xadds in the blocking fastpath.
2013-07-20 05:08:57 -04:00
Ben Blum
52ca256d7b
Add KillHandle and implement exit code propagation to replace join_latch
2013-07-20 05:08:56 -04:00
Ben Blum
2a99163f5d
Add UnsafeAtomicRcBox::try_unwrap()
2013-07-20 05:08:55 -04:00
Ben Blum
10a400ffaa
Reimplement ARC::unwrap() and friends.
2013-07-20 05:08:55 -04:00
Ben Blum
28c9ba91d8
Remove redundant Atomic{Ui,I}nt types from unstable::sync
2013-07-20 05:08:55 -04:00
Brian Anderson
1098d6980b
Merge remote-tracking branch 'mozilla/master'
...
Conflicts:
src/libextra/test.rs
src/libstd/at_vec.rs
src/libstd/cleanup.rs
src/libstd/rt/comm.rs
src/libstd/rt/global_heap.rs
src/libstd/task/spawn.rs
src/libstd/unstable/lang.rs
src/libstd/vec.rs
src/rt/rustrt.def.in
src/test/run-pass/extern-pub.rs
2013-07-03 14:49:13 -07:00
Patrick Walton
1c0aa78481
librustc: Change "Owned" to "Send" everywhere
2013-06-28 10:44:15 -04:00
Luqman Aden
ca2966c6d0
Change finalize -> drop.
2013-06-25 21:14:39 -04:00
Daniel Micay
d2e9912aea
vec: remove BaseIter implementation
...
I removed the `static-method-test.rs` test because it was heavily based
on `BaseIter` and there are plenty of other more complex uses of static
methods anyway.
2013-06-23 02:05:20 -04:00
Brian Anderson
357f087786
Merge remote-tracking branch 'brson/io' into io-upstream
...
Conflicts:
src/rt/rust_builtin.cpp
src/rt/rustrt.def.in
2013-06-20 12:17:00 -07:00
Graydon Hoare
d904c72af8
replace #[inline(always)] with #[inline]. r=burningtree.
2013-06-18 14:48:48 -07:00
Brian Anderson
319cf6e465
Merge remote-tracking branch 'brson/io'
...
Conflicts:
src/libstd/rt/comm.rs
src/libstd/rt/mod.rs
src/libstd/rt/sched.rs
src/libstd/rt/task.rs
src/libstd/rt/test.rs
src/libstd/rt/tube.rs
src/libstd/rt/uv/uvio.rs
src/libstd/rt/uvio.rs
src/libstd/task/spawn.rs
2013-06-16 15:09:25 -07:00
Patrick Walton
5fb254695b
Remove all uses of pub impl. rs=style
2013-06-01 09:18:27 -07:00
Patrick Walton
206ab89629
librustc: Stop reexporting the standard modules from prelude.
2013-05-29 19:04:53 -07:00
Brian Anderson
f4ed554ddb
Merge remote-tracking branch 'brson/io' into incoming
...
Conflicts:
src/libstd/rt/sched.rs
2013-05-29 18:22:28 -07:00
Patrick Walton
0c820d4123
libstd: Rename libcore to libstd and libstd to libextra; update makefiles.
...
This only changes the directory names; it does not change the "real"
metadata names.
2013-05-22 21:57:05 -07:00