OSDN Git Service

[llvm][IRBuilder] Introspection for CreateAlignmentAssumption*() functions
authorRoman Lebedev <lebedev.ri@gmail.com>
Tue, 15 Jan 2019 09:44:13 +0000 (09:44 +0000)
committerRoman Lebedev <lebedev.ri@gmail.com>
Tue, 15 Jan 2019 09:44:13 +0000 (09:44 +0000)
commit809a10dd781f0ae9262ee82890212af426e60f5c
tree61a2c7ed94d27d0358076a1f6cc90af907c80297
parent33c1aca75eb665cb9fac516e5f1903eb9eb59f1a
[llvm][IRBuilder] Introspection for CreateAlignmentAssumption*() functions

Summary:
Clang calls these functions to produce IR for assume-aligned attributes.
I would like to teach UBSAN to verify these assumptions.
For that, i need to access the final pointer on which the check is performed,
and the actual `icmp` that does the check.

The alternative to this would be to fully re-implement this in clang.

This is a second commit, the original one was r351104,
which was mass-reverted in r351159 because 2 compiler-rt tests were failing.

Reviewers: spatel, dneilson, craig.topper, dblaikie, hfinkel

Reviewed By: hfinkel

Subscribers: hfinkel, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@351176 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/IR/IRBuilder.h