2007-06-03 01:56:57 +00:00
|
|
|
#ifndef COMMON_H
|
|
|
|
#define COMMON_H
|
|
|
|
|
2007-06-05 00:28:52 +00:00
|
|
|
#include "stdint.h"
|
2007-06-18 04:25:42 +00:00
|
|
|
#include "stdlib.h"
|
2007-06-07 00:30:16 +00:00
|
|
|
#include "stdarg.h"
|
|
|
|
#include "string.h"
|
|
|
|
#include "stdio.h"
|
2007-06-05 00:28:52 +00:00
|
|
|
|
2007-06-03 01:56:57 +00:00
|
|
|
#define NO_RETURN __attribute__((noreturn))
|
2007-06-08 00:23:12 +00:00
|
|
|
#define LIKELY(v) __builtin_expect((v) != 0, true)
|
|
|
|
#define UNLIKELY(v) __builtin_expect((v) == 0, true)
|
2007-06-03 01:56:57 +00:00
|
|
|
|
2007-06-05 00:28:52 +00:00
|
|
|
#define MACRO_XY(X, Y) X##Y
|
|
|
|
#define MACRO_MakeNameXY(FX, LINE) MACRO_XY(FX, LINE)
|
|
|
|
#define MAKE_NAME(FX) MACRO_MakeNameXY(FX, __LINE__)
|
|
|
|
|
2007-06-03 01:56:57 +00:00
|
|
|
#endif//COMMON_H
|