[all-commits] [llvm/llvm-project] a0ff26: [GlobalOpt] Fix assertion failure during instructi...
Nikita Popov via All-commits
all-commits at lists.llvm.org
Thu Dec 2 02:58:55 PST 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: a0ff26e08c0cca4917a08c8b8383b8338aa8e73e
https://github.com/llvm/llvm-project/commit/a0ff26e08c0cca4917a08c8b8383b8338aa8e73e
Author: Nikita Popov <nikita.ppv at gmail.com>
Date: 2021-12-02 (Thu, 02 Dec 2021)
Changed paths:
M llvm/lib/Transforms/Utils/Local.cpp
A llvm/test/Transforms/GlobalOpt/recursively-delete-dead-inst-assertion.ll
Log Message:
-----------
[GlobalOpt] Fix assertion failure during instruction deletion
This fixes the assertion failure reported in https://reviews.llvm.org/D114889#3166417,
by making RecursivelyDeleteTriviallyDeadInstructionsPermissive()
more permissive. As the function accepts a WeakTrackingVH, even if
originally only Instructions were inserted, we may end up with
different Value types after a RAUW operation. As such, we should
not assume that the vector only contains instructions.
Notably this matches the behavior of the
RecursivelyDeleteTriviallyDeadInstructions() function variant which
accepts a single value rather than vector.
More information about the All-commits
mailing list