Generic wrapper program, detects SIMD CPU extensions and launches an appropriate sub-process.
Will launch one of: ProgramName.avx2, ProgramName.avx, ProgramName.sse42, ProgramName.sse41 or ProgramName.noext as appropriate (passing all parameters). Executables must be on the same path as the wrapper. More extensions will be added when needed.
Just compile SIMDExtensionWrapper.cpp. Define the macro "ProgramName" (... -DProgramName=MyProgramName) to decorate output messages.
Tested on Linux, MacOS and Windows using clang.
stb_sprintf.h (https://github.com/nothings/stb/blob/master/stb_sprintf.h)