Changeset View
Changeset View
Standalone View
Standalone View
src/secp256k1/src/util.h
Show All 30 Lines | |||||
} while(0); | } while(0); | ||||
#else | #else | ||||
#define TEST_FAILURE(msg) do { \ | #define TEST_FAILURE(msg) do { \ | ||||
fprintf(stderr, "%s:%d: %s\n", __FILE__, __LINE__, msg); \ | fprintf(stderr, "%s:%d: %s\n", __FILE__, __LINE__, msg); \ | ||||
abort(); \ | abort(); \ | ||||
} while(0) | } while(0) | ||||
#endif | #endif | ||||
#ifdef HAVE_BUILTIN_EXPECT | #if SECP256K1_GNUC_PREREQ(3, 0) | ||||
#define EXPECT(x,c) __builtin_expect((x),(c)) | #define EXPECT(x,c) __builtin_expect((x),(c)) | ||||
#else | #else | ||||
#define EXPECT(x,c) (x) | #define EXPECT(x,c) (x) | ||||
#endif | #endif | ||||
#ifdef DETERMINISTIC | #ifdef DETERMINISTIC | ||||
#define CHECK(cond) do { \ | #define CHECK(cond) do { \ | ||||
if (EXPECT(!(cond), 0)) { \ | if (EXPECT(!(cond), 0)) { \ | ||||
▲ Show 20 Lines • Show All 74 Lines • Show Last 20 Lines |