From d8a057ab7aee73783e10c03fd61daad75b173b37 Mon Sep 17 00:00:00 2001 From: Daniel Lemire Date: Wed, 2 Dec 2026 22:52:53 -0500 Subject: [PATCH] Build with simdjson 5.3.0, which renamed write_uint_jeaiii to write_uint simdjson 5.3.0 renamed simdjson::internal::write_uint_jeaiii to write_uint: call the new name, download simdjson 5.3.0, and require 5.3.0 or later. --- .github/workflows/release.yml | 2 +- CMakeLists.txt | 2 +- README.md | 4 ++-- src/ndjson_writer.cpp | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 7e25f86..47870ad 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -12,7 +12,7 @@ on: workflow_dispatch: env: - SIMDJSON_VERSION: v5.1.1 + SIMDJSON_VERSION: v5.3.0 jobs: test: diff --git a/CMakeLists.txt b/CMakeLists.txt index 830f25f..51d6ac6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -18,7 +18,7 @@ option(SIMDJSON_ARROW_ARROW_CPP "Build the example and the benchmark that use Ar include(FetchContent) FetchContent_Declare(simdjson - URL https://github.com/simdjson/simdjson/archive/refs/tags/v5.1.1.tar.gz + URL https://github.com/simdjson/simdjson/archive/refs/tags/v5.3.0.tar.gz DOWNLOAD_EXTRACT_TIMESTAMP TRUE) set(SIMDJSON_DEVELOPER_MODE OFF CACHE BOOL "" FORCE) FetchContent_MakeAvailable(simdjson) diff --git a/README.md b/README.md index cb7d7e5..3a22c2c 100644 --- a/README.md +++ b/README.md @@ -42,7 +42,7 @@ The simplest way: take two files from a [release](https://github.com/simdjson/simdjson_arrow/releases), `simdjson_arrow.h` and `simdjson_arrow.cpp` (or `singleheader.zip`, which holds both), and the two files of a [simdjson release](https://github.com/simdjson/simdjson/releases) -(5.0.7 or later), `simdjson.h` and `simdjson.cpp`. Put the four files in one +(5.3.0 or later), `simdjson.h` and `simdjson.cpp`. Put the four files in one directory, include `simdjson_arrow.h`, and compile the two source files with yours, as C++17: @@ -368,7 +368,7 @@ cmake --build build ctest --test-dir build # the C++ tests and the example ``` -CMake downloads simdjson 5.1.1. Options: `SIMDJSON_ARROW_TESTS`, +CMake downloads simdjson 5.3.0. Options: `SIMDJSON_ARROW_TESTS`, `SIMDJSON_ARROW_BENCHMARKS` and `SIMDJSON_ARROW_EXAMPLES` (on by default), and `SIMDJSON_ARROW_ARROW_CPP` (off), which builds `examples/arrow_cpp.cpp` and `benchmarks/bench_arrow_cpp.cpp` against an installed Arrow C++ (with diff --git a/src/ndjson_writer.cpp b/src/ndjson_writer.cpp index ad6c2b0..cba5e6c 100644 --- a/src/ndjson_writer.cpp +++ b/src/ndjson_writer.cpp @@ -56,7 +56,7 @@ class output { void append_bool(bool b) { append_raw(b ? std::string_view("true") : std::string_view("false")); } void append_uint(uint64_t x) { char* p = reserve(20); - size_ = simdjson::internal::write_uint_jeaiii(p, x) - data_; + size_ = simdjson::internal::write_uint(p, x) - data_; } void append_int(int64_t x) { char* p = reserve(20); @@ -64,7 +64,7 @@ class output { *p = '-'; p += negative; const uint64_t magnitude = negative ? 0 - static_cast(x) : static_cast(x); - size_ = simdjson::internal::write_uint_jeaiii(p, magnitude) - data_; + size_ = simdjson::internal::write_uint(p, magnitude) - data_; } // x must be finite. We write the shortest representation that gives back x, // with a decimal point or an exponent (1.0, not 1), so that the number reads