SameBoy | Accurate GB/GBC emulator |
| download: https://git.y1.nz/archives/sameboy.tar.gz | |
| README | Files | Log | Refs | LICENSE |
commit 7b5846fbaf10d543e09585eb701577e6a859de22 parent d6adbe0c7f01907a769265a08c6703eb191d3b6d Author: Lior Halphon <LIJI32@gmail.com> Date: Sun, 31 Jul 2022 01:16:03 +0300 Build break Diffstat:
| M | Cocoa/Document.m | 3 | +++ |
| M | Core/defs.h | 7 | +++++-- |
| M | SDL/audio.c | 3 | ++- |
3 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/Cocoa/Document.m b/Cocoa/Document.m @@ -14,6 +14,9 @@ #import "GBObjectView.h" #import "GBPaletteView.h" +#define likely(x) GB_likely(x) +#define unlikely(x) GB_unlikely(x) + @implementation NSString (relativePath) - (NSString *)pathRelativeToDirectory:(NSString *)directory diff --git a/Core/defs.h b/Core/defs.h @@ -1,11 +1,14 @@ #ifndef defs_h #define defs_h +#define GB_likely(x) __builtin_expect((bool)(x), 1) +#define GB_unlikely(x) __builtin_expect((bool)(x), 0) + #ifdef GB_INTERNAL // "Keyword" definitions -#define likely(x) __builtin_expect((bool)(x), 1) -#define unlikely(x) __builtin_expect((bool)(x), 0) +#define likely(x) GB_likely(x) +#define unlikely(x) GB_unlikely(x) #define internal __attribute__((visibility("internal"))) diff --git a/SDL/audio.c b/SDL/audio.c @@ -5,7 +5,8 @@ #include "audio/audio.h" #include "configuration.h" -#define unlikely(x) __builtin_expect((bool)(x), 0) +#define likely(x) GB_likely(x) +#define unlikely(x) GB_unlikely(x) static const GB_audio_driver_t *driver = NULL;
This webpage is intended to be an accessible preview of this repository. To get a fuller picture, clone it and use the git CLI.