llvm
fef8e42f - [libspirv] Use clc functions for __spirv_All/Any (#22105)

Commit
38 days ago
[libspirv] Use clc functions for __spirv_All/Any (#22105) They are now implemented with @llvm.vector.reduce.and/or, which can map to native hardware instruction. Example llvm-diff changes (> is reference): in function _Z11__spirv_AllDv2_c: > %2 = extractelement <2 x i8> %0, i64 0 > %3 = extractelement <2 x i8> %0, i64 1 > %4 = and i8 %2, %3 < %2 = tail call i8 @llvm.vector.reduce.and.v2i8(<2 x i8> %0) in function _Z11__spirv_AnyDv2_c: > %2 = extractelement <2 x i8> %0, i64 0 > %3 = extractelement <2 x i8> %0, i64 1 > %4 = or i8 %2, %3 < %2 = tail call i8 @llvm.vector.reduce.or.v2i8(<2 x i8> %0)
Author
Parents
Loading