diff options
author | Reid Kleckner <rnk@google.com> | 2017-09-21 19:52:03 +0000 |
---|---|---|
committer | Reid Kleckner <rnk@google.com> | 2017-09-21 19:52:03 +0000 |
commit | 0fe506bc5eff0b3b77632ff8db00165ae07830ee (patch) | |
tree | 540b10e2fd6b6ca76708216c9cdf21255da665db /lldb/packages/Python/lldbsuite/test/example/TestSequenceFunctions.py | |
parent | 977996d25b1f7ca0d4f4d2c863537a95287f096e (diff) | |
download | bcm5719-llvm-0fe506bc5eff0b3b77632ff8db00165ae07830ee.tar.gz bcm5719-llvm-0fe506bc5eff0b3b77632ff8db00165ae07830ee.zip |
Re-land r313825: "[IR] Add llvm.dbg.addr, a control-dependent version of llvm.dbg.declare"
The fix is to avoid invalidating our insertion point in
replaceDbgDeclare:
Builder.insertDeclare(NewAddress, DIVar, DIExpr, Loc, InsertBefore);
+ if (DII == InsertBefore)
+ InsertBefore = &*std::next(InsertBefore->getIterator());
DII->eraseFromParent();
I had to write a unit tests for this instead of a lit test because the
use list order matters in order to trigger the bug.
The reduced C test case for this was:
void useit(int*);
static inline void inlineme() {
int x[2];
useit(x);
}
void f() {
inlineme();
inlineme();
}
llvm-svn: 313905
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/example/TestSequenceFunctions.py')
0 files changed, 0 insertions, 0 deletions