Skip to content

Commit 35722b7

Browse files
nodejs-github-bottargos
authored andcommitted
deps: update simdjson to 3.10.0
PR-URL: #54197 Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
1 parent 09f411e commit 35722b7

File tree

2 files changed

+675
-146
lines changed

2 files changed

+675
-146
lines changed

Diff for: deps/simdjson/simdjson.cpp

+37-22
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* auto-generated on 2024-06-11 14:08:20 -0400. Do not edit! */
1+
/* auto-generated on 2024-08-01 09:31:50 -0400. Do not edit! */
22
/* including simdjson.cpp: */
33
/* begin file simdjson.cpp */
44
#define SIMDJSON_SRC_SIMDJSON_CPP
@@ -40,6 +40,16 @@
4040
#endif
4141
#endif
4242

43+
// C++ 23
44+
#if !defined(SIMDJSON_CPLUSPLUS23) && (SIMDJSON_CPLUSPLUS >= 202302L)
45+
#define SIMDJSON_CPLUSPLUS23 1
46+
#endif
47+
48+
// C++ 20
49+
#if !defined(SIMDJSON_CPLUSPLUS20) && (SIMDJSON_CPLUSPLUS >= 202002L)
50+
#define SIMDJSON_CPLUSPLUS20 1
51+
#endif
52+
4353
// C++ 17
4454
#if !defined(SIMDJSON_CPLUSPLUS17) && (SIMDJSON_CPLUSPLUS >= 201703L)
4555
#define SIMDJSON_CPLUSPLUS17 1
@@ -224,6 +234,11 @@ using std::size_t;
224234
#define SIMDJSON_NO_SANITIZE_UNDEFINED
225235
#endif
226236

237+
#if defined(__clang__) || defined(__GNUC__)
238+
#define simdjson_pure [[gnu::pure]]
239+
#else
240+
#define simdjson_pure
241+
#endif
227242

228243
#if defined(__clang__) || defined(__GNUC__)
229244
#if defined(__has_feature)
@@ -5949,7 +5964,7 @@ class dom_parser_implementation {
59495964
* Unescape a valid UTF-8 string from src to dst, stopping at a final unescaped quote. There
59505965
* must be an unescaped quote terminating the string. It returns the final output
59515966
* position as pointer. In case of error (e.g., the string has bad escaped codes),
5952-
* then null_nullptrptr is returned. It is assumed that the output buffer is large
5967+
* then null_ptr is returned. It is assumed that the output buffer is large
59535968
* enough. E.g., if src points at 'joe"', then dst needs to have four free bytes +
59545969
* SIMDJSON_PADDING bytes.
59555970
*
@@ -5966,7 +5981,7 @@ class dom_parser_implementation {
59665981
* Unescape a NON-valid UTF-8 string from src to dst, stopping at a final unescaped quote. There
59675982
* must be an unescaped quote terminating the string. It returns the final output
59685983
* position as pointer. In case of error (e.g., the string has bad escaped codes),
5969-
* then null_nullptrptr is returned. It is assumed that the output buffer is large
5984+
* then null_ptr is returned. It is assumed that the output buffer is large
59705985
* enough. E.g., if src points at 'joe"', then dst needs to have four free bytes +
59715986
* SIMDJSON_PADDING bytes.
59725987
*
@@ -6020,14 +6035,14 @@ class dom_parser_implementation {
60206035
*
60216036
* @return Current capacity, in bytes.
60226037
*/
6023-
simdjson_inline size_t capacity() const noexcept;
6038+
simdjson_pure simdjson_inline size_t capacity() const noexcept;
60246039

60256040
/**
60266041
* The maximum level of nested object and arrays supported by this parser.
60276042
*
60286043
* @return Maximum depth, in bytes.
60296044
*/
6030-
simdjson_inline size_t max_depth() const noexcept;
6045+
simdjson_pure simdjson_inline size_t max_depth() const noexcept;
60316046

60326047
/**
60336048
* Ensure this parser has enough memory to process JSON documents up to `capacity` bytes in length
@@ -6068,11 +6083,11 @@ simdjson_inline dom_parser_implementation::dom_parser_implementation() noexcept
60686083
simdjson_inline dom_parser_implementation::dom_parser_implementation(dom_parser_implementation &&other) noexcept = default;
60696084
simdjson_inline dom_parser_implementation &dom_parser_implementation::operator=(dom_parser_implementation &&other) noexcept = default;
60706085

6071-
simdjson_inline size_t dom_parser_implementation::capacity() const noexcept {
6086+
simdjson_pure simdjson_inline size_t dom_parser_implementation::capacity() const noexcept {
60726087
return _capacity;
60736088
}
60746089

6075-
simdjson_inline size_t dom_parser_implementation::max_depth() const noexcept {
6090+
simdjson_pure simdjson_inline size_t dom_parser_implementation::max_depth() const noexcept {
60766091
return _max_depth;
60776092
}
60786093

@@ -12477,7 +12492,7 @@ simdjson_inline error_code json_structural_indexer::finish(dom_parser_implementa
1247712492
}
1247812493
parser.n_structural_indexes = uint32_t(indexer.tail - parser.structural_indexes.get());
1247912494
/***
12480-
* The On Demand API requires special padding.
12495+
* The On-Demand API requires special padding.
1248112496
*
1248212497
* This is related to https://github.com/simdjson/simdjson/issues/906
1248312498
* Basically, we want to make sure that if the parsing continues beyond the last (valid)
@@ -13352,7 +13367,7 @@ simdjson_inline bool handle_unicode_codepoint_wobbly(const uint8_t **src_ptr,
1335213367
* Unescape a valid UTF-8 string from src to dst, stopping at a final unescaped quote. There
1335313368
* must be an unescaped quote terminating the string. It returns the final output
1335413369
* position as pointer. In case of error (e.g., the string has bad escaped codes),
13355-
* then null_nullptrptr is returned. It is assumed that the output buffer is large
13370+
* then null_ptr is returned. It is assumed that the output buffer is large
1335613371
* enough. E.g., if src points at 'joe"', then dst needs to have four free bytes +
1335713372
* SIMDJSON_PADDING bytes.
1335813373
*/
@@ -18696,7 +18711,7 @@ simdjson_inline error_code json_structural_indexer::finish(dom_parser_implementa
1869618711
}
1869718712
parser.n_structural_indexes = uint32_t(indexer.tail - parser.structural_indexes.get());
1869818713
/***
18699-
* The On Demand API requires special padding.
18714+
* The On-Demand API requires special padding.
1870018715
*
1870118716
* This is related to https://github.com/simdjson/simdjson/issues/906
1870218717
* Basically, we want to make sure that if the parsing continues beyond the last (valid)
@@ -19571,7 +19586,7 @@ simdjson_inline bool handle_unicode_codepoint_wobbly(const uint8_t **src_ptr,
1957119586
* Unescape a valid UTF-8 string from src to dst, stopping at a final unescaped quote. There
1957219587
* must be an unescaped quote terminating the string. It returns the final output
1957319588
* position as pointer. In case of error (e.g., the string has bad escaped codes),
19574-
* then null_nullptrptr is returned. It is assumed that the output buffer is large
19589+
* then null_ptr is returned. It is assumed that the output buffer is large
1957519590
* enough. E.g., if src points at 'joe"', then dst needs to have four free bytes +
1957619591
* SIMDJSON_PADDING bytes.
1957719592
*/
@@ -24908,7 +24923,7 @@ simdjson_inline error_code json_structural_indexer::finish(dom_parser_implementa
2490824923
}
2490924924
parser.n_structural_indexes = uint32_t(indexer.tail - parser.structural_indexes.get());
2491024925
/***
24911-
* The On Demand API requires special padding.
24926+
* The On-Demand API requires special padding.
2491224927
*
2491324928
* This is related to https://github.com/simdjson/simdjson/issues/906
2491424929
* Basically, we want to make sure that if the parsing continues beyond the last (valid)
@@ -25783,7 +25798,7 @@ simdjson_inline bool handle_unicode_codepoint_wobbly(const uint8_t **src_ptr,
2578325798
* Unescape a valid UTF-8 string from src to dst, stopping at a final unescaped quote. There
2578425799
* must be an unescaped quote terminating the string. It returns the final output
2578525800
* position as pointer. In case of error (e.g., the string has bad escaped codes),
25786-
* then null_nullptrptr is returned. It is assumed that the output buffer is large
25801+
* then null_ptr is returned. It is assumed that the output buffer is large
2578725802
* enough. E.g., if src points at 'joe"', then dst needs to have four free bytes +
2578825803
* SIMDJSON_PADDING bytes.
2578925804
*/
@@ -31391,7 +31406,7 @@ simdjson_inline error_code json_structural_indexer::finish(dom_parser_implementa
3139131406
}
3139231407
parser.n_structural_indexes = uint32_t(indexer.tail - parser.structural_indexes.get());
3139331408
/***
31394-
* The On Demand API requires special padding.
31409+
* The On-Demand API requires special padding.
3139531410
*
3139631411
* This is related to https://github.com/simdjson/simdjson/issues/906
3139731412
* Basically, we want to make sure that if the parsing continues beyond the last (valid)
@@ -32266,7 +32281,7 @@ simdjson_inline bool handle_unicode_codepoint_wobbly(const uint8_t **src_ptr,
3226632281
* Unescape a valid UTF-8 string from src to dst, stopping at a final unescaped quote. There
3226732282
* must be an unescaped quote terminating the string. It returns the final output
3226832283
* position as pointer. In case of error (e.g., the string has bad escaped codes),
32269-
* then null_nullptrptr is returned. It is assumed that the output buffer is large
32284+
* then null_ptr is returned. It is assumed that the output buffer is large
3227032285
* enough. E.g., if src points at 'joe"', then dst needs to have four free bytes +
3227132286
* SIMDJSON_PADDING bytes.
3227232287
*/
@@ -38448,7 +38463,7 @@ simdjson_inline error_code json_structural_indexer::finish(dom_parser_implementa
3844838463
}
3844938464
parser.n_structural_indexes = uint32_t(indexer.tail - parser.structural_indexes.get());
3845038465
/***
38451-
* The On Demand API requires special padding.
38466+
* The On-Demand API requires special padding.
3845238467
*
3845338468
* This is related to https://github.com/simdjson/simdjson/issues/906
3845438469
* Basically, we want to make sure that if the parsing continues beyond the last (valid)
@@ -39323,7 +39338,7 @@ simdjson_inline bool handle_unicode_codepoint_wobbly(const uint8_t **src_ptr,
3932339338
* Unescape a valid UTF-8 string from src to dst, stopping at a final unescaped quote. There
3932439339
* must be an unescaped quote terminating the string. It returns the final output
3932539340
* position as pointer. In case of error (e.g., the string has bad escaped codes),
39326-
* then null_nullptrptr is returned. It is assumed that the output buffer is large
39341+
* then null_ptr is returned. It is assumed that the output buffer is large
3932739342
* enough. E.g., if src points at 'joe"', then dst needs to have four free bytes +
3932839343
* SIMDJSON_PADDING bytes.
3932939344
*/
@@ -44472,7 +44487,7 @@ simdjson_inline error_code json_structural_indexer::finish(dom_parser_implementa
4447244487
}
4447344488
parser.n_structural_indexes = uint32_t(indexer.tail - parser.structural_indexes.get());
4447444489
/***
44475-
* The On Demand API requires special padding.
44490+
* The On-Demand API requires special padding.
4447644491
*
4447744492
* This is related to https://github.com/simdjson/simdjson/issues/906
4447844493
* Basically, we want to make sure that if the parsing continues beyond the last (valid)
@@ -45347,7 +45362,7 @@ simdjson_inline bool handle_unicode_codepoint_wobbly(const uint8_t **src_ptr,
4534745362
* Unescape a valid UTF-8 string from src to dst, stopping at a final unescaped quote. There
4534845363
* must be an unescaped quote terminating the string. It returns the final output
4534945364
* position as pointer. In case of error (e.g., the string has bad escaped codes),
45350-
* then null_nullptrptr is returned. It is assumed that the output buffer is large
45365+
* then null_ptr is returned. It is assumed that the output buffer is large
4535145366
* enough. E.g., if src points at 'joe"', then dst needs to have four free bytes +
4535245367
* SIMDJSON_PADDING bytes.
4535345368
*/
@@ -50487,7 +50502,7 @@ simdjson_inline error_code json_structural_indexer::finish(dom_parser_implementa
5048750502
}
5048850503
parser.n_structural_indexes = uint32_t(indexer.tail - parser.structural_indexes.get());
5048950504
/***
50490-
* The On Demand API requires special padding.
50505+
* The On-Demand API requires special padding.
5049150506
*
5049250507
* This is related to https://github.com/simdjson/simdjson/issues/906
5049350508
* Basically, we want to make sure that if the parsing continues beyond the last (valid)
@@ -51362,7 +51377,7 @@ simdjson_inline bool handle_unicode_codepoint_wobbly(const uint8_t **src_ptr,
5136251377
* Unescape a valid UTF-8 string from src to dst, stopping at a final unescaped quote. There
5136351378
* must be an unescaped quote terminating the string. It returns the final output
5136451379
* position as pointer. In case of error (e.g., the string has bad escaped codes),
51365-
* then null_nullptrptr is returned. It is assumed that the output buffer is large
51380+
* then null_ptr is returned. It is assumed that the output buffer is large
5136651381
* enough. E.g., if src points at 'joe"', then dst needs to have four free bytes +
5136751382
* SIMDJSON_PADDING bytes.
5136851383
*/
@@ -54563,7 +54578,7 @@ simdjson_inline bool handle_unicode_codepoint_wobbly(const uint8_t **src_ptr,
5456354578
* Unescape a valid UTF-8 string from src to dst, stopping at a final unescaped quote. There
5456454579
* must be an unescaped quote terminating the string. It returns the final output
5456554580
* position as pointer. In case of error (e.g., the string has bad escaped codes),
54566-
* then null_nullptrptr is returned. It is assumed that the output buffer is large
54581+
* then null_ptr is returned. It is assumed that the output buffer is large
5456754582
* enough. E.g., if src points at 'joe"', then dst needs to have four free bytes +
5456854583
* SIMDJSON_PADDING bytes.
5456954584
*/

0 commit comments

Comments
 (0)