llvm-project/llvm/test/Analysis/BasicAA
Sanjoy Das 3336f681e3 [Verifier] Add verification for TBAA metadata
Summary:
This change adds some verification in the IR verifier around struct path
TBAA metadata.

Other than some basic sanity checks (e.g. we get constant integers where
we expect constant integers), this checks:

 - That by the time an struct access tuple `(base-type, offset)` is
   "reduced" to a scalar base type, the offset is `0`.  For instance, in
   C++ you can't start from, say `("struct-a", 16)`, and end up with
   `("int", 4)` -- by the time the base type is `"int"`, the offset
   better be zero.  In particular, a variant of this invariant is needed
   for `llvm::getMostGenericTBAA` to be correct.

 - That there are no cycles in a struct path.

 - That struct type nodes have their offsets listed in an ascending
   order.

 - That when generating the struct access path, you eventually reach the
   access type listed in the tbaa tag node.

Reviewers: dexonsmith, chandlerc, reames, mehdi_amini, manmanren

Subscribers: mcrosier, llvm-commits

Differential Revision: https://reviews.llvm.org/D26438

llvm-svn: 289402
2016-12-11 20:07:15 +00:00
..
2003-02-26-AccessSizeTest.ll
2003-03-04-GEPCrash.ll
2003-04-22-GEPProblem.ll
2003-04-25-GEPCrash.ll
2003-05-21-GEP-Problem.ll
2003-06-01-AliasCrash.ll
2003-07-03-BasicAACrash.ll
2003-09-19-LocalArgument.ll
2003-11-04-SimpleCases.ll
2003-12-11-ConstExprGEP.ll [opaque pointer type] Add textual IR support for explicit type parameter to gep operator 2015-03-13 18:20:45 +00:00
2004-07-28-MustAliasbug.ll
2006-03-03-BadArraySubscript.ll [opaque pointer type] Add textual IR support for explicit type parameter to the call instruction 2015-04-16 23:24:18 +00:00
2006-11-03-BasicAAVectorCrash.ll
2007-01-13-BasePointerBadNoAlias.ll
2007-08-01-NoAliasAndCalls.ll
2007-08-01-NoAliasAndGEP.ll
2007-08-05-GetOverloadedModRef.ll
2007-10-24-ArgumentsGlobals.ll [opaque pointer type] Add textual IR support for explicit type parameter to gep operator 2015-03-13 18:20:45 +00:00
2007-11-05-SizeCrash.ll [opaque pointer type] Add textual IR support for explicit type parameter for global aliases 2015-09-11 03:22:04 +00:00
2007-12-08-OutOfBoundsCrash.ll [opaque pointer type] Add textual IR support for explicit type parameter for global aliases 2015-09-11 03:22:04 +00:00
2008-04-15-Byval.ll [opaque pointer type] Add textual IR support for explicit type parameter to the call instruction 2015-04-16 23:24:18 +00:00
2008-06-02-GEPTailCrash.ll [opaque pointer type] Add textual IR support for explicit type parameter to gep operator 2015-03-13 18:20:45 +00:00
2008-11-23-NoaliasRet.ll
2009-03-04-GEPNoalias.ll
2009-10-13-AtomicModRef.ll
2009-10-13-GEP-BaseNoAlias.ll
2010-09-15-GEP-SignedArithmetic.ll
2014-03-18-Maxlookup-reached.ll
aligned-overread.ll [opaque pointer type] Add textual IR support for explicit type parameter to gep operator 2015-03-13 18:20:45 +00:00
args-rets-allocas-loads.ll
assume.ll Revert "Change memcpy/memset/memmove to have dest and source alignments." 2015-11-19 05:56:52 +00:00
bug.23540.ll [BasicAA] Fix the handling of sext and zext in the analysis of GEPs. 2015-08-31 22:32:47 +00:00
bug.23626.ll [BasicAA] Fix the handling of sext and zext in the analysis of GEPs. 2015-08-31 22:32:47 +00:00
byval.ll [opaque pointer type] Add textual IR support for explicit type parameter to the call instruction 2015-04-16 23:24:18 +00:00
cas.ll
constant-over-index.ll
cs-cs.ll [BasicAA] Teach BasicAA to handle the inaccessiblememonly and inaccessiblemem_or_argmemonly attributes 2016-11-08 21:07:42 +00:00
dag.ll
empty.ll
featuretest.ll [opaque pointer type] Add textual IR support for explicit type parameter to gep operator 2015-03-13 18:20:45 +00:00
full-store-partial-alias.ll [Verifier] Add verification for TBAA metadata 2016-12-11 20:07:15 +00:00
gcsetest.ll
gep-alias.ll [BasicAA] Add a test for PR24468 to be sure we won't regress 2015-08-19 00:08:26 +00:00
gep-and-alias.ll [BasicAA] Fix - missed alias in GEP expressions 2016-10-22 02:41:39 +00:00
getmodrefinfo-cs-cs.ll Revert "Change memcpy/memset/memmove to have dest and source alignments." 2015-11-19 05:56:52 +00:00
global-size.ll
guards.ll [BasicAA] Guard intrinsics don't write to memory 2016-05-10 02:35:41 +00:00
intrinsics.ll Sort the enums in Attributes.h in case insensitive alphabetical order. 2015-11-11 02:11:46 +00:00
invariant_load.ll
memset_pattern.ll [BasicAA] Remove special casing of memset_pattern16 in favor of generic attribute inference 2016-01-06 04:53:16 +00:00
modref.ll Revert "Change memcpy/memset/memmove to have dest and source alignments." 2015-11-19 05:56:52 +00:00
must-and-partial.ll
negoffset.ll [BasicAA] Extend inbound GEP negative offset logic to GlobalVariables 2016-05-26 19:30:49 +00:00
no-escape-call.ll
noalias-bugs.ll Fix a bunch of trivial cases of 'CHECK[^:]*$' in the tests. NFCI 2015-08-10 19:01:27 +00:00
noalias-geps.ll
noalias-param.ll
noalias-wraparound-bug.ll [BasicAA] Fix for missing must alias (D16343) 2016-01-30 05:52:53 +00:00
nocapture.ll
phi-aa.ll [PM/AA] Port alias analysis evaluator to the new pass manager, and use 2016-02-20 03:46:03 +00:00
phi-and-select.ll
phi-loop.ll Analyze recursive PHI nodes in BasicAA 2015-07-15 19:32:22 +00:00
phi-spec-order.ll [opaque pointer type] Add textual IR support for explicit type parameter to gep operator 2015-03-13 18:20:45 +00:00
phi-speculation.ll
pr18573.ll
pure-const-dce.ll
q.bad.ll [BasicAA] Fix the handling of sext and zext in the analysis of GEPs. 2015-08-31 22:32:47 +00:00
returned.ll BasicAA should look through functions with returned arguments 2016-07-11 01:32:20 +00:00
sequential-gep.ll [BasicAA] Bugfix for r251016 2015-10-23 14:17:03 +00:00
store-promote.ll
struct-geps.ll [BasicAA] Compare GEP indices based on value (Fix PR27418) 2016-05-11 15:45:43 +00:00
tailcall-modref.ll
underlying-value.ll
unreachable-block.ll
zext.ll [BasicAA] Fix the handling of sext and zext in the analysis of GEPs. 2015-08-31 22:32:47 +00:00