[PATCH] D105974: [analyzer] Do not assume that all pointers have the same bitwidth as void*

2021-07-16 Thread Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG918bda124120: [analyzer] Do not assume that all pointers have the same bitwidth as void* (authored by vabridgers, committed by einvbri

[PATCH] D105974: [analyzer] Do not assume that all pointers have the same bitwidth as void*

2021-07-15 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. This revision is now accepted and ready to land. Looks great, thanks! Comment at: clang/lib/StaticAnalyzer/Core/SValBuilder.cpp:718 + QualType Ty = Sym->getType(); + // FIXME: Why did we have references at this point? +

[PATCH] D105974: [analyzer] Do not assume that all pointers have the same bitwidth as void*

2021-07-15 Thread Vince Bridgers via Phabricator via cfe-commits
vabridgers updated this revision to Diff 359163. vabridgers added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D105974/new/ https://reviews.llvm.org/D105974 Files: clang/lib/StaticAnalyzer/Core/SValBuilder.cpp clang/test/Anal

[PATCH] D105974: [analyzer] Do not assume that all pointers have the same bitwidth as void*

2021-07-15 Thread Vince Bridgers via Phabricator via cfe-commits
vabridgers updated this revision to Diff 358869. vabridgers added a comment. update test case Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D105974/new/ https://reviews.llvm.org/D105974 Files: clang/lib/StaticAnalyzer/Core/SValBuilder.cpp clang

[PATCH] D105974: [analyzer] Do not assume that all pointers have the same bitwidth as void*

2021-07-14 Thread Vince Bridgers via Phabricator via cfe-commits
vabridgers added a comment. Thanks for the updates, comments and the reproducer. I've added those in this update. If possible, I'd like to get this change accepted to avoid the crash we currently see, and I'll immediately follow up with the FIXMEs. Otherwise, I'll iterate quickly on the FIXMEs.

[PATCH] D105974: [analyzer] Do not assume that all pointers have the same bitwidth as void*

2021-07-14 Thread Vince Bridgers via Phabricator via cfe-commits
vabridgers updated this revision to Diff 358792. vabridgers added a comment. address comments, add test case suggested by @bjope Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D105974/new/ https://reviews.llvm.org/D105974 Files: clang/lib/StaticAn

[PATCH] D105974: [analyzer] Do not assume that all pointers have the same bitwidth as void*

2021-07-14 Thread Vince Bridgers via Phabricator via cfe-commits
vabridgers added a comment. Thanks all for the updates and comments. I'll address promptly and resubmit. Best! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D105974/new/ https://reviews.llvm.org/D105974

[PATCH] D105974: [analyzer] Do not assume that all pointers have the same bitwidth as void*

2021-07-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. I think this is a plausible use case, previously I thought it's too much work but it seems reasonable last time I looked into it, so I'm glad to see it going on! Can you add a comment explaining that the new code is necessary for architectures with varying pointer bit widt

[PATCH] D105974: [analyzer] Do not assume that all pointers have the same bitwidth as void*

2021-07-14 Thread Bjorn Pettersson via Phabricator via cfe-commits
bjope added a comment. I think you can create an upstream test case by looking at `clang/test/Analysis/ptr.cl`. It uses amdgcn and address space 256, which seems to have a different pointer size compared to address space zero for that specific target. So the test case (named with a .cl extensio