Brian Anderson
8693fcc2d7
rt: Remove yield timers
2012-02-02 18:10:24 -08:00
Niko Matsakis
196d69beb2
make boxes self-describing ( fixes #1493 )" (take 2)
...
this will be used to generate a new snapshot.
2012-02-01 18:52:08 -08:00
Niko Matsakis
3116643806
Revert "make boxes self-describing ( fixes #1493 )" until a new
...
snapshot is prepared.
2012-02-01 18:50:19 -08:00
Niko Matsakis
c36207bfb8
make boxes self-describing ( fixes #1493 )
2012-02-01 18:18:07 -08:00
Brian Anderson
4eb92d4177
rt: Don't access fields on null supervisor task
2012-02-01 16:46:11 -08:00
Brian Anderson
fa13fd9d64
rt: Remove set_min_stack
2012-01-29 21:27:37 -08:00
Brian Anderson
6548cdd59b
rt: Make the initial segment of the main task's stack 1MB
...
This is a trick to fool microbenchmarks. Closes #1681
2012-01-29 21:20:39 -08:00
Brian Anderson
94c389a25b
rt: Add RUST_MAX_STACK env var with 8MB default
...
Closes #1489
2012-01-11 13:57:11 -08:00
Niko Matsakis
110c3ccdca
add rust_task_is_unwinding predicate and do not kill if already unwinding
2012-01-09 19:53:32 -08:00
Brian Anderson
7e8974305c
rt: Set Linux red zone to 20K again
...
With runtime logging on it smashes the stack
2012-01-09 11:44:36 -08:00
Niko Matsakis
8506241f3a
fix how we walk functions to match new closure fmt
2012-01-06 22:40:31 -08:00
Niko Matsakis
25e81e34ea
rewrite task tests
2012-01-06 22:40:31 -08:00
Niko Matsakis
98f5109cde
simplify task impl
2012-01-06 22:40:31 -08:00
Brian Anderson
4632358cbc
Revert "rt: Reduce mac red zone to 6K"
...
This reverts commit d499e739a1
.
2012-01-06 18:16:19 -08:00
Brian Anderson
d499e739a1
rt: Reduce mac red zone to 6K
2012-01-06 16:42:26 -08:00
Brian Anderson
2f4c9315af
rt: Fail the scheduler immediately on task failure in win32
2012-01-06 16:18:56 -08:00
User Jyyou
a59c4b1b47
freebsd support
2012-01-01 20:18:55 -08:00
Brian Anderson
dedfef4c4c
Revert "wip"
...
This reverts commit aeadc6269e
.
2011-12-20 20:57:04 -08:00
Brian Anderson
aeadc6269e
wip
2011-12-20 20:15:09 -08:00
Brian Anderson
128621be97
rt: Remove rust_task::grow. Obsolete
2011-12-20 20:02:57 -08:00
Brian Anderson
cab4da70c8
rt: Don't check the stack canary on most upcalls
2011-12-20 16:50:54 -08:00
Brian Anderson
2a490d1cf8
Revert "rt: Reduce the mac red zone to 2K"
...
This reverts commit ba8f369f89
.
2011-12-20 15:17:30 -08:00
Brian Anderson
ba8f369f89
rt: Reduce the mac red zone to 2K
2011-12-20 14:24:13 -08:00
Brian Anderson
2e230b1cf9
rt: Reduce the linux red zone to 2K
2011-12-20 14:02:59 -08:00
Brian Anderson
93fef2e113
rt: Parenthesize the red zone macros
2011-12-20 11:57:22 -08:00
Brian Anderson
784713ec68
rt: Add a canary value to the end of every stack
...
Check it on upcall entry and exit, and on stack deletion
2011-12-20 11:48:47 -08:00
Brian Anderson
56ec9cb278
rt: Run yet more task_start_wrapper cleanup on the C stack
2011-12-20 10:29:40 -08:00
Brian Anderson
25f7c844df
rt: Don't reuse stack segments when they are not big enough
2011-12-19 22:47:28 -08:00
Brian Anderson
bd6b80c972
rt: Get rid of the rethrow in upcall_fail
...
Throwing in upcall_fail ends up running lots of code in the red zone. To avoid
it we have the personality function figure out which stack it's on and switch
as needed.
2011-12-18 17:17:31 -08:00
Brian Anderson
f57fd8de1f
rt: Run the cycle collector on the C stack
2011-12-18 15:23:44 -08:00
Brian Anderson
74d5faa86e
rt: Give each platform its own red zone definition
2011-12-18 15:23:41 -08:00
Brian Anderson
762d7e43a6
rt: Trim the red zone to 20k on all platforms
2011-12-18 15:22:56 -08:00
Brian Anderson
3fa930f598
rt: Remove a bogus FIXME from ~rust_task
2011-12-18 02:09:41 -08:00
Brian Anderson
fe683dfb80
rt: Get rid of the valgrind guard bytes at the end of the stack
...
Preventing us from writing beyond our allocations is _what valgrind does_,
so telling valgrind not to let us write to the end of the stack isn't
buying anything.
2011-12-17 16:46:50 -08:00
Brian Anderson
4ac345939c
rt: Cache an extra stack segment to avoid bad behavior at stack boundaries
2011-12-17 13:45:38 -08:00
Brian Anderson
0ed5117a9d
rt: Set the default stack size to 768 bytes. Double on each alloc
2011-12-17 13:45:38 -08:00
Brian Anderson
23df4de86d
rt: Fix alignment of new stack segments
2011-12-16 18:18:43 -08:00
Brian Anderson
81f932e7d7
rt: Fix alignment of stacks generated by __morestack
2011-12-07 14:06:46 -08:00
Brian Anderson
9656ceac60
rt: Put 16 guard bytes at the end of the stack
2011-12-06 22:35:42 -08:00
Brian Anderson
5d1a1dc420
rt: Rename stk_seg.limit to stk_seg.end
...
rust_task is using the word limit it two ways, so one has to change.
2011-12-06 21:45:53 -08:00
Brian Anderson
9a738fd61d
rt: Various tweaks to make __morestack unwinding work on linux
...
When unwinding through __morestack the stack limit in the TLS is invalidated
and must be reset. Instead of actually landing at __morestack we're
just going to make all our Rust landing pads call upcall_reset_stack_limit,
which will find the stack segment that corresponds to the current stack
pointer and put the limit in the TLS.
Also massively expand the stack segment red zone to make more room for the
dynamic linker. Will fix in the future.
2011-12-06 16:32:41 -08:00
Austin Seipp
b513a5a500
Make valgrind usage more consistent and less error prone.
...
I was still having issues with the build system somehow getting confused
as to which set of valgrind headers to use when compiling rt.
This commit moves all the valgrind headers into their own directory
under rt and makes the usage more consistent. The compiler is now passed
the -DNVALGRIND flag when valgrind is not installed, as opposed to
passing -DHAVE_VALGRIND.
We also pass -I src/rt to the compiler when building rt so you can more
easily import what you want. I also cleaned up some erroneous #includes
along the way.
It should be safe to always just import the local valgrind headers and use
them without question. NVALGRIND turns the operations to no-ops when it
is active, and the build and tests run cleanly with or without.
2011-12-06 01:15:29 -06:00
Brian Anderson
58844aee42
rt: Make stack unwinding work more correctly with stack growth
2011-12-05 17:42:58 -08:00
Brian Anderson
52d7dc5e0a
rt: Update 32-bit __morestack for recent LLVM changes
2011-12-04 20:40:34 -08:00
Brian Anderson
1974cf9a81
rt: Move RED_ZONE_SIZE to rust_task.cpp
2011-12-01 15:50:00 -08:00
Brian Anderson
249f017bf2
rt: Add FIXME's about future changes to LLVM's __morestack impl
2011-12-01 15:33:15 -08:00
Brian Anderson
6da1a3fcd6
rt: Refactor record_sp into task::record_stack_limit
2011-12-01 15:26:42 -08:00
Brian Anderson
f2de42c39a
rt: Reorganize stack growth code
2011-11-30 20:31:33 -08:00
Brian Anderson
e6ef4d929c
rt: Remove the stack pointer field of stk_seg
2011-11-30 20:31:33 -08:00
Brian Anderson
06f4cb43f6
rt: Delete the entire stack chain on task destruction
...
Unwinding through __morestack on 64-bit Linux seems to be no big deal, and
all we have to do is free the stacks to make unwinding work with split stacks.
2011-11-29 22:22:49 -08:00