aboutsummaryrefslogtreecommitdiff
path: root/src/unlikely.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/unlikely.h')
-rw-r--r--src/unlikely.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/unlikely.h b/src/unlikely.h
index 602c723..72f51b6 100644
--- a/src/unlikely.h
+++ b/src/unlikely.h
@@ -1,12 +1,12 @@
-#ifndef INPLA_UNLIKELY_H
-#define INPLA_UNLIKELY_H
+#ifndef INPLA_UNLIKELY_H_
+#define INPLA_UNLIKELY_H_
#if defined(__GNUC__) || defined(__clang__)
- // GCC と Clang の場合は、極限まで最適化!
+ // For GCC, Clang
#define likely(x) __builtin_expect(!!(x), 1)
#define unlikely(x) __builtin_expect(!!(x), 0)
#else
- // それ以外のコンパイラ(MSVCなど)では、ただの素通り(無害化)
+ // Otherwise
#define likely(x) (x)
#define unlikely(x) (x)
#endif