[PATCH 2/2] newlib: riscv: Fix build for rv64e

Eric Salem ericsalem@gmail.com
Sun Apr 20 20:39:18 GMT 2025


Update the macro check so that rv64e builds successfully.

Signed-off-by: Eric Salem <ericsalem@gmail.com>
---
 newlib/libc/machine/riscv/setjmp.S | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/newlib/libc/machine/riscv/setjmp.S b/newlib/libc/machine/riscv/setjmp.S
index eef242e0211a..2d4ab6cfc885 100644
--- a/newlib/libc/machine/riscv/setjmp.S
+++ b/newlib/libc/machine/riscv/setjmp.S
@@ -19,7 +19,7 @@ setjmp:
 	REG_S s0,  1*SZREG(a0)
 	REG_S s1,  2*SZREG(a0)
 
-#ifndef __riscv_32e
+#ifndef __riscv_abi_rve
 	REG_S s2,  3*SZREG(a0)
 	REG_S s3,  4*SZREG(a0)
 	REG_S s4,  5*SZREG(a0)
@@ -61,7 +61,7 @@ longjmp:
 	REG_L ra,  0*SZREG(a0)
 	REG_L s0,  1*SZREG(a0)
 	REG_L s1,  2*SZREG(a0)
-#ifndef __riscv_32e
+#ifndef __riscv_abi_rve
 	REG_L s2,  3*SZREG(a0)
 	REG_L s3,  4*SZREG(a0)
 	REG_L s4,  5*SZREG(a0)
-- 
2.49.0



More information about the Newlib mailing list