Skip to content

Commit f1db941

Browse files
newpavlovAmanieu
authored andcommitted
Remove late specifiers in __cpuid_count
1 parent 3fd17e4 commit f1db941

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

crates/core_arch/src/x86/cpuid.rs

+14-14
Original file line numberDiff line numberDiff line change
@@ -62,27 +62,27 @@ pub unsafe fn __cpuid_count(leaf: u32, sub_leaf: u32) -> CpuidResult {
6262
#[cfg(target_arch = "x86")]
6363
{
6464
asm!(
65-
"movl %ebx, {0}",
65+
"movl {0}, ebx",
6666
"cpuid",
67-
"xchgl %ebx, {0}",
68-
lateout(reg) ebx,
69-
inlateout("eax") leaf => eax,
70-
inlateout("ecx") sub_leaf => ecx,
71-
lateout("edx") edx,
72-
options(nostack, preserves_flags, att_syntax),
67+
"xchgl {0}, ebx",
68+
out(reg) ebx,
69+
inout("eax") leaf => eax,
70+
inout("ecx") sub_leaf => ecx,
71+
out("edx") edx,
72+
options(nostack, preserves_flags),
7373
);
7474
}
7575
#[cfg(target_arch = "x86_64")]
7676
{
7777
asm!(
78-
"movq %rbx, {0:r}",
78+
"movq {0:r}, rbx",
7979
"cpuid",
80-
"xchgq %rbx, {0:r}",
81-
lateout(reg) ebx,
82-
inlateout("eax") leaf => eax,
83-
inlateout("ecx") sub_leaf => ecx,
84-
lateout("edx") edx,
85-
options(nostack, preserves_flags, att_syntax),
80+
"xchgq {0:r}, rbx",
81+
out(reg) ebx,
82+
inout("eax") leaf => eax,
83+
inout("ecx") sub_leaf => ecx,
84+
out("edx") edx,
85+
options(nostack, preserves_flags),
8686
);
8787
}
8888
CpuidResult { eax, ebx, ecx, edx }

0 commit comments

Comments
 (0)