[hipDNN] [ALMIOPEN-2037] [ALMIOPEN-2038] cuDNN shim: enum/error and Tensor_attributes aliasing#8744
Open
mousdahl-amd wants to merge 2 commits into
Open
[hipDNN] [ALMIOPEN-2037] [ALMIOPEN-2038] cuDNN shim: enum/error and Tensor_attributes aliasing#8744mousdahl-amd wants to merge 2 commits into
mousdahl-amd wants to merge 2 commits into
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. ❌ Your project status has failed because the head coverage (77.89%) is below the target coverage (80.00%). You can increase the head coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## develop #8744 +/- ##
========================================
Coverage 71.43% 71.44%
========================================
Files 2612 2612
Lines 407002 407033 +31
Branches 60775 60775
========================================
+ Hits 290732 290774 +42
+ Misses 94964 94959 -5
+ Partials 21306 21300 -6
*This pull request uses carry forward flags. Click here to find out more. 🚀 New features to boost your workflow:
|
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.
Summary
Implements the next layer of the cuDNN-compatibility shim for hipDNN (per the cuDNN-shim RFC, RFC 0012): the FE-namespace enum/error aliasing surface and the
graph::Tensor_attributestype. Hipified cuDNN-frontend v9 graph code can declare enums, return error/error_tvalues, use the error/log macros, and construct/configure tensors against the shim with no numeric casts between the cuDNN and hipDNN enum families — the shimusing-aliases the hipDNN types 1:1 rather than wrapping them.Risk Assessment
Low risk. Header-only
using-aliasing plus host-only unit tests, all behind the opt-inHIPDNN_ENABLE_CUDNN_COMPATIBILITYflag. No kernel, dispatch, default-behavior, or public-shipping-API change; the aliased types are the same hipDNN types, so there is no ABI or compatibility surface beyond the new shim headers. Covered by passing unit tests.ASIC Coverage
ASIC-independent. The change is compile-time type aliasing and host-only tests with no kernel selection, support surface, or dispatch behavior impact, so standard PR CI is sufficient; no specific-ASIC run or multi-arch sweep is required.
Testing Summary
HIPDNN_ENABLE_CUDNN_COMPATIBILITY): enum/error aliasing, error macros, status round-trip, handle entry points, the v9-only translation-unit compile gate, andTensor_attributesconstruction/setters/UID/copy-identity.static_asserts in the tests pin that each shim alias is the exact same type as its hipDNN counterpart (alias, not parallel re-declaration).Testing Checklist
hipdnn_frontend_testswith-DHIPDNN_ENABLE_CUDNN_COMPATIBILITY=ON, ran--gtest_filter=TestCudnnShim*(23/23) - Status: PassedTechnical Changes
cudnn_frontend/graph_properties.h, aliasinghipdnn_frontend::graph::TensorAttributes(and itsTensor_attributestypedef) into the shimgraphnamespace; no shim-side UID allocator or identity map — UID handling stays native to hipDNN.cudnn_frontend_utils.h(FE-namespace enum aliases:DataType_t,PointwiseMode_t,ConvolutionMode_t, etc.) andcudnn_frontend/graph_helpers.h(aliasederror_t/error_object/error_code_tand re-exportedCHECK_CUDNN_FRONTEND_ERROR/RETURN_CUDNN_FRONTEND_ERROR_IF/CUDNN_FE_LOG*macros).cudnn_frontend.hand extends the stubcudnn.hC-API types as needed.TestCudnnShimError.cpp,TestCudnnShimTensor.cpp, and theTestCudnnShimV9Tu.cppv9-only compile gate; registers them in the frontend tests CMakeLists.Tensor_attributesaliases the setters hipDNN publishes 1:1 (set_dim/set_stride/set_data_type/set_uid/set_is_virtual/set_output/set_name);set_is_pass_by_value(modeled by hipDNN's typedset_value) andset_ragged_offset(no ragged-tensor support yet) are intentionally deferred until their consuming nodes land.