Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run get_json_object_multiple_paths with thread-parallel kernel based on number of paths #2256

Closed
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Change path size threshold
Signed-off-by: Nghia Truong <nghiat@nvidia.com>
  • Loading branch information
ttnghia committed Jul 25, 2024
commit 09d7105815e74168f0b281365aa168395edb97a4
4 changes: 2 additions & 2 deletions src/main/cpp/src/get_json_object.cu
Original file line number Diff line number Diff line change
Expand Up @@ -1075,8 +1075,8 @@ std::vector<std::unique_ptr<cudf::column>> get_json_object(
rmm::exec_policy(stream), d_has_out_of_bound.begin(), d_has_out_of_bound.end(), 0);

// Threshold to decide on using thread parallel or warp parallel algorithms.
constexpr int64_t PATH_SIZE_THRESHOLD = 2;
auto const exec_thread_parallel = json_paths.size() > PATH_SIZE_THRESHOLD;
constexpr int64_t PATH_SIZE_THRESHOLD = 8;
auto const exec_thread_parallel = json_paths.size() >= PATH_SIZE_THRESHOLD;
launch_kernel(exec_thread_parallel, *d_input_ptr, d_path_data, stream);

// Do not use parallel check since we do not have many elements.
Expand Down
Loading