Fix asm! from AT&T to Intel syntax
This commit is contained in:
parent
b97a33b1cb
commit
fcb37cb7d6
2 changed files with 3 additions and 3 deletions
|
@ -62,7 +62,7 @@ mod fpu_precision {
|
|||
// any `u16`
|
||||
unsafe {
|
||||
asm!(
|
||||
"fldcw ({})",
|
||||
"fldcw word ptr [{}]",
|
||||
in(reg) &cw,
|
||||
options(nostack),
|
||||
)
|
||||
|
@ -86,7 +86,7 @@ mod fpu_precision {
|
|||
// any `u16`
|
||||
unsafe {
|
||||
asm!(
|
||||
"fnstcw ({})",
|
||||
"fnstcw word ptr [{}]",
|
||||
in(reg) &mut cw,
|
||||
options(nostack),
|
||||
)
|
||||
|
|
|
@ -36,7 +36,7 @@ pub fn image_base() -> u64 {
|
|||
let base: u64;
|
||||
unsafe {
|
||||
asm!(
|
||||
"lea IMAGE_BASE(%rip), {}",
|
||||
"lea {}, qword ptr [rip + IMAGE_BASE]",
|
||||
lateout(reg) base,
|
||||
options(nostack, preserves_flags, nomem, pure),
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue