-
Notifications
You must be signed in to change notification settings - Fork 14.8k
Open
Labels
llvm:instcombineCovers the InstCombine, InstSimplify and AggressiveInstCombine passesCovers the InstCombine, InstSimplify and AggressiveInstCombine passesmissed-optimization
Description
define i1 @src(ptr %arg0) {
%v0 = getelementptr inbounds nuw i8, ptr %arg0, i64 8
%v1 = load i32, ptr %v0, align 8
%v2 = and i32 %v1, 255
%v3 = icmp eq i32 %v2, 17
ret i1 %v3
}
define i1 @tgt(ptr %arg0) {
%v0 = getelementptr inbounds i8, ptr %arg0, i64 8
%v1 = load i8, ptr %v0, align 8
%v2 = icmp eq i8 %v1, 17
ret i1 %v2
}
Alive2: https://alive2.llvm.org/ce/z/tjnF6d
Godbolt: https://godbolt.org/z/9rrPhKE5b
Pattern found in: https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/llvm/optimized/AArch64TargetMachine.ll
Metadata
Metadata
Assignees
Labels
llvm:instcombineCovers the InstCombine, InstSimplify and AggressiveInstCombine passesCovers the InstCombine, InstSimplify and AggressiveInstCombine passesmissed-optimization