| Input filename | Size (MB) | Content |
|---|---|---|
| data/output/persons.json | 540.82 | Text,integers |
| Environment | Windows, Intel |
|---|---|
| Computer | Lenovo Thinkpad X Extreme with 8 cores, 16 hardware threads, 32 GB memory, 2 TB solid state drive |
| Operating system | Windows 2011 |
| Compiler | Visual Studio 2022 Version 17.14.16 |
| Optimization | /O2,/Ot |
| Language | /std:c++23preview |
| Library | Version | Type to read into/write from |
|---|---|---|
| jsoncons | 1.7.0 | jsoncons::json |
| nlohmann | 3.12.0 | nlohmann::json |
| rapidjson | 1.1.0 | rapidjson::Document |
| jsoncpp | 1.9.6 | Json::Value |
| glaze | 7.4.0 | glz::generic |
| Boost.JSON | 1_90 | boost::json::value |
| yyjson | 0.12.0 | yyjson_doc |
| reflect-cpp | 0.24.0 | rfl::Generic |
| Library | Time to read (s) | Time to write (s) | Physical memory footprint of json value (MB) | Notes |
|---|---|---|---|---|
| jsoncons | 3.733 | 0.72 | 343 | Uses sorted std::vector of key/value pairs for objects, expect smaller memory footprint.Uses slightly modified grisu3_59_56 implementation by Florian Loitsch plus fallback for printing doubles, expect faster serializing. |
| nlohmann | 8.355 | 2.866 | 409 | Uses std::map for objects. Uses slightly modified Grisu2 implementation by Florian Loitsch for printing doubles, expect faster serializing. |
| rapidjson | 2.228 | 0.642 | 332 | Uses custom floating point parsing, expect faster parsing. Uses girsu3 for printing doubles, expect faster serializing. Uses custom allocation and flat map for objects, expect smaller memory footprint. |
| jsoncpp | 15.929 | 7.425 | 1985 | Uses std::map for both arrays and objects, expect larger memory footprint. |
| glaze | 3.336 | 1.207 | 880 | |
| Boost.JSON | 2.213 | 0.73 | 502 | |
| yyjson | 1.017 | 0.283 | 871 | |
| reflect-cpp | 11.064 | 3.128 | 832 | Uses yyjson for serializing and deserializing JSON. |