HomePhabricator

[InstCombine] Don't transform code if DoTransform is false

Authored by Carrot on Jun 18 2021, 6:01 PM.

Description

[InstCombine] Don't transform code if DoTransform is false

In patch https://reviews.llvm.org/D72396, it doesn't check DoTransform before transforming the code, and generates wrong result for the attached test case.

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