[all-commits] [llvm/llvm-project] 19c6b6: [InstCombine] Fix a crash in `PointerReplacer`
Shilei Tian via All-commits
all-commits at lists.llvm.org
Tue Jul 16 06:06:01 PDT 2024
Branch: refs/heads/users/shiltian/07-15-_instcombine_remove_early_replacement_of_uses_in_pointerreplacer
Home: https://github.com/llvm/llvm-project
Commit: 19c6b683096201c968ea5f254d734aca388d1e39
https://github.com/llvm/llvm-project/commit/19c6b683096201c968ea5f254d734aca388d1e39
Author: Shilei Tian <i at tianshilei.me>
Date: 2024-07-16 (Tue, 16 Jul 2024)
Changed paths:
M llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp
A llvm/test/Transforms/InstCombine/AMDGPU/select-from-load.ll
Log Message:
-----------
[InstCombine] Fix a crash in `PointerReplacer`
A crash could happen in `PointerReplacer::replace` when constructing a new
select instruction and there is no replacement for one of its operand. This can
happen when the operand is a load instruction that has been replaced earlier
such that the operand itself is already the new value. In this case, it is not
in the replacement map and `getReplacement` simply returns nullptr.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list