-
Notifications
You must be signed in to change notification settings - Fork 12k
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
[FunctionAttrs] Incorrect nonnull inference for non-inbounds GEP #91177
Comments
nikic
added a commit
to nikic/llvm-project
that referenced
this issue
May 6, 2024
nikic
added a commit
to nikic/llvm-project
that referenced
this issue
May 6, 2024
For inbounds GEPs, if the source pointer is non-null, the result must also be non-null. However, this does not hold for non-inbounds GEPs. Fixes llvm#91177.
github-project-automation
bot
moved this from Needs Triage
to Done
in LLVM Release Status
May 7, 2024
/cherry-pick f34d30c |
llvmbot
pushed a commit
to llvmbot/llvm-project
that referenced
this issue
May 7, 2024
…lvm#91180) For inbounds GEPs, if the source pointer is non-null, the result must also be non-null. However, this does not hold for non-inbounds GEPs. Fixes llvm#91177. (cherry picked from commit f34d30c)
/pull-request #91286 |
EugeneZelenko
added
ipo
Interprocedural optimizations
and removed
llvm:optimizations
labels
May 7, 2024
tstellar
pushed a commit
to llvmbot/llvm-project
that referenced
this issue
May 9, 2024
…lvm#91180) For inbounds GEPs, if the source pointer is non-null, the result must also be non-null. However, this does not hold for non-inbounds GEPs. Fixes llvm#91177. (cherry picked from commit f34d30c)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
FunctionAttrs incorrectly infers that the following function returns nonnull (https://llvm.godbolt.org/z/49Kbq15xn):
This is because the code assumes that the result of a GEP is non-null if the source is non-null here:
llvm-project/llvm/lib/Transforms/IPO/FunctionAttrs.cpp
Line 1189 in d98a785
The text was updated successfully, but these errors were encountered: