Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[tuner]: add property functions to lowering config python binding #19376

Merged
merged 6 commits into from
Dec 7, 2024

Conversation

bangtianliu
Copy link
Contributor

This PR introduces additional property functions to the LoweringConfig Python binding. These new functions enable direct extraction of the following attributes: workgroup, reduction, subgroup_m_count, subgroup_n_count, and mma_kind directly from the lowering config python binding.

This PR is relevant to the task in nod-ai/shark-ai#453: use IREE bindings for compilation info (incl., lowering_config and translation_info).

@bangtianliu bangtianliu requested a review from benvanik as a code owner December 4, 2024 22:49
@bangtianliu bangtianliu requested review from kuhar and removed request for benvanik December 4, 2024 22:49
compiler/bindings/c/iree/compiler/dialects/iree_gpu.h Outdated Show resolved Hide resolved
compiler/bindings/python/IREECompilerDialectsModule.cpp Outdated Show resolved Hide resolved
compiler/bindings/python/IREECompilerDialectsModule.cpp Outdated Show resolved Hide resolved
compiler/bindings/python/test/ir/dialects_test.py Outdated Show resolved Hide resolved
@bangtianliu bangtianliu requested a review from kuhar December 5, 2024 20:35
@bangtianliu bangtianliu changed the title [tune: ] add property functions to lowering config python binding [tuner: ] add property functions to lowering config python binding Dec 5, 2024
@bangtianliu bangtianliu changed the title [tuner: ] add property functions to lowering config python binding [tuner]: add property functions to lowering config python binding Dec 5, 2024
@bangtianliu bangtianliu force-pushed the lowering_config_methods branch 2 times, most recently from f96cf54 to 21df5c4 Compare December 5, 2024 23:16
@bangtianliu bangtianliu requested a review from kuhar December 5, 2024 23:17
Copy link
Member

@kuhar kuhar left a comment

Choose a reason for hiding this comment

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

LGTM % one nit

@bangtianliu bangtianliu force-pushed the lowering_config_methods branch from b34e1d1 to a080908 Compare December 7, 2024 03:01
@bangtianliu bangtianliu merged commit 62903cc into iree-org:main Dec 7, 2024
38 checks passed
bangtianliu added a commit to nod-ai/shark-ai that referenced this pull request Dec 9, 2024
…ng (#662)

After landing iree-org/iree#19376, all helper
functions related to lowering configuration can be removed. Instead, we
can directly utilize property functions from the LoweringConfig Python
bindings.

This PR is still relevant to the task in
#453: use IREE bindings for
compilation info (incl., lowering_config and translation_info).

---------

Signed-off-by: Bangtian Liu <[email protected]>
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.

2 participants