| ... | @@ -183,6 +183,7 @@ fn _start() callconv(.naked) noreturn { | ... | @@ -183,6 +183,7 @@ fn _start() callconv(.naked) noreturn { |
| 183 | .sparc, .sparc64 => ".cfi_undefined %%i7", | 183 | .sparc, .sparc64 => ".cfi_undefined %%i7", |
| 184 | .x86 => ".cfi_undefined %%eip", | 184 | .x86 => ".cfi_undefined %%eip", |
| 185 | .x86_64 => ".cfi_undefined %%rip", | 185 | .x86_64 => ".cfi_undefined %%rip", |
| | 186 | .xtensa, .xtensaeb => "", // No CFI support. |
| 186 | else => @compileError("unsupported arch"), | 187 | else => @compileError("unsupported arch"), |
| 187 | }); | 188 | }); |
| 188 | | 189 | |
| ... | @@ -486,6 +487,15 @@ fn _start() callconv(.naked) noreturn { | ... | @@ -486,6 +487,15 @@ fn _start() callconv(.naked) noreturn { |
| 486 | \\ sub %%sp, 2047, %%sp | 487 | \\ sub %%sp, 2047, %%sp |
| 487 | \\ ba,a %[posixCallMainAndExit] | 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 | else => @compileError("unsupported arch"), | 499 | else => @compileError("unsupported arch"), |
| 490 | } | 500 | } |
| 491 | : | 501 | : |