qemu/compiler: Define likely() and unlikely() preprocessor macros if they don't exist

Makes the code more functional with MSVC
This commit is contained in:
Lioncash 2019-01-28 09:09:57 -05:00
parent 80e7661555
commit d020acd771
No known key found for this signature in database
GPG key ID: 4E3C3CC1031BA9C7

View file

@ -62,6 +62,14 @@
#endif
#endif
#ifndef likely
#define likely(x) (x)
#endif
#ifndef unlikely
#define unlikely(x) (x)
#endif
#define sizeof_field(type, field) sizeof(((type *)0)->field)
static double rint( double x )