Repository navigation
Allow public tuning of non-ByKey cub::DeviceScan - #8853
Conversation
|
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
This comment has been minimized.
This comment has been minimized.
cub::DeviceScancub::DeviceScan
This comment has been minimized.
This comment has been minimized.
|
Turned to draft to prevent accidental merging. Waiting for #7671 to be resolved. |
53876f5 to
c01dbcb
Compare
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
suggestion: Walkthroughsuggestion: Exposes public LookbackDelay and Scan policy types and replaces internal delay/scan detail types across tuning tables, dispatch, kernels, NVRTC templates, benchmarks, helpers, docs, and tests. ChangesDelay and Scan Policy API Productization
Assessment against linked issues
Possibly related issues
Suggested reviewers
Warning Review ran into problems🔥 ProblemsGit: Failed to clone repository. Please run the Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
cub/cub/device/dispatch/tuning/tuning_scan.cuh (1)
130-141: 💤 Low valuesuggestion: Missing
[[nodiscard]]on equality operators forScanWarpspeedPolicy, inconsistent withScanLookbackPolicy(lines 79, 88) andScanPolicy(lines 162, 167) which have them.- _CCCL_HOST_DEVICE_API constexpr friend bool operator==(const ScanWarpspeedPolicy& lhs, const ScanWarpspeedPolicy& rhs) + [[nodiscard]] _CCCL_HOST_DEVICE_API constexpr friend bool operator==(const ScanWarpspeedPolicy& lhs, const ScanWarpspeedPolicy& rhs) { return lhs.num_reduce_and_scan_warps == rhs.num_reduce_and_scan_warps && lhs.look_ahead_items_per_thread == rhs.look_ahead_items_per_thread && lhs.items_per_thread == rhs.items_per_thread && lhs.lookahead_stages == rhs.lookahead_stages && lhs.block_idx_stages == rhs.block_idx_stages; } - _CCCL_HOST_DEVICE_API constexpr friend bool operator!=(const ScanWarpspeedPolicy& lhs, const ScanWarpspeedPolicy& rhs) + [[nodiscard]] _CCCL_HOST_DEVICE_API constexpr friend bool operator!=(const ScanWarpspeedPolicy& lhs, const ScanWarpspeedPolicy& rhs) { return !(lhs == rhs); }
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: 647d0420-c261-4627-942a-7f98f699739a
📒 Files selected for processing (29)
c/parallel/src/radix_sort.cuc/parallel/src/scan.cuc/parallel/src/unique_by_key.cucub/benchmarks/bench/copy/memcpy.cucub/benchmarks/bench/scan/policy_selector.hcub/cub/detail/delay_constructor.cuhcub/cub/device/device_scan.cuhcub/cub/device/dispatch/dispatch_radix_sort.cuhcub/cub/device/dispatch/dispatch_rle.cuhcub/cub/device/dispatch/dispatch_scan.cuhcub/cub/device/dispatch/dispatch_select_if.cuhcub/cub/device/dispatch/dispatch_three_way_partition.cuhcub/cub/device/dispatch/kernels/kernel_radix_sort.cuhcub/cub/device/dispatch/kernels/kernel_scan.cuhcub/cub/device/dispatch/kernels/kernel_scan_warpspeed.cuhcub/cub/device/dispatch/tuning/tuning_batch_memcpy.cuhcub/cub/device/dispatch/tuning/tuning_radix_sort.cuhcub/cub/device/dispatch/tuning/tuning_reduce_by_key.cuhcub/cub/device/dispatch/tuning/tuning_rle_encode.cuhcub/cub/device/dispatch/tuning/tuning_rle_non_trivial_runs.cuhcub/cub/device/dispatch/tuning/tuning_scan.cuhcub/cub/device/dispatch/tuning/tuning_scan_by_key.cuhcub/cub/device/dispatch/tuning/tuning_select_if.cuhcub/cub/device/dispatch/tuning/tuning_three_way_partition.cuhcub/cub/device/dispatch/tuning/tuning_unique_by_key.cuhcub/test/catch2_test_device_scan_env.cucub/test/catch2_test_device_scan_env_api.cunvbench_helper/nvbench_helper/look_back_helper.cuhthrust/testing/scan.cu
This comment has been minimized.
This comment has been minimized.
b9f1a1d to
6410670
Compare
This comment has been minimized.
This comment has been minimized.
6410670 to
4a2d89e
Compare
🥳 CI Workflow Results🟩 Finished in 1h 21m: Pass: 100%/354 | Total: 2d 13h | Max: 40m 45s | Hits: 99%/327737See results here. |
| enum class ScanAlgorithm | ||
| { | ||
| lookback, | ||
| warpspeed |
There was a problem hiding this comment.
Food for thought: I am wondering whether it would be wise to rename this to lookahead
Warpspeed is the library we use to implement the lookahead algorithm.
There was a problem hiding this comment.
Oh man, we have had that discussion a few times already and I am sick of renaming :S
This PR makes all tuning policies required for
cub::DeviceScanpublic and adds tests+documentation.DispatchScanandAgentScanPolicywill be deprecated in a follow-up PR: #9234Fixes: #8578
New public entities
cub::LookbackDelayAlgorithmno_delay,fixed_delay,exponential_backoff,exponential_backoff_jitter,exponential_backoff_jitter_window,exponential_backon_jitter_window,exponential_backon_jitter,exponential_backoncub::LookbackDelayPolicykind(LookbackDelayAlgorithm),delay,l2_write_latencycub::ScanAlgorithmlookback,warpspeedcub::ScanLookbackPolicythreads_per_block,items_per_thread,load_algorithm,load_modifier,store_algorithm,scan_algorithm,delay_constructor(LookbackDelayPolicy)cub::ScanWarpspeedPolicyreduce_and_scan_warps,items_per_thread,lookahead_items_per_thread,lookahead_stages,block_idx_stagescub::ScanPolicyalgorithm(ScanAlgorithm),lookback(ScanLookbackPolicy),warpspeed(ScanWarpspeedPolicy)