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

Add DPEX_OPT, INLINE_THRESHOLD config and do not use numba's OPT #1158

Merged
merged 1 commit into from
Oct 6, 2023

Conversation

ZzEeKkAa
Copy link
Contributor

@ZzEeKkAa ZzEeKkAa commented Oct 4, 2023

It appears that level 3 optimization breaks kernel execution, so we need to set default value to 2 (which seems to work acceptable). This is a quick fix for #1152 and further investigation needed.

  • Have you provided a meaningful PR description?
  • Have you added a test, reproducer or referred to an issue with a reproducer?
  • Have you tested your changes locally for CPU and GPU devices?
  • Have you made sure that new changes do not introduce compiler warnings?
  • If this PR is a work in progress, are you filing the PR as a draft?

@ZzEeKkAa ZzEeKkAa self-assigned this Oct 4, 2023
@ZzEeKkAa ZzEeKkAa requested a review from diptorupd as a code owner October 4, 2023 22:39
@ZzEeKkAa ZzEeKkAa enabled auto-merge October 4, 2023 23:14
# Make optimization level depending on config.OPT variable
pmb.opt_level = config.OPT
# Make optimization level depending on config.DPEX_OPT variable
pmb.opt_level = config.DPEX_OPT

pmb.disable_unit_at_a_time = False
pmb.inlining_threshold = 2
Copy link

Choose a reason for hiding this comment

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

TY for investigating those issues. Also while investigating for #1152 we've also found that pmb.inlining_threshold = 2 causes miscompilations. Could it be disabled by default ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

FYI, opt3 works fine one devcloud with threshold being removed and fails on opt2 with theshold. However I have an environment that fails with opt3 without threshold.

@ZzEeKkAa ZzEeKkAa force-pushed the feature/introduce_dpex_opt_config branch 2 times, most recently from e112e88 to 45aca12 Compare October 5, 2023 17:13
@ZzEeKkAa ZzEeKkAa changed the title Add DPEX_OPT config and do not use numba's OPT Add DPEX_OPT, INLINE_THRESHOLD config and do not use numba's OPT Oct 5, 2023
@ZzEeKkAa ZzEeKkAa requested a review from diptorupd October 5, 2023 17:38
numba_dpex/config.py Outdated Show resolved Hide resolved
@ZzEeKkAa ZzEeKkAa force-pushed the feature/introduce_dpex_opt_config branch from 45aca12 to cbc2911 Compare October 5, 2023 19:13
@ZzEeKkAa ZzEeKkAa force-pushed the feature/introduce_dpex_opt_config branch from cbc2911 to e70a0ff Compare October 5, 2023 20:07
Copy link
Contributor

@diptorupd diptorupd left a comment

Choose a reason for hiding this comment

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

Thanks @ZzEeKkAa

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