summary refs log tree commit diff
path: root/src/rt/rust_uv.cpp
AgeCommit message (Collapse)AuthorLines
2012-04-03rt: alloca is spelled differently on win32Brian Anderson-0/+4
2012-04-03rt: Fix the 0 bytes lost issueBrian Anderson-0/+16
This is a workaround for #1815. libev uses realloc(0) to free the loop, which valgrind doesn't like. We have suppressions to make valgrind ignore them. Valgrind also has a sanity check when collecting allocation backtraces that the stack pointer must be at least 512 bytes into the stack (at least 512 bytes of frames must have come before). When this is not the case it doesn't collect the backtrace. Unfortunately, with our spaghetti stacks that valgrind check triggers sometimes and we don't get the backtrace for the realloc(0), it fails to be suppressed, and it gets reported as 0 bytes lost from a malloc with no backtrace. This fixes the issue by alloca'ing 512 bytes before calling uv_loop_delete
2012-04-03Refactor includes structure, getting rid of rust_internal.hJon Morton-1/+3
Many changes to code structure are included: - removed TIME_SLICE_IN_MS - removed sychronized_indexed_list - removed region_owned - kernel_owned move to kernel.h, task_owned moved to task.h - global configs moved to rust_globals.h - changed #pragma once to standard guard in rust_upcall.h - got rid of memory.h
2012-04-02Add global rust_get_current_taskJon Morton-2/+2
Previously two methods existed: rust_sched_loop::get_task and rust_task::get_task_from_tcb. Merge both of them into one, trying the faster one (tcb) first, and if that fails, the slower one from the tls.
2012-04-01Merge remote-tracking branch 'brson/mainthread'Brian Anderson-2/+2
Conflicts: src/rt/rust_sched_loop.cpp src/rt/rust_shape.cpp src/rt/rust_task.cpp
2012-03-31rt: Fix whitespaceBrian Anderson-53/+53
2012-03-31rt: Rename rust_task_thread to rust_sched_loopBrian Anderson-2/+2
This class no longer represents a thread; it just schedules tasks.
2012-02-28add uv::loop_delete()Jeff Olson-2/+8
because of the last change, the loop ptr is no longer cleaned up when the loop exits. This api call addresses that. Sadly, the loop ptr is not "reusable" across multiple calls to uv::run().
2012-02-28correcting for libuv behavior that differs between linux & windowsJeff Olson-16/+2
net complexity increase :/
2012-02-28moving new uv stuff into uv.rs and rust_uv.cppJeff Olson-27/+159
- removing the remains of uvtmp.rs and rust_uvtmp.rs - removing the displaced, low-level libuv bindings in uv.rs and rust_uv.cpp
2012-01-22std: Add some hacks to use libuvBrian Anderson-0/+1
2011-12-01stdlib: Implement some preliminary libuv bindingsBrian Anderson-0/+50
std::uv is intended to be low-level, exactly mirroring the C API. Difficult to continue the implementation now without scheduler improvements.
2011-11-07Rename rust_uv.cpp to rust_aio.cppBrian Anderson-325/+0
2011-10-04rt: Switch the AIO stuff to the C stackPatrick Walton-18/+16
2011-10-03rt: Switch the libuv bindings over to not using explicit task pointersPatrick Walton-17/+27
2011-10-03rt: Fix comment typo in rust_uv.cppPatrick Walton-1/+1
2011-09-23Update to libuv commit 3ca382.Erick Tryzelaar-43/+35
This patch changes libuv's gyp build system to make it's own makefiles. To generate them for rust, run these commands. They requires python 2.x to work: $ mkdir -p src/rt/libuv/build $ svn co http://gyp.googlecode.com/svn src/rt/libuv/build/gyp $ ./etc/src/gyp_uv
2011-08-29Implement non-internal ivecsMarijn Haverbeke-12/+9
Vectors are now similar to our old, pre-internal vectors, except that they are uniquely owned, not refcounted. Their name should probably change too, then. I've renamed them to vec in the runtime, will do so throughout the compiler later.
2011-08-16Removed trans_comm.rs from the compiler. Updating aio/sio to work with the ↵Eric Holk-6/+26
new chan and port system, started on a networking module for the standard library.
2011-08-05Fix uv_buf_t declaration on win32Brian Anderson-0/+8
The fields of this structure are mysteriously defined in the opposite order on windows as on unix
2011-08-05Update libuv to revision ee599ec1141cc48f895de1f9d148033babdf9c2aRob Arnold-15/+15
2011-08-05Basic async IO module using libuvRob Arnold-0/+300