OSDN Git Service

[GVNHoist] computeInsertionPoints() miscalculates IDF
authorAlexandros Lamprineas <alexandros.lamprineas@arm.com>
Wed, 12 Sep 2018 14:28:23 +0000 (14:28 +0000)
committerAlexandros Lamprineas <alexandros.lamprineas@arm.com>
Wed, 12 Sep 2018 14:28:23 +0000 (14:28 +0000)
commit6a54cd5c4b78df511d19730aa5e27e0c04b96239
tree7d84964dd61249dacc7f2f63ac2297fda60ee3d6
parent748e6b87e216b1a219d0a0e931bef1ab0d5ffae3
[GVNHoist] computeInsertionPoints() miscalculates IDF

Fix for https://bugs.llvm.org/show_bug.cgi?id=38912.

In GVNHoist::computeInsertionPoints() we iterate over the Value
Numbers and calculate the Iterated Dominance Frontiers without
clearing the IDFBlocks vector first. IDFBlocks ends up accumulating
an insane number of basic blocks, which bloats the compilation time
of SemaChecking.cpp with ubsan enabled.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@342055 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/GVNHoist.cpp