Cranelift AArch64: Use an allocated encoding for Udf (#4281)
Preserve the current behaviour when code is generated for SpiderMonkey. Copyright (c) 2022, Arm Limited.
This commit is contained in:
@@ -695,6 +695,7 @@
|
||||
;; An instruction guaranteed to always be undefined and to trigger an illegal instruction at
|
||||
;; runtime.
|
||||
(Udf
|
||||
(use_allocated_encoding bool)
|
||||
(trap_code TrapCode))
|
||||
|
||||
;; Compute the address (using a PC-relative offset) of a memory location, using the `ADR`
|
||||
@@ -1905,6 +1906,12 @@
|
||||
(_2 Unit (emit (MInst.VecRRR (VecALUOp.Bsl) dst x y (vector_size ty)))))
|
||||
dst))
|
||||
|
||||
;; Helper for generating a `udf` instruction.
|
||||
|
||||
(decl udf (bool TrapCode) SideEffectNoResult)
|
||||
(rule (udf use_allocated_encoding trap_code)
|
||||
(SideEffectNoResult.Inst (MInst.Udf use_allocated_encoding trap_code)))
|
||||
|
||||
;; Immediate value helpers ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
(decl imm (Type u64) Reg)
|
||||
|
||||
Reference in New Issue
Block a user