summaryrefslogtreecommitdiffstats
path: root/llvm/test/Analysis/CFLAliasAnalysis/Steensgaard/const-exprs.ll
Commit message (Collapse)AuthorAgeFilesLines
* Add regression test for r331976George Burgess IV2018-05-101-0/+30
In general, it's difficult to poke the ConstantExpr code in CFLAA, since LLVM is so great at eagerly reducing ConstantExprs. :) Sadly, this only shows a functional difference from before the patch because CFLAA has some special logic around taking loads of non-pointers into account. Namely, with the broken select behavior, CFLAA will completely fail to take note of @g3. Since CFLAA doesn't have any record about @g3 when we do an alias query for @g3 and %a, it conservatively answers MayAlias. When we properly take @g3 into account with the new select logic, we get NoAlias for this query. I suspect that the aforementioned "special logic" isn't completely correct, but this test-case should prevent future wonky aliasing results from appearing for these flavors of ConstantExprs, so I think it's still worth having. llvm-svn: 332017
OpenPOWER on IntegriCloud