From: Mike Pall Date: Sat, 6 Dec 2025 07:42:18 +0000 (+0100) Subject: ARM64: More fixes for ARM BTI. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c7c74ea505ab9103bd0df8e84da56a895ae60e82;p=thirdparty%2FLuaJIT.git ARM64: More fixes for ARM BTI. Reported by Yuichiro Naito. #1415 --- diff --git a/src/vm_arm64.dasc b/src/vm_arm64.dasc index eb6d0c2f..08ecb72c 100644 --- a/src/vm_arm64.dasc +++ b/src/vm_arm64.dasc @@ -1696,6 +1696,7 @@ static void build_subroutines(BuildCtx *ctx) | adr lr, >1 | checkint CARG1, ->vm_tobit_fb |1: + | bti_jump |.endmacro | |.macro .ffunc_bit_op, name, ins @@ -1710,6 +1711,7 @@ static void build_subroutines(BuildCtx *ctx) | bge >9 | checkint CARG1, ->vm_tobit_fb |2: + | bti_jump | ins TMP0w, TMP0w, CARG1w | b <1 |.endmacro @@ -1742,6 +1744,7 @@ static void build_subroutines(BuildCtx *ctx) | adr lr, >1 | checkint CARG1, ->vm_tobit_fb |1: + | bti_jump |.if shmod == 0 | mov TMP1, CARG1 |.else @@ -1751,6 +1754,7 @@ static void build_subroutines(BuildCtx *ctx) | adr lr, >2 | checkint CARG1, ->vm_tobit_fb |2: + | bti_jump | ins TMP0w, CARG1w, TMP1w | add_TISNUM CARG1, TMP0 | b ->fff_restv