| ... | ... | @@ -183,6 +183,7 @@ fn _start() callconv(.naked) noreturn { |
| 183 | 183 | .sparc, .sparc64 => ".cfi_undefined %%i7", |
| 184 | 184 | .x86 => ".cfi_undefined %%eip", |
| 185 | 185 | .x86_64 => ".cfi_undefined %%rip", |
| 186 | .xtensa, .xtensaeb => "", // No CFI support. |
| 186 | 187 | else => @compileError("unsupported arch"), |
| 187 | 188 | }); |
| 188 | 189 | |
| ... | ... | @@ -486,6 +487,15 @@ fn _start() callconv(.naked) noreturn { |
| 486 | 487 | \\ sub %%sp, 2047, %%sp |
| 487 | 488 | \\ ba,a %[posixCallMainAndExit] |
| 488 | 489 | , |
| 490 | .xtensa, .xtensaeb => |
| 491 | // a0 = LR, a7 = FP, a1 = SP |
| 492 | \\ movi a0, 0 |
| 493 | \\ movi a7, 0 |
| 494 | \\ mov a2, sp |
| 495 | \\ movi a8, -16 |
| 496 | \\ and sp, sp, a8 |
| 497 | \\ callx0 %[posixCallMainAndExit] |
| 498 | , |
| 489 | 499 | else => @compileError("unsupported arch"), |
| 490 | 500 | } |
| 491 | 501 | : |