8 Commits

Author SHA1 Message Date
George Burgess IV
3772549656 Make some LLVM_CONSTEXPR variables const. NFC.
This patch changes LLVM_CONSTEXPR variable declarations to const
variable declarations, since LLVM_CONSTEXPR expands to nothing if the
current compiler doesn't support constexpr. In all of the changed
cases, it looks like the code intended the variable to be const instead
of sometimes-constexpr sometimes-not.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@279696 91177308-0d34-0410-b5e6-96231b3b80d8
2016-08-25 01:05:08 +00:00
George Burgess IV
3dba903392 [CFLAA] Add more offset-sensitivity tracking.
This patch teaches FunctionInfo about offsets.

Like the last patch, this one doesn't introduce any visible
functionality change (the core algorithm knows nothing about offsets;
they're just plumbed through). Tests will come when we start acting
differently because of the offsets.

Patch by Jia Chen.

(N.B. I made a tiny change to Jia's patch to avoid warnings by GCC: I
put DenseMapInfo specializations in the `llvm` namespace. Only realized
that those appeared when compiling locally. :) )

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


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@276486 91177308-0d34-0410-b5e6-96231b3b80d8
2016-07-22 22:30:48 +00:00
George Burgess IV
1caa063db8 [CFLAA] Add some interproc. analysis to CFLAnders.
This patch adds function summary support to CFLAnders. It also comes
with a lot of tests! Woohoo!

Patch by Jia Chen.

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


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@276026 91177308-0d34-0410-b5e6-96231b3b80d8
2016-07-19 20:47:15 +00:00
George Burgess IV
723a3ff949 [CFLAA] Add an initial CFLAnders implementation.
This adds an incomplete anders-style implementation for CFLAA. It's
incomplete in that it's missing interprocedural analysis, attrs
handling, etc. and that it needs more tests. More tests and features
will be added in future commits.

Patch by Jia Chen.

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


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@275602 91177308-0d34-0410-b5e6-96231b3b80d8
2016-07-15 19:53:25 +00:00
George Burgess IV
9e937064ea [CFLAA] Simplify CFLGraphBuilder. NFC.
This patch simplifies the graph builder by encoding nodes as {Value,
Dereference Level} pairs. This lets us kill edge types, and allows us to
get rid of hacks in StratifiedSets (like addAttrsBelow/...). This
simplification also allows us to remove InstantiatedRelations and
InstantiatedAttrs.

Patch by Jia Chen.

Differential Revision: http://reviews.llvm.org/D22080


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@275122 91177308-0d34-0410-b5e6-96231b3b80d8
2016-07-11 22:59:09 +00:00
George Burgess IV
d0506b50b4 [CFLAA] Make a constant variable const. NFC.
`const` was dropped by r274958, and the lack of `const` makes GCC6
(correctly) complain.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@274961 91177308-0d34-0410-b5e6-96231b3b80d8
2016-07-09 03:21:25 +00:00
George Burgess IV
654ec29586 [CFLAA] Move the graph builder out from CFLSteens. NFC.
Patch by Jia Chen.

Differential Revision: http://reviews.llvm.org/D22022


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@274958 91177308-0d34-0410-b5e6-96231b3b80d8
2016-07-09 02:54:42 +00:00
George Burgess IV
cc48e0f82a [CFLAA] Split out more things from CFLSteens. NFC.
"More things" = StratifiedAttrs and various bits like interprocedural
summaries.

Patch by Jia Chen.

Differential Revision: http://reviews.llvm.org/D21964


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@274592 91177308-0d34-0410-b5e6-96231b3b80d8
2016-07-06 00:47:21 +00:00