VoxelForgeCoreThreadLocal::FLazy<T> (new public header ThreadLocalStorage.h) makes every large thread_local cache a pointer that heap-allocates on that thread's first use (still worker-private, lock-free). Static TLS 17.33 MiB -> 43 KiB (initialised image 5.8 MiB -> 21 KiB); worker start 5.2 -> 0.12 ms; idle worker RSS 17.7 MiB -> 52 KiB. Linux workers back to 8 MiB stacks. World unchanged (L1 hashes Clang off/GCC default, W1/W12; FloatingIslands seed 0). Reviewer interleaved W12: 2.256 -> 2.091 s. MSVC/UBT not compiled here. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ED33VnqepD4YY6gDAAA832
12 lines
270 B
C++
12 lines
270 B
C++
#include "StandaloneTlsProbe.h"
|
|
|
|
#include <cstdlib>
|
|
#include <string_view>
|
|
|
|
int main(int argc,char** argv)
|
|
{
|
|
const int workers=argc>1?std::atoi(argv[1]):12;
|
|
const std::string_view touch=argc>2?argv[2]:"none";
|
|
return StandaloneTlsProbe::Run(workers,touch);
|
|
}
|