Repository navigation
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/23597
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit f7868bd with merge base bdb489e ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This PR needs a
|
This branch was successfully 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.
Stack from ghstack (oldest at bottom):
Ulterior Motive
Restructure the Vulkan operator test+benchmark binaries around a single
etvk_benchmarkentry point with registered, per-operator test case sets, so related cases (such as a model's bottleneck shapes) can be grouped and run in isolation.Rationale
What: Move the test+benchmark binaries, their shared utilities, and the test-only ops and shaders from
test/custom_ops/intotest/ops/benchmark/, with one subdirectory per operator undercases/, and split the monolithicutils.{h,cpp}by topic.Why: The flat
custom_ops/directory mixes benchmark binaries, framework code, test-only ops, and correctness-only gtests, andutils.{h,cpp}(3.5k lines) mixes value specs, test cases, execution, and reporting. Grouping the binaries by operator gives the upcoming case-set registration a home for each operator's cases and reference code.Details
test/ops/benchmark/framework/: test framework utilities,conv2d_utils,cm_utils, andtest_coopmat_probe.test_ops/impl/andtest_ops/glsl/: test-only ops and shaders, formerlyimpl/andglsl/.cases/: one directory per operator,conv2d/(direct, depthwise, pointwise),conv1d/,q8csw_conv2d/,q4gsw_linear/(includingtest_fpa_q4gsw_linearandtest_coopmat_linear_bench),q8csw_linear/,mm/,sdpa/,embedding_q4gsw/,choose_qparams_per_row/,add/;cases/q8ta/collects the q8ta operators:conv2d/,conv2d_transposed/,linear/,binary/,unary/,clone/,pixel_shuffle/,qdq/.utils.{h,cpp}splitconfig: global output and debugging options.labels.h: test case naming helpers.value_spec:ValueSpec, data generation, half-precision conversion, andprint_valuespec_data.test_case:ReferenceKey, the shader filter defaults, andTestCase.results:BenchmarkResult,TestResult, and table printing.runner: graph setup,RepeatedGraphExecutor, andexecute_test_case(s).weight_utils: weight canvases and weight sum helpers.utils.hincludes all of the above, so binaries are unchanged.expliciton the single-argumentBenchmarkResult,TestResult, andTestCaseconstructors,const&for the generator, reference, FLOP calculator, andop_nameparameters,utils::safe_downcast<int>for one narrowing,(void)for an unused parameter, andNOLINTNEXTLINEon enumswitches that list only some enumerators (each has adefault) and on theusing namespace vkcomputethat binaries rely on.utils.hno longer includes<iostream>.test/ops/benchmark/{BUCK,targets.bzl}define the binaries,prototyping_utils,operator_implementations, andcustom_ops_shaderlib. Binary target names are unchanged; only the package path changes.build_and_run.shmove with the binaries and take source paths from the new subdirectories.utils_test,q8ta_conv2d_route_test,q8ta_conv2d_stream_plan_test) stay intest/custom_ops/;utils_testnow depends onprototyping_utilsin its new package.executorch/backends/vulkan/test/ops/benchmark/framework/utils.h).vulkan.ymlandpull.ymlworkflows.BUCK/targets.bzland the split framework files are recorded as copies.Binary sources, test cases, and test-only ops are otherwise unchanged.
Differential Revision: D123690842