Working state before pushing to cyu remote
This commit is contained in:
@ -10,6 +10,22 @@ ws=${WS:-400}
|
||||
runs=${RUNS:-10}
|
||||
bin=${BENCH_BIN:-./bench_random_mixed_hakmem}
|
||||
|
||||
# SSOT header: bin sha / profile / iters / ws / runs
|
||||
echo "[SSOT-HEADER] bin=$(sha256sum "${bin}" | cut -c1-8) profile=${profile} iters=${iters} ws=${ws} runs=${runs}"
|
||||
|
||||
# Bench size range SSOT (bench_random_mixed.c reads these).
|
||||
# IMPORTANT: we FORCE these to avoid leaked exports causing "wrong classes exercised"
|
||||
# (e.g. only <=256B => C4/C5/C6 inline-slots never invoked).
|
||||
ssot_min_size=${SSOT_MIN_SIZE:-16}
|
||||
ssot_max_size=${SSOT_MAX_SIZE:-1040} # matches bench default (16..1040 ≒ 16..1024)
|
||||
export HAKMEM_BENCH_MIN_SIZE="${ssot_min_size}"
|
||||
export HAKMEM_BENCH_MAX_SIZE="${ssot_max_size}"
|
||||
|
||||
# Disable fixed-size bench modes (must be forced to avoid leaks).
|
||||
export HAKMEM_BENCH_C5_ONLY=0
|
||||
export HAKMEM_BENCH_C6_ONLY=0
|
||||
export HAKMEM_BENCH_C7_ONLY=0
|
||||
|
||||
# Keep profiles reproducible even if user exported env vars.
|
||||
case "${profile}" in
|
||||
MIXED_TINYV3_C7_BALANCED)
|
||||
@ -53,6 +69,11 @@ export HAKMEM_TINY_INLINE_SLOTS_FIXED=${HAKMEM_TINY_INLINE_SLOTS_FIXED:-1}
|
||||
# NOTE: Phase 80-1 winner (Switch dispatch for inline slots, removes if-chain comparisons)
|
||||
export HAKMEM_TINY_INLINE_SLOTS_SWITCHDISPATCH=${HAKMEM_TINY_INLINE_SLOTS_SWITCHDISPATCH:-1}
|
||||
|
||||
if [[ "${HAKMEM_BENCH_HEADER_LOG:-1}" == "1" ]]; then
|
||||
sha="$(git rev-parse --short HEAD 2>/dev/null || echo unknown)"
|
||||
echo "[SSOT] sha=${sha} bin=${bin} profile=${profile} iters=${iters} ws=${ws} runs=${runs} size=${ssot_min_size}..${ssot_max_size}" >&2
|
||||
fi
|
||||
|
||||
if [[ "${HAKMEM_BENCH_ENV_LOG:-0}" == "1" ]]; then
|
||||
if [[ -x ./scripts/bench_env_banner.sh ]]; then
|
||||
./scripts/bench_env_banner.sh >&2 || true
|
||||
|
||||
Reference in New Issue
Block a user