]> git.lizzy.rs Git - rust.git/commit
Use __morestack to detect stack overflow
authorAlex Crichton <alex@alexcrichton.com>
Thu, 17 Oct 2013 08:40:33 +0000 (01:40 -0700)
committerAlex Crichton <alex@alexcrichton.com>
Sat, 19 Oct 2013 16:43:31 +0000 (09:43 -0700)
commit6d8330afb6c925d1092f27919f61d4ce6a3fb1d4
tree72a6ff826ffcd13afe10a79cc4a4a78384cf2f16
parentd773a024a2976f2759235551a52101cd08b37cce
Use __morestack to detect stack overflow

This commit resumes management of the stack boundaries and limits when switching
between tasks. This additionally leverages the __morestack function to run code
on "stack overflow". The current behavior is to abort the process, but this is
probably not the best behavior in the long term (for deails, see the comment I
wrote up in the stack exhaustion routine).
57 files changed:
mk/platform.mk
mk/rt.mk
src/librustc/middle/trans/base.rs
src/librustc/middle/trans/foreign.rs
src/librustc/rustc.rs
src/libstd/rt/context.rs
src/libstd/rt/crate_map.rs
src/libstd/rt/env.rs
src/libstd/rt/sched.rs
src/libstd/rt/task.rs
src/libstd/rt/thread.rs
src/libstd/rt/thread_local_storage.rs
src/rt/arch/arm/ccall.S [deleted file]
src/rt/arch/arm/context.cpp [deleted file]
src/rt/arch/arm/context.h [deleted file]
src/rt/arch/arm/gpr.cpp [deleted file]
src/rt/arch/arm/gpr.h [deleted file]
src/rt/arch/arm/morestack.S
src/rt/arch/arm/record_sp.S
src/rt/arch/arm/regs.h [deleted file]
src/rt/arch/arm/sp.h [deleted file]
src/rt/arch/i386/ccall.S [deleted file]
src/rt/arch/i386/context.cpp [deleted file]
src/rt/arch/i386/context.h [deleted file]
src/rt/arch/i386/gpr.cpp [deleted file]
src/rt/arch/i386/gpr.h [deleted file]
src/rt/arch/i386/morestack.S
src/rt/arch/i386/regs.h [deleted file]
src/rt/arch/i386/sp.h [deleted file]
src/rt/arch/mips/ccall.S [deleted file]
src/rt/arch/mips/context.cpp [deleted file]
src/rt/arch/mips/context.h [deleted file]
src/rt/arch/mips/gpr.cpp [deleted file]
src/rt/arch/mips/gpr.h [deleted file]
src/rt/arch/mips/morestack.S
src/rt/arch/mips/record_sp.S
src/rt/arch/mips/regs.h [deleted file]
src/rt/arch/mips/sp.h [deleted file]
src/rt/arch/x86_64/_context.S
src/rt/arch/x86_64/ccall.S [deleted file]
src/rt/arch/x86_64/context.cpp [deleted file]
src/rt/arch/x86_64/context.h [deleted file]
src/rt/arch/x86_64/gpr.cpp [deleted file]
src/rt/arch/x86_64/gpr.h [deleted file]
src/rt/arch/x86_64/morestack.S
src/rt/arch/x86_64/regs.h
src/rt/arch/x86_64/sp.h [deleted file]
src/rt/rust_builtin.cpp
src/rt/rust_gpr_base.h [deleted file]
src/rt/rust_test_helpers.cpp
src/rt/rustrt.def.in
src/rt/sync/rust_thread.cpp
src/rt/sync/rust_thread.h
src/test/auxiliary/static_priv_by_default.rs
src/test/compile-fail/static-priv-by-default.rs
src/test/compile-fail/xcrate-private-by-default.rs
src/test/run-pass/no-std-xcrate.rs