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

Remove dead code only if function name is replaced #303

Merged
merged 13 commits into from
May 18, 2021

Conversation

reazulhoque
Copy link
Contributor

This PR makes sure we try to remove dead code only when we replace the Numpy function names with our own. Removing dead code regardless was failing in cases where we have multiple prange as mentioned in this issue. This PR should close #302.

Copy link
Contributor

@PokhodenkoSA PokhodenkoSA left a comment

Choose a reason for hiding this comment

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

Please, provide test case.

@reazulhoque
Copy link
Contributor Author

@PokhodenkoSA this bug was noticed originally because this test was falling back. This PR fixes this test from falling back and offloads it through our pipeline. Should we ask the original author of that test to make sure it fails if it is falling back instead of going through our pipeline?

I can always write tests and that would require setting up a partial compiler pipeline to test it, which is tedious. Please share your thoughts.

@PokhodenkoSA
Copy link
Contributor

this test was falling back.

Does it mean that test did not check that code falling back? So test was blind?
No when you fix the code did you fix the test to check that fallback is not happening now?
I think test should be fixed first to catch bad situation and show that the test fails. Then your fix for the feature should show that it makes test passing.

@reazulhoque
Copy link
Contributor Author

reazulhoque commented Apr 27, 2021

Does it mean that test did not check that code falling back? So test was blind?

Yes.

I have updated the tests to check for falling back.

numba_dppy/testing.py Outdated Show resolved Hide resolved
@reazulhoque
Copy link
Contributor Author

@PokhodenkoSA @diptorupd Can you please review it?

@PokhodenkoSA PokhodenkoSA merged commit 4ec1456 into IntelPython:main May 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Lowering multiple pranges are failing for GPU
2 participants