output
+
+
+```CSV
+Processing all files and saving to 'cbenchmark.dat'...
+ done in 0.0s. Run 'ClangBuildAnalyzer --analyze cbenchmark.dat' to analyze it.
+Analyzing build trace from 'cbenchmark.dat'...
+**** Time summary:
+Compilation (2 times):
+ Parsing (frontend): 0.4 s
+ Codegen & opts (backend): 0.0 s
+
+**** Files that took longest to parse (compiler frontend):
+ 423 ms: build_clang/CMakeFiles/cbenchmark.dir/examples/cbenchmark.cpp.o
+
+**** Templates that took longest to instantiate:
+ 187 ms: FIX8::conjure_enum (1 times, avg 187 ms)
+ 119 ms: FIX8::conjure_enum::_entries<0UL, 1UL, 2UL, 3UL, 4UL, 5UL... (1 times, avg 119 ms)
+ 8 ms: FIX8::conjure_enum::_sorted_entries (1 times, avg 8 ms)
+ 6 ms: std::sort> *, boo... (1 times, avg 6 ms)
+ 6 ms: std::__sort> *, _... (1 times, avg 6 ms)
+ 5 ms: std::__introsort_loop>, 72> (1 times, avg 3 ms)
+ 2 ms: std::tuple, char, std::basic_string_vie... (1 times, avg 2 ms)
+ 2 ms: std::__unguarded_partition_pivot> *... (1 times, avg 2 ms)
+ 2 ms: std::__partial_sort> (1 times, avg 2 ms)
+ 2 ms: std::__heap_select>... (1 times, avg 2 ms)
+ 1 ms: std::optional (1 times, avg 1 ms)
+ 1 ms: std::to_array, char, std::ba... (1 times, avg 1 ms)
+ 1 ms: std::basic_string (1 times, avg 1 ms)
+ 1 ms: std::basic_string (1 times, avg 1 ms)
+ 1 ms: std::__adjust_heap (1 times, avg 1 ms)
+ 1 ms: std::basic_string (1 times, avg 1 ms)
+ 1 ms: std::basic_string (1 times, avg 1 ms)
+ 1 ms: std::__and_, std::__is_swappable, char, std::basic_s... (1 times, avg 1 ms)
+ 1 ms: std::__final_insertion_sort::_M_construct (1 times, avg 1 ms)
+ 1 ms: std::basic_string::_M_construct (1 times, avg 1 ms)
+ 1 ms: std::basic_string::_M_construct (1 times, avg 1 ms)
+ 1 ms: std::operator+, std::allocator> (1 times, avg 1 ms)
+
+**** Template sets that took longest to instantiate:
+ 187 ms: FIX8::conjure_enum<$> (1 times, avg 187 ms)
+ 119 ms: FIX8::conjure_enum<$>::_entries<$> (1 times, avg 119 ms)
+ 49 ms: FIX8::conjure_enum<$>::_get_name<$> (72 times, avg 0 ms)
+ 12 ms: std::tuple<$>::tuple<$> (21 times, avg 0 ms)
+ 8 ms: FIX8::conjure_enum<$>::_sorted_entries (1 times, avg 8 ms)
+ 7 ms: std::basic_string<$> (5 times, avg 1 ms)
+ 6 ms: std::sort<$> (1 times, avg 6 ms)
+ 6 ms: std::__sort<$> (1 times, avg 6 ms)
+ 5 ms: std::basic_string<$>::_M_construct<$> (5 times, avg 1 ms)
+ 5 ms: std::tuple<$> (2 times, avg 2 ms)
+ 5 ms: std::__introsort_loop<$> (1 times, avg 5 ms)
+ 4 ms: std::array<$> (2 times, avg 2 ms)
+ 2 ms: std::__unguarded_partition_pivot<$> (1 times, avg 2 ms)
+ 2 ms: std::__and_<$> (3 times, avg 0 ms)
+ 2 ms: std::__move_median_to_first<$> (1 times, avg 2 ms)
+ 2 ms: std::iter_swap<$> (1 times, avg 2 ms)
+ 2 ms: std::__partial_sort<$> (1 times, avg 2 ms)
+ 2 ms: std::__heap_select<$> (1 times, avg 2 ms)
+ 2 ms: std::__make_heap<$> (1 times, avg 2 ms)
+ 1 ms: std::_Tuple_impl<$> (2 times, avg 0 ms)
+ 1 ms: std::optional<$> (1 times, avg 1 ms)
+ 1 ms: std::to_array<$> (1 times, avg 1 ms)
+ 1 ms: std::__adjust_heap<$> (1 times, avg 1 ms)
+ 1 ms: std::basic_string<$>::basic_string (2 times, avg 0 ms)
+ 1 ms: std::__final_insertion_sort<$> (1 times, avg 1 ms)
+ 1 ms: std::operator+, std::allocator> (1 times, avg 1 ms)
+ 1 ms: std::__insertion_sort<$> (1 times, avg 1 ms)
+ 0 ms: FIX8::conjure_enum<$>::_tuple_comp_rev (1 times, avg 0 ms)
+ 0 ms: std::tuple>::operator= (1 times, avg 0 ms)
+ 0 ms: __gnu_cxx::__to_xstring<$> (1 times, avg 0 ms)
+
+**** Functions that took longest to compile:
+ 0 3s: test_conjure_enum(std::errc) (/home/davidd/prog/conjure_enum_tclass/examples/cbenchmark.cpp)
+
+**** Function sets that took longest to compile / optimize:
+
+**** Expensive headers:
+166 ms: /usr/include/c++/14/system_error (included 1 times, avg 166 ms), included via:
+ 1x:
+
+54 ms: /home/davidd/prog/conjure_enum_tclass/include/fix8/conjure_enum.hpp (included 1 times, avg 54 ms), included via:
+ 1x:
+
+ done in 0.0s.
+```
+
+
+
+---
+# 9. Benchmarks
+We have benchmarked compilation times for `conjure_enum` and `magic_enum`.
+For `magic_enum` we created a separate repo (see [here](https://github.com/fix8mt/magic_enum_benchmark)).
+
+| Compiler | `conjure_enum` (secs) | `magic_enum` (secs)| Notes |
+| :--- | :--- | :--- |:--- |
+| **MSVC** | 0.376 | 0.343 | using cl from command prompt|
+|_command_ | `cl /nologo /MD /std:c++latest /Bt+ /I ..\include ..\examples\cbenchmark.cpp\|find "c1xx.dll"` | `cl /nologo /MD /std:c++latest /Bt+ -I build\_deps\magic_enum-src\include cbenchmark.cpp\|find "c1xx.dll"`||
+| **clang** | 0.3 | 0.3 | using ClangBuildAnalyzer|
+|_command_|`make`; `ClangBuildAnalyzerLoc=~/prog/ClangBuildAnalyzer/build ArtifactLoc=build_clang examples/cbenchmark.sh`|`make`; `ClangBuildAnalyzerLoc=~/prog/ClangBuildAnalyzer/build ArtifactLoc=build_clang ./cbenchmark.sh`||
+
+## Notes
+- Benchmark run 10 times, best result shown
+- Both benchmarks are using [cbenchmark.sh](examples/cbenchmark.sh) and [cbenchmark.cpp](examples/cbenchmark.cpp)
+- MSVC: Windows 11 ThinkCentre 16x 13th Gen Intel i7-13700, 32Gb; MSVC 2022 / 17.11.0.
+- Clang: Ubuntu 24.04 12th Gen Intel i9-12900T, 32Gb; Clang 18.1.3
+- `magic_enum`: single header only
+- `conjure_enum`: minimal build
+
+## Discussion
+For MSVC, `magic_enum` compilation times a slighly better than `conjure_enum` (around %9). For clang the results are identical.
+From a compilation performance perspective, `conjure_enum` roughly matches the performance of `magic_enum`.
---
-# 8. Compiler support
+# 10. Compiler support
| Compiler | Version(s) | Notes | Unsupported |
| :--- | :--- | :--- | ---: |
| [gcc](https://gcc.gnu.org/projects/cxx-status.html) | `11`, `12`, `13`, `14`| `std::format` not complete in `11`, `12` | `<= 10` |
| [clang](https://clang.llvm.org/cxx_status.html) | `15`, `16`, `17`, `18`| Catch2 needs `cxx_std_20` in `15` | `<= 14` |
-| [msvc](https://learn.microsoft.com/en-us/cpp/overview/visual-cpp-language-conformance) | `16`, `17` | Visual Studio 2019,2022, latest `17.10.5`| `<= 16.9`|
-| [xcode](https://developer.apple.com/support/xcode/) | `15` | Apple LLVM 15.0.0, some issues with `constexpr`, workarounds| `<= 14`|
+| [msvc](https://learn.microsoft.com/en-us/cpp/overview/visual-cpp-language-conformance) | `16`, `17` | Visual Studio 2019,2022, latest `17.11.2`| `<= 16.9`|
+| [xcode](https://developer.apple.com/support/xcode/) | `15` | Apple Xcode Clang 15.0.0 (LLVM 16), some issues with `constexpr`, workarounds| `<= 14`|
-# 9. Compiler issues
+# 11. Compiler issues
| Compiler | Version(s) | Issues | Workaround |
| :--- | :--- | :--- | ---: |
| clang | `16`, `17`, `18`| Compiler reports integers outside valid range [x,y]| specify underlying type when declaring enum eg. `enum class foo : int` |
diff --git a/examples/cbenchmark.cpp b/examples/cbenchmark.cpp
index 31620db9..d396bcf8 100644
--- a/examples/cbenchmark.cpp
+++ b/examples/cbenchmark.cpp
@@ -28,16 +28,35 @@
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
// SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//----------------------------------------------------------------------------------------
-#include