A high-throughput and memory-efficient inference and serving engine for LLMs
Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git
Synced Nov 13, 02:00 UTC
Cast return value to int64_t for cache size (#28814)
Signed-off-by: tiehexue <tiehexue@hotmail.com>
tiehexue committed
Nov 18, 2025 at 00:02 UTC
e42bd8c2e3bfecdaf9c5a7ad99d7c7d7cb75a7b5
1 file changed
+1
-1
csrc/cpu/cpu_attn_impl.hpp
+1
-1
@@ -754,7 +754,7 @@ class AttentionScheduler {
754
return l2_cache_size >> 1; // use 50% of L2 cache
755
}
756
// Fallback if sysctlbyname fails
757
- return 128 * 1024 >> 1; // use 50% of 128KB
757
+ return 128LL * 1024 >> 1; // use 50% of 128KB
758
#else
759
long l2_cache_size = sysconf(_SC_LEVEL2_CACHE_SIZE);
760
TORCH_CHECK_NE(l2_cache_size, -1);