More linux fixes

This commit is contained in:
ArtemisX64 2022-08-27 15:53:31 +09:00
parent e4fc8ce726
commit 4bc6c01ce6
3 changed files with 10 additions and 4 deletions

View file

@ -231,10 +231,12 @@ typedef union _LARGE_INTEGER {
#else
#define DLLEXPORT
#define DLLIMPORT
#define DEBUG_BREAK
// fixme: random stack overflow solution. use with caution
#include <csignal>
#define DEBUG_BREAK raise(SIGTRAP)
#define ALIGN(N) __attribute__((aligned (N)))
#define NOINLINE __attribute__((noinline))
// fixme: random github solution. use it with caution
// fixme: random stack overflow solution. use it with caution
#define ASSUME(X) do { if (!(X)) __builtin_unreachable(); } while (0)
#define THREAD_LOCAL __thread
#define POPCNT(X) __builtin_popcount((X))