summary refs log tree commit diff
path: root/src/libstd/rt
AgeCommit message (Collapse)AuthorLines
2013-07-19Changed methods on UDP sockets and TCP/UDP watchers to &mut self to reflect ↵Eric Reed-64/+65
that libuv may change the underlying handle.
2013-07-18auto merge of #7854 : brson/rust/rt-test-threads, r=pcwaltonbors-1/+1
2013-07-17test: Fix tests.Patrick Walton-3/+3
2013-07-17test: Fix tests.Patrick Walton-1/+1
2013-07-17librustc: Remove all uses of "copy".Patrick Walton-8/+10
2013-07-17std::rt: Rename RUST_TEST_THREADS to RUST_RT_TEST_THREADSBrian Anderson-1/+1
2013-07-16Rename Option swap_unwrap to take_unwrap. Fixes Issue#7764Austin King-15/+15
2013-07-15remove headers from unique vectorsDaniel Micay-8/+0
2013-07-14Make TLS keys actually take up spaceAlex Crichton-2/+2
If the TLS key is 0-sized, then the linux linker is apparently smart enough to put everything at the same pointer. OSX on the other hand, will reserve some space for all of them. To get around this, the TLS key now actuall consumes space to ensure that it gets a unique pointer
2013-07-14Purge the last remnants of the old TLS apiAlex Crichton-8/+6
Closes #3273
2013-07-11auto merge of #7677 : alexcrichton/rust/tls-gc, r=pcwaltonbors-6/+6
cc #6004 and #3273 This is a rewrite of TLS to get towards not requiring `@` when using task local storage. Most of the rewrite is straightforward, although there are two caveats: 1. Changing `local_set` to not require `@` is blocked on #7673 2. The code in `local_pop` is some of the most unsafe code I've written. A second set of eyes should definitely scrutinize it... The public-facing interface currently hasn't changed, although it will have to change because `local_data::get` cannot return `Option<T>`, nor can it return `Option<&T>` (the lifetime isn't known). This will have to be changed to be given a closure which yield `&T` (or as an Option). I didn't do this part of the api rewrite in this pull request as I figured that it could wait until when `@` is fully removed. This also doesn't deal with the issue of using something other than functions as keys, but I'm looking into using static slices (as mentioned in the issues).
2013-07-11Remove all external requirements of `@` from TLSAlex Crichton-2/+2
Closes #6004
2013-07-11Work around stage0 to remove '@' requirements from TLSAlex Crichton-5/+5
2013-07-09auto merge of #7265 : brson/rust/io-upstream, r=brsonbors-1571/+5074
r? @graydon, @nikomatsakis, @pcwalton, or @catamorphism Sorry this is so huge, but it's been accumulating for about a month. There's lots of stuff here, mostly oriented toward enabling multithreaded scheduling and improving compatibility between the old and new runtimes. Adds task pinning so that we can create the 'platform thread' in servo. [Here](https://github.com/brson/rust/blob/e1555f9b5628af2b6c6ed344cad621399cb7684d/src/libstd/rt/mod.rs#L201) is the current runtime setup code. About half of this has already been reviewed.
2013-07-09Change the elements in the task-local map to be actual key-value pairsAlex Crichton-1/+1
2013-07-09std::rt: Ignore 0-byte udp readsBrian Anderson-0/+7
2013-07-09std::rt: Do local tests in a bare thread to not interfere with the schedulerBrian Anderson-21/+30
2013-07-09remove the unused exchange_malloc `align` parameterDaniel Micay-2/+2
`malloc` already returns memory correctly aligned for every possible type in standard C, and that's enough for all types in Rust too
2013-07-09std: Make os::set_exit_status work with newschedBrian Anderson-1/+31
2013-07-09std::rt: size_t, not u64Brian Anderson-2/+2
2013-07-08TidyBrian Anderson-10/+14
2013-07-08Merge remote-tracking branch 'mozilla/master'Brian Anderson-11/+7
Conflicts: src/libextra/test.rs src/libstd/rt/global_heap.rs src/libstd/unstable/lang.rs src/libstd/vec.rs
2013-07-08Merge remote-tracking branch 'anasazi/io'Brian Anderson-686/+1512
Conflicts: src/libstd/rt/test.rs
2013-07-08std::rt: Add a hack to allocate different test port ranges to different botsBrian Anderson-2/+44
2013-07-08changed .each() to .iter().advance()Eric Reed-10/+10
2013-07-08renamed finalize to drop in Drop impl for UvUdpSocketEric Reed-1/+1
2013-07-08Merge remote-tracking branch 'upstream/io' into ioEric Reed-117/+145
Conflicts: src/libstd/rt/uvio.rs
2013-07-08remove headers from exchange allocationsDaniel Micay-3/+2
2013-07-08add a temporary vector_exchange_malloc lang itemDaniel Micay-0/+8
2013-07-03Merge remote-tracking branch 'mozilla/master'Brian Anderson-121/+148
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-04Convert vec::{as_imm_buf, as_mut_buf} to methods.Huon Wilson-1/+2
2013-07-02converted TODOs into XXXsEric Reed-8/+7
2013-07-02Merge remote-tracking branch 'upstream/io' into ioEric Reed-555/+377
Conflicts: src/libstd/rt/test.rs src/rt/rustrt.def.in
2013-07-02IPv6 support for UDP and TCP.Eric Reed-131/+768
2013-07-02A missing ! made it so that the testcase schedule_home_states was throwing ↵toddaaro-1/+1
spurious assert failures. Why this did not result in the test case failing previously is beyond me.
2013-07-01removed unnecessary import that slipped in during mergetoddaaro-1/+0
2013-07-01merging task/coroutine refactoring back into upstreamtoddaaro-19/+18
2013-07-01Refactored the runtime to view coroutines as a component of tasks, instead ↵toddaaro-542/+362
of tasks as a component of coroutines.
2013-06-30pass exchange_malloc an alignment, not a tydescDaniel Micay-7/+2
2013-06-30global_heap: inline get_box_size and align_toDaniel Micay-0/+2
2013-06-30global_heap: inline malloc_raw and add realloc_rawDaniel Micay-1/+13
2013-06-30add a closure_exchange_malloc lang itemDaniel Micay-0/+14
this makes the exchange allocation header completely unused, and leaves it uninitialized
2013-06-30stop initializing ref_count in exchange_allocDaniel Micay-1/+21
this is never read anymore
2013-06-30simplify the exchange allocatorDaniel Micay-53/+41
* stop using an atomic counter, this has a significant cost and valgrind will already catch these leaks * remove the extra layer of function calls * remove the assert of non-null in free, freeing null is well defined but throwing a failure from free will not be * stop initializing the `prev`/`next` pointers * abort on out-of-memory, failing won't necessarily work
2013-06-28librustc: Disallow "mut" from distributing over bindings.Patrick Walton-2/+5
This is the backwards-incompatible part of per-binding-site "mut".
2013-06-28librustc: Change "Owned" to "Send" everywherePatrick Walton-9/+9
2013-06-28std: silence some test warnings.Huon Wilson-2/+2
2013-06-28Convert vec::{reserve, reserve_at_least, capacity} to methods.Huon Wilson-1/+1
2013-06-27Convert vec::[mut_]slice to methods, remove vec::const_slice.Huon Wilson-2/+2
2013-06-26std::rt: Some cleanupBrian Anderson-20/+18