From: Sebastian Nickolls Date: Tue, 13 Aug 2024 10:47:40 +0000 (+0100) Subject: cmd/internal/obj/arm64: Emit UDF instruction for undefined Prog nodes X-Git-Tag: go1.24rc1~1201 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=3e3ce20df87b2de86fbcbbad863b07b1a133e879;p=gostls13.git cmd/internal/obj/arm64: Emit UDF instruction for undefined Prog nodes UDF provides a stronger guarantee for generating the Undefined Instruction exception than the current value being emitted. Change-Id: I234cd70ce04f21311959c1061ae24992438105f8 Reviewed-on: https://go-review.googlesource.com/c/go/+/605155 LUCI-TryBot-Result: Go LUCI Reviewed-by: Carlos Amedee Reviewed-by: Cherry Mui --- diff --git a/src/cmd/internal/obj/arm64/asm7.go b/src/cmd/internal/obj/arm64/asm7.go index 178c83c0bc..bd2bd037ba 100644 --- a/src/cmd/internal/obj/arm64/asm7.go +++ b/src/cmd/internal/obj/arm64/asm7.go @@ -5338,10 +5338,10 @@ func (c *ctxt7) asmout(p *obj.Prog, o *Optab, out []uint32) { // This is supposed to be something that stops execution. // It's not supposed to be reached, ever, but if it is, we'd // like to be able to tell how we got there. Assemble as - // 0xbea71700 which is guaranteed to raise undefined instruction + // UDF which is guaranteed to raise the undefined instruction // exception. case 90: - o1 = 0xbea71700 + o1 = 0x0 case 91: /* prfm imm(Rn), */ imm := uint32(p.From.Offset)