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