Skip to content
Discussion options

You must be logged in to vote

@MBkkt

with ondemand such use case needs to be recursive :(

This code looks very good to me: https://github.com/ydb-platform/ydb/blob/74df9273b222dc253487508e6f4602237f4a7c11/ydb/library/binary_json/write.cpp#L553

❤️

We get pretty decent results with recursion and the code is relatively elegant. The one annoying caveat is that GCC and LLVM differ in how they handle recursion in practice, so a bit of care is needed if one wants to get good performance. But that's relatively minor.

Please see...

https://github.com/simdjson/simdjson/blob/master/benchmark/json2msgpack/simdjson_ondemand.h

Depending on your compiler, you might get better result when passing by value instead of by reference.

I…

Replies: 1 comment 7 replies

Comment options

You must be logged in to vote
7 replies
@MBkkt
Comment options

@lemire
Comment options

Answer selected by MBkkt
@MBkkt
Comment options

@lemire
Comment options

@MBkkt
Comment options

@MBkkt
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants