// c7_hotpath_env_box.h - ENV gate for C7 hotpath // Purpose: isolate the ENV handling so hotpath code can assume gate済み。 #pragma once #include // ENV gate: HAKMEM_TINY_C7_HOT=1 で有効化(デフォルト OFF) static inline int tiny_c7_hot_enabled(void) { static int g_enable = -1; if (__builtin_expect(g_enable == -1, 0)) { const char* e = getenv("HAKMEM_TINY_C7_HOT"); g_enable = (e && *e && *e != '0') ? 1 : 0; } return g_enable; }