Fix build on i386.

This commit is contained in:
Mathieu Arnold 2018-09-25 14:25:50 +00:00
parent 66c73d6ca1
commit eef8b139b6
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=480665

View file

@ -0,0 +1,15 @@
--- lib/isc/rwlock.c.orig 2018-09-25 13:20:09 UTC
+++ lib/isc/rwlock.c
@@ -44,9 +44,11 @@
#if defined(_MSC_VER)
# include <intrin.h>
# define isc_rwlock_pause() YieldProcessor()
-#elif defined(__x86_64__) || defined(__i386__)
+#elif defined(__x86_64__)
# include <immintrin.h>
# define isc_rwlock_pause() _mm_pause()
+#elif defined(__i386__)
+# define isc_rwlock_pause() asm("rep; nop")
#elif defined(__ia64__)
# define isc_rwlock_pause() __asm__ __volatile__ ("hint @pause")
#elif defined(__arm__)