diff options
author | markm <markm@FreeBSD.org> | 2000-11-21 20:16:49 +0000 |
---|---|---|
committer | markm <markm@FreeBSD.org> | 2000-11-21 20:16:49 +0000 |
commit | a3da3ab72cd06286d3802b38bba4ee1edd58dfb3 (patch) | |
tree | 89345673900e85f3d00809180810f91d1362b5d3 /sys/amd64/include/cpufunc.h | |
parent | ae30fcfec826cbc1aef366e520ae248267e5ac2e (diff) | |
download | FreeBSD-src-a3da3ab72cd06286d3802b38bba4ee1edd58dfb3.zip FreeBSD-src-a3da3ab72cd06286d3802b38bba4ee1edd58dfb3.tar.gz |
Assembler fixes.
Fix opcodes that were typed as ".byte 0xNN, 0xMM" when an older
assembler could not recognise the newer Pentium instructions.
Reviewed by: jhb
Diffstat (limited to 'sys/amd64/include/cpufunc.h')
-rw-r--r-- | sys/amd64/include/cpufunc.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/amd64/include/cpufunc.h b/sys/amd64/include/cpufunc.h index fef36e0..8941ba1 100644 --- a/sys/amd64/include/cpufunc.h +++ b/sys/amd64/include/cpufunc.h @@ -379,7 +379,7 @@ rdmsr(u_int msr) { u_int64_t rv; - __asm __volatile(".byte 0x0f, 0x32" : "=A" (rv) : "c" (msr)); + __asm __volatile("rdmsr" : "=A" (rv) : "c" (msr)); return (rv); } @@ -388,7 +388,7 @@ rdpmc(u_int pmc) { u_int64_t rv; - __asm __volatile(".byte 0x0f, 0x33" : "=A" (rv) : "c" (pmc)); + __asm __volatile("rdpmc" : "=A" (rv) : "c" (pmc)); return (rv); } @@ -397,7 +397,7 @@ rdtsc(void) { u_int64_t rv; - __asm __volatile(".byte 0x0f, 0x31" : "=A" (rv)); + __asm __volatile("rdtsc" : "=A" (rv)); return (rv); } @@ -416,7 +416,7 @@ write_eflags(u_int ef) static __inline void wrmsr(u_int msr, u_int64_t newval) { - __asm __volatile(".byte 0x0f, 0x30" : : "A" (newval), "c" (msr)); + __asm __volatile("wrmsr" : : "A" (newval), "c" (msr)); } static __inline u_int |