OSDN Git Service

[BasicAA] Stop crashing when dealing with pointers > 64 bits.
authorDavide Italiano <davide@freebsd.org>
Mon, 15 Jan 2018 01:40:18 +0000 (01:40 +0000)
committerDavide Italiano <davide@freebsd.org>
Mon, 15 Jan 2018 01:40:18 +0000 (01:40 +0000)
commit4b3289612268b4fbbf578256a15d31e3f5033003
tree2b61b318e1e29a694c23ce29537749c608f47453
parentbc98528887c529c75a406e9307b86088fade8798
[BasicAA] Stop crashing when dealing with pointers > 64 bits.

An alternative (and probably better) fix would be that of
making `Scale` an APInt, and there's a patch floating around
to do this. As we're still discussing it, at least stop crashing
in the meanwhile (added bonus, we now have a regression test for
this situation).

Fixes PR35843.

Thanks to Eli for suggesting the fix and Simon for reporting and
reducing the bug.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@322467 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Analysis/BasicAliasAnalysis.cpp
test/Analysis/BasicAA/pr35843.ll [new file with mode: 0644]