OSDN Git Service

[CodeExtractor] Erase use-without-def debug intrinsics in parent func
authorVedant Kumar <vsk@apple.com>
Tue, 6 Nov 2018 19:05:53 +0000 (19:05 +0000)
committerVedant Kumar <vsk@apple.com>
Tue, 6 Nov 2018 19:05:53 +0000 (19:05 +0000)
commitb109c4206afa553e8d25a56d6d851f612e57e3e7
treef70754c3093bcfb3971a8adaf3fb110ae3db23e2
parent27ad7c20cc1fc02faa4cea18fef8361c0eb3b417
[CodeExtractor] Erase use-without-def debug intrinsics in parent func

When CodeExtractor moves instructions to a new function, debug
intrinsics referring to those instructions within the parent function
become invalid.

This results in the same verifier failure which motivated r344545, about
function-local metadata being used in the wrong function.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@346255 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Utils/CodeExtractor.cpp
test/Transforms/HotColdSplit/delete-use-without-def-dbg-val.ll [new file with mode: 0644]