From: John Wolfe Date: Mon, 5 Apr 2021 16:01:43 +0000 (-0700) Subject: Common header file change not applicable to open-vm-tools. X-Git-Tag: stable-11.3.0~74 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d1d9f2fca56a40159b7039f2955410acc3de3489;p=thirdparty%2Fopen-vm-tools.git Common header file change not applicable to open-vm-tools. --- diff --git a/open-vm-tools/lib/include/vm_basic_asm.h b/open-vm-tools/lib/include/vm_basic_asm.h index 201f10134..23af5ef7c 100644 --- a/open-vm-tools/lib/include/vm_basic_asm.h +++ b/open-vm-tools/lib/include/vm_basic_asm.h @@ -652,7 +652,7 @@ uint32set(void *dst, uint32 val, size_t count) static INLINE uint16 Bswap16(uint16 v) { -#if defined(VM_ARM_64) +#if defined(VM_ARM_64) && !defined(_MSC_VER) __asm__("rev16 %w0, %w0" : "+r"(v)); return v; #else @@ -685,7 +685,7 @@ Bswap32(uint32 v) // IN #elif defined(VM_ARM_32) && !defined(__ANDROID__) && !defined(_MSC_VER) __asm__("rev %0, %0" : "+r"(v)); return v; -#elif defined(VM_ARM_64) +#elif defined(VM_ARM_64) && !defined(_MSC_VER) __asm__("rev32 %x0, %x0" : "+r"(v)); return v; #else @@ -711,7 +711,7 @@ Bswap32(uint32 v) // IN static INLINE uint64 Bswap64(uint64 v) // IN { -#if defined(VM_ARM_64) +#if defined(VM_ARM_64) && !defined(_MSC_VER) __asm__("rev %0, %0" : "+r"(v)); return v; #else @@ -742,7 +742,11 @@ PAUSE(void) } #elif defined(_MSC_VER) { +#ifdef VM_X86_ANY _mm_pause(); +#else + __yield(); +#endif } #else /* __GNUC__ */ #error No compiler defined for PAUSE