Skip to content

Commit

Permalink
Switch to x64_rbp to avoid the use of a pinned register (bytecodeal…
Browse files Browse the repository at this point in the history
…liance#5168)

Avoid a use of preg_rpb in the x64 backend, using x64_rbp instead.
  • Loading branch information
elliottt authored Nov 1, 2022
1 parent 0ca3249 commit 09d8df6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cranelift/codegen/src/isa/x64/lower.isle
Original file line number Diff line number Diff line change
Expand Up @@ -2853,7 +2853,7 @@

(rule (lower (get_return_address))
(x64_load $I64
(Amode.ImmReg 8 (preg_rbp) (mem_flags_trusted))
(Amode.ImmReg 8 (x64_rbp) (mem_flags_trusted))
(ExtKind.None)))

;; Rules for `jump` ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Expand Down
4 changes: 3 additions & 1 deletion cranelift/filetests/filetests/isa/x64/fp_sp_pc.clif
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@ block0:
; pushq %rbp
; movq %rsp, %rbp
; block0:
; movq 8(%rbp), %rax
; movq %rbp, %rdi
; movq 8(%rdi), %rax
; movq %rbp, %rsp
; popq %rbp
; ret

0 comments on commit 09d8df6

Please sign in to comment.