File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -30,12 +30,9 @@ pub unsafe fn ___chkstk_ms() {
30
30
#[ naked]
31
31
#[ cfg_attr( not( test) , no_mangle) ]
32
32
pub unsafe fn __alloca ( ) {
33
- asm ! ( "mov %rcx,%rax // x64 _alloca is a normal function with parameter in rcx" ) ;
34
- // The original behavior had __alloca fall through to ___chkstk here, but
35
- // I don't believe that this behavior is guaranteed, and a program that uses
36
- // only __alloca could have ___chkstk removed by --gc-sections. Call
37
- // ___chkstk here to guarantee that neither of those happen.
38
- ___chkstk ( ) ;
33
+ asm ! ( "mov %rcx,%rax // x64 _alloca is a normal function with parameter in rcx
34
+ jmp ___chkstk // Jump to ___chkstk since fallthrough may be unreliable" ) ;
35
+ intrinsics:: unreachable ( ) ;
39
36
}
40
37
41
38
#[ cfg( windows) ]
You can’t perform that action at this time.
0 commit comments