File tree 2 files changed +2
-5
lines changed
2 files changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -135,11 +135,8 @@ _x86_64_asm_write_rflags:
135
135
.global _x86_64_asm_read_rflags
136
136
.p2align 4
137
137
_x86_64_asm_read_rflags:
138
- pushq %rbp
139
- movq %rsp , %rbp
140
138
pushfq
141
139
popq %rax
142
- popq %rbp
143
140
retq
144
141
145
142
.global _x86_64_asm_load_ss
Original file line number Diff line number Diff line change @@ -81,7 +81,7 @@ mod x86_64 {
81
81
82
82
#[ cfg( feature = "inline_asm" ) ]
83
83
unsafe {
84
- asm ! ( "pushf ; pop {}" , out( reg) r, options( nomem, preserves_flags) ) ;
84
+ asm ! ( "pushfq ; pop {}" , out( reg) r, options( nomem, preserves_flags) ) ;
85
85
}
86
86
#[ cfg( not( feature = "inline_asm" ) ) ]
87
87
unsafe {
@@ -122,7 +122,7 @@ mod x86_64 {
122
122
// HACK: we mark this function as preserves_flags to prevent Rust from restoring
123
123
// saved flags after the "popf" below. See above note on safety.
124
124
#[ cfg( feature = "inline_asm" ) ]
125
- asm ! ( "push {}; popf " , in( reg) val, options( nomem, preserves_flags) ) ;
125
+ asm ! ( "push {}; popfq " , in( reg) val, options( nomem, preserves_flags) ) ;
126
126
127
127
#[ cfg( not( feature = "inline_asm" ) ) ]
128
128
crate :: asm:: x86_64_asm_write_rflags ( val) ;
You can’t perform that action at this time.
0 commit comments