Repository navigation
Benchmarks: Refine GPU stream performance with autotune and preconfig - #895
Open
WenqingLan1 wants to merge 8 commits into
Open
WenqingLan1 wants to merge 8 commits into
WenqingLan1 wants to merge 8 commits into
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The new default allocates 24 GiB across three arrays, breaking existing invocations on 16 GiB GPUs; both Python and native defaults need a capacity-safe fallback.
1 open issue
What changed in this PR
This PR adds explicit GPU-specific presets and a fixed autotuning sweep to the GPU STREAM benchmark, reporting one winning measurement per operation and datatype.
Changes:
- Add packaged launch profiles for
h100,gb300, andvr, with validated parameter handling. - Implement block/unroll sweeps, scalar-tail handling, and canonical bandwidth results.
- Update tests, documentation, and the example for preset selection and autotuning.
| File | Description |
|---|---|
tests/benchmarks/micro_benchmarks/test_gpu_stream.py |
Tests presets, fallback commands, validation, and result parsing. |
superbench/benchmarks/micro_benchmarks/gpu_stream/gpu_stream.hpp |
Updates the kernel timing interface. |
superbench/benchmarks/micro_benchmarks/gpu_stream/gpu_stream.cu |
Runs configured sweeps and reports winning measurements. |
superbench/benchmarks/micro_benchmarks/gpu_stream/gpu_stream_utils.hpp |
Defines launch configurations and updated defaults. |
superbench/benchmarks/micro_benchmarks/gpu_stream/gpu_stream_utils.cpp |
Validates native arguments and adds launch selectors. |
superbench/benchmarks/micro_benchmarks/gpu_stream/gpu_stream_kernels.hpp |
Implements tiled kernels, unrolling, and scalar tails. |
superbench/benchmarks/micro_benchmarks/gpu_stream/gpu_stream_kernels.cu |
Shortens the template compilation-unit explanation. |
superbench/benchmarks/micro_benchmarks/gpu_stream.py |
Selects presets, generates commands, and parses canonical results. |
superbench/benchmarks/micro_benchmarks/gpu_stream_profiles.json |
Provides chip-specific buffer and launch settings. |
MANIFEST.in |
Includes the profile JSON in distribution files. |
examples/benchmarks/gpu_stream.py |
Demonstrates both datatypes and describes preset selection. |
docs/user-tutorial/benchmarks/micro-benchmarks.md |
Documents presets, fallback behavior, and revised metrics. |
Review effort: Balanced
| _OPERATIONS = ['copy', 'scale', 'add', 'triad'] | ||
| _BLOCKS = [128, 256, 512, 1024] | ||
| _UNROLLS = [1, 2, 3, 4, 6, 8] | ||
| _DEFAULT_SIZE = 8 * 1024**3 |
Co-authored-by: dpower4 <[email protected]> Co-authored-by: Copilot <[email protected]>
Comment on lines
+36
to
+37
| self._parser.add_argument('--kernel_configs', type=str, default=None, | ||
| help='JSON mapping of workload tags to block_size/unroll. Omit to autotune.') |
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
The rewritten CUDA kernels and launch dispatch need GPU validation across datatypes, non-tile-aligned sizes, and sweep configurations because mocked tests cannot establish native correctness or bandwidth accuracy.
2 open issues
Review effort: Balanced
Contributor
|
/azp run |
|
Azure Pipelines: Successfully started running 3 pipeline(s). |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Description
Rework GPU STREAM bandwidth benchmarking with automatic per-operation launch tuning and optional fixed configurations.
Major Revision
kernel_configsJSON overrides, with fallback tuning for unlisted operations.Minor Revision