Odin
Odin copied to clipboard
Add more `ODIN_*` global constants.
When benchmarking the influence of compiler versions on a piece of code, it would be nice to print the compiler version (and options) it was compiled with.
Presently this is limited to:
fmt.printf("Compiled with Odin %v.\n\t- Asserts disabled: %v\n\n", ODIN_VERSION, ODIN_DISABLE_ASSERT)
Compiled with Odin dev-2022-12.
- Asserts disabled: false
To be added:
ODIN_VERSION_HASH(either git hash or-devif unknown)ODIN_OPTIMIZATION_MODE(speed,size,minimal, from-o:)ODIN_DISABLE_BOUNDS_CHECK(falseby default,truewith-no-bounds-check)ODIN_MICROARCH_STRING(e.g.native, from-microarch:)