@@ -27,18 +27,12 @@ check_stack_alignment() __attribute__ ((aligned (16)));
27
27
static void check_stack_alignment () { }
28
28
#endif
29
29
30
- static inline void
31
- do_sanity_check (rust_task *task) {
32
- check_stack_alignment ();
33
- task->check_stack_canary ();
34
- }
35
-
36
30
#define UPCALL_SWITCH_STACK (A, F ) call_upcall_on_c_stack((void *)A, (void *)F)
37
31
38
32
inline void
39
33
call_upcall_on_c_stack (void *args, void *fn_ptr) {
34
+ check_stack_alignment ();
40
35
rust_task *task = rust_scheduler::get_task ();
41
- do_sanity_check (task);
42
36
rust_scheduler *sched = task->sched ;
43
37
sched->c_context .call_shim_on_c_stack (args, fn_ptr);
44
38
}
@@ -55,7 +49,6 @@ extern "C" void record_sp(void *limit);
55
49
extern " C" CDECL void
56
50
upcall_call_shim_on_c_stack (void *args, void *fn_ptr) {
57
51
rust_task *task = rust_scheduler::get_task ();
58
- do_sanity_check (task);
59
52
60
53
// FIXME (1226) - The shim functions generated by rustc contain the
61
54
// morestack prologue, so we need to let them know they have enough
@@ -645,9 +638,7 @@ upcall_del_stack() {
645
638
extern " C" CDECL void
646
639
upcall_reset_stack_limit () {
647
640
rust_task *task = rust_scheduler::get_task ();
648
- do_sanity_check (task);
649
641
task->reset_stack_limit ();
650
- task->check_stack_canary ();
651
642
}
652
643
653
644
//
0 commit comments