Commit graph

103 commits

Author SHA1 Message Date
Niko Matsakis
6a8cb704d9 get basic code generation working, clone type descs for lambda[send] 2011-12-14 14:32:20 -08:00
Brian Anderson
1974cf9a81 rt: Move RED_ZONE_SIZE to rust_task.cpp 2011-12-01 15:50:00 -08:00
Brian Anderson
9675343dc9 rt: Fix i386/morestack.S for static linking 2011-11-29 13:47:54 -08:00
Brian Anderson
a9967423f8 rt: Make 64-bit __morestack grow and shrink properly 2011-11-28 21:57:52 -08:00
Brian Anderson
6bdf347418 rt: Make __morestack (without unwinding) work on 32-bit linux 2011-11-22 18:02:10 -08:00
Brian Anderson
5d1e321ecb rt: Remove rust_chan 2011-11-11 12:11:21 -08:00
Brian Anderson
371574f64b rt: Remove rust_token. Unused 2011-11-10 17:35:21 -08:00
Brian Anderson
061d2c2f77 Make task_sleep an intrinsic. 2011-11-08 15:58:08 -08:00
Niko Matsakis
8011e3fabb hack around on makefiles trying to get a 64 bit build
right now there are many temporary hacks, search for NDM to find them
2011-11-02 14:13:22 -07:00
Marijn Haverbeke
8124846b2c Get rid of taskpointer-passing throughout the compiler
Only intrinsics still take a dummy taskptr. We'll have to do some
makefile stunts to snapshot a version without taskptrs-in-intrinsics.

Issue #466
2011-10-20 14:22:17 +02:00
Marijn Haverbeke
457683c7fe Do not pass taskpointers to "rust" native functions
Issue #466
2011-10-20 14:22:17 +02:00
Patrick Walton
a7b44e847a rt: Make the builtins no longer take an explicit task parameter 2011-10-03 18:23:30 -07:00
Patrick Walton
61afef29a1 rt: Add a RUST_TRACK_ORIGINS debug flag to help track down memory corruption 2011-09-23 11:42:20 -07:00
Brian Anderson
dbd2ee015a Remove is_stateful flag from tydesc. Closes #136 2011-09-22 22:15:25 -07:00
Brian Anderson
0ea55ffdc8 Use a unique exit status when the runtime fails normally
Check for it in run-fail tests
2011-09-11 17:31:40 -07:00
Brian Anderson
72c14d5a41 Eliminate const_refcount. Issue #855 2011-09-02 15:13:41 -07:00
Marijn Haverbeke
458ac89894 Back out copy-glue
This wasn't a good idea after all.
2011-09-01 22:37:23 +02:00
Patrick Walton
880fd788eb rustc: Add an extra flag to object tydescs so that shapes know how to find the captured subtydescs 2011-08-25 12:01:10 -07:00
Marijn Haverbeke
fa97793139 Revert "Back out copy-glue"
This reverts commit 629ee94a0b.
2011-08-24 20:30:20 +02:00
Marijn Haverbeke
629ee94a0b Back out copy-glue
This wasn't a good idea after all.
2011-08-24 17:05:53 +02:00
Marijn Haverbeke
cd5e4c21ee Add skeleton of copy glue that actually copies 2011-08-22 11:41:49 +02:00
Marijn Haverbeke
7588a89553 Rename copy_glue back to take_glue 2011-08-22 10:42:56 +02:00
Patrick Walton
0fedea39ce rt: Remove rust_alarm dead code 2011-08-18 18:21:03 -07:00
Michael Sullivan
eb368d1b34 Remove rc_base. Closes #603. 2011-08-18 15:49:58 -07:00
Eric Holk
8686645aad New channel-based task status notifications. 2011-08-16 16:47:40 -07:00
Eric Holk
cf2def46c1 Removed trans_comm.rs from the compiler. Updating aio/sio to work with the new chan and port system, started on a networking module for the standard library. 2011-08-16 09:36:29 -07:00
Eric Holk
5c6790519b Reducing the chances for race conditions in join. 2011-08-15 12:39:55 -07:00
Eric Holk
2f23405a60 Working on more spawn test cases. 2011-08-15 09:26:51 -07:00
Eric Holk
04af99ecb0 First step towards port handles. 2011-08-15 09:26:51 -07:00
unknown
44bef5f2cb Introduced task handles.
This is the new way to refer to tasks in rust-land. Currently all they
do is serve as a key to look up the old rust_task structure. Ideally
they won't be ref counted, but baby steps.
2011-08-08 16:55:38 -07:00
Eric Holk
b62e80c1f0 Atomic ref counting for chans. 2011-08-05 15:27:28 -07:00
Patrick Walton
e351ad762d rt: Stub shape glue and implement shape::print and shape::size_of. 2011-08-03 20:25:44 -07:00
Eric Holk
286be2d94e Adding an intrinsic for recv. 2011-08-01 18:43:05 -07:00
Eric Holk
d1dbb99984 Removing proxies and message queues. 2011-07-29 18:54:59 -07:00
Brian Anderson
4ef1ec580a Do all runtime calls to getenv at initialization
getenv is not threadsafe and (maybe as a result) it's randomly crashing with
CFLAGS=-g and RUST_THREADS=32. Calls from rust code are still on their
own.
2011-07-28 12:23:01 -07:00
Eric Holk
3ae4dcd41e Lots of work on memory tracking and channels.
We're trying to get closer to doing correct move semantics for channel
operations. This involves a lot of cleanup (such as removing the
unused sched parameter from rust_vec constructor) and making
circular_buffer kernel_owned.

Added tagging for memory allocations. This means we give a string tag
to everything we allocate. If we leak something and TRACK_ALLOCATIONS
is enabled, then it's much easier now to tell exactly what is leaking.
2011-07-21 11:51:22 -07:00
Graydon Hoare
49116adbe9 Fix compile-command lines in rt. 2011-07-13 13:51:20 -07:00
Eric Holk
5d9a5b7d55 Tightened up the scoping for our various new operators, which should
make it harder to use the wrong one.
2011-07-07 18:22:27 -07:00
Rob Arnold
02a5949aba Add macro for refcounting runtime structures.
The macro with the extra dtor parameter is intended for structures like
rust_chan which may not necessarily delete themselves when the ref count
becomes 0. This functionality will be used in an upcoming changeset.
2011-07-01 16:59:10 -07:00
Patrick Walton
dfcfef41df rustc: Rename take glue to copy glue 2011-06-28 16:52:59 -07:00
Eric Holk
f6f8a06d6b Resurrecting the runtime unit tests, and modifying them so they compile under the latest refactoring changes. 2011-06-28 16:12:34 -07:00
Eric Holk
657e5a2bd5 Renamed what's left of rust_dom to rust_scheduler 2011-06-28 16:12:33 -07:00
Eric Holk
49a8cb34d2 Removed dom_owned, splitting things between task_owned and kernel_owned. Had to re-xfail a few tests brson recently un-xfailed. 2011-06-28 16:12:33 -07:00
Eric Holk
1c852ac9c0 Removing runtime tests. The runtime is tested well enough by the standard library tests, so we might as well have less code to fix during refactoring. 2011-06-28 16:12:33 -07:00
Michael Sullivan
ccd1bcf7a7 Make tydesc glue functions use cdecl. 2011-06-14 16:09:21 -07:00
Michael Sullivan
491d110645 Make type_desc fields have useful types and better names. Add in cmp_glue. 2011-06-14 15:35:08 -07:00
Eric Holk
d1857d30fc This is the mega-ucontext commit. It replaces the task switching mechanism with a new one inspired by ucontext. It works under Linux, OS X and Windows, and is Valgrind clean on Linux and OS X (provided the runtime is built with gcc).
This commit also moves yield and join to the standard library, as requested in #42. Join is currently a no-op though.
2011-06-13 18:14:13 -07:00
Graydon Hoare
79c9e13073 More delicious dead code removal from runtime, upcalls. 2011-05-26 18:21:02 -07:00
Rafael Ávila de Espíndola
db47cb5c13 Dead code. 2011-05-25 15:22:25 -04:00
Rafael Ávila de Espíndola
0e324cad0a Dead code. 2011-05-25 15:08:31 -04:00