Skip to content

Use filter_hip_architectures for hipTensor examples#454

Open
mapatel-amd wants to merge 3 commits into
amd-stagingfrom
mapatel/hiptensor-arch-check
Open

Use filter_hip_architectures for hipTensor examples#454
mapatel-amd wants to merge 3 commits into
amd-stagingfrom
mapatel/hiptensor-arch-check

Conversation

@mapatel-amd
Copy link
Copy Markdown

Closes #333

Replaces the hiptensor_is_supported_architecture per-arch loop in all hipTensor CMakeLists files with the shared filter_hip_architectures utility introduced in 1d19858.

Changes

  • All 21 hipTensor CMakeLists.txt files updated (root + 20 sub-examples)
  • Hardcoded supported arch list gfx908;gfx90a;gfx942;gfx950 sourced from hipTensor documentation
  • Gracefully skips unsupported architectures with a warning instead of a fatal error, allowing mixed-arch builds to proceed on supported targets

Behaviour

  • Supported arch only → builds normally
  • Unsupported arch only → warns and skips
  • Mixed archs → warns about removed archs, builds for remaining supported ones

@mapatel-amd mapatel-amd requested a review from a team as a code owner May 19, 2026 18:13
@mapatel-amd mapatel-amd self-assigned this May 19, 2026
@mapatel-amd mapatel-amd force-pushed the mapatel/hiptensor-arch-check branch from 9f7a9a9 to e29951a Compare May 20, 2026 14:09
endif()
endforeach()
include("${CMAKE_CURRENT_LIST_DIR}/../../../../../Common/FilterHIPArchitectures.cmake")
filter_hip_architectures("hipTensor" "gfx908;gfx90a;gfx942;gfx950" SHOULD_SKIP)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here, could we get these archs from hipTensor so we don't need to maintain the list here? Use something from hiptensorSupportedArchitectures.cmake

Copy link
Copy Markdown
Collaborator

@zichguan-amd zichguan-amd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also look into the Makefiles with filter_hip_architectures.mk?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants