Hi All,
This patch implements transform for the pattern " ((B | C) & A) | B -> B | (A & C) "
Please help in reviewing the same.
Z3 Link : http://rise4fun.com/Z3/hP6p
Thanks,
Sonam.
Differential D4865
Added InstCombine Transform for ((B | C) & A) | B -> B | (A & C) sonamkumari on Aug 12 2014, 4:13 AM. Authored by
Details Hi All, This patch implements transform for the pattern " ((B | C) & A) | B -> B | (A & C) " Please help in reviewing the same. Z3 Link : http://rise4fun.com/Z3/hP6p Thanks,
Diff Detail Event TimelineComment Actions While this seems to handle ((B | C) & A) | B, it would be nice if you also handled ((B | C) & A) | C
Comment Actions Hi David, Thanks for your valuable comments. define i32 @test19(i32 %x, i32 %y, i32 %z) { %or = or i32 %y, %z %and = and i32 %x, %or %or1 = or i32 %and, %z ret i32 %or1 } The output I got was : define i32 @test19(i32 %x, i32 %y, i32 %z) { %1 = and i32 %x, %y %or1 = or i32 %1, %z ret i32 %or1 } So, I guess we need not handle this case. Thanks,
Comment Actions Hi David, Thanks for further simplifying it. Thanks, Comment Actions Hi David, Can you please commit this on my behalf as i don't have commit access. Thanks, |
This is a longwinded way of saying Op1 == B.