Gopalasubramanian, Ganesh via llvm-dev
2017-Dec-21 05:51 UTC
[llvm-dev] Query on i128 type tests written for memset
Hi, I was going through tests written for memset. I need help in figuring out the types in the tests. Found test "test/Transforms/MemCpyOpt/memset-memcpy-redundant-memset.ll>" which uses i128 type for destination size. I am curious when we can get i128 type dest_size calls for memset? <snip> define void @test_different_types_i128_i32(i8* %dst, i8* %src, i128 %dst_size, i32 %src_size, i8 %c) { call void @llvm.memset.p0i8.i128(i8* %dst, i8 %c, i128 %dst_size, i32 1, i1 false) call void @llvm.memcpy.p0i8.p0i8.i32(i8* %dst, i8* %src, i32 %src_size, i32 1, i1 false) ret void } </snip> Regards -Ganesh -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20171221/20365a80/attachment.html>
Friedman, Eli via llvm-dev
2017-Dec-21 20:48 UTC
[llvm-dev] Query on i128 type tests written for memset
On 12/20/2017 9:51 PM, Gopalasubramanian, Ganesh via llvm-dev wrote:> > Hi, > > I was going through tests written for memset. I need help in figuring > out the types in the tests. > Found test > “test/Transforms/MemCpyOpt/memset-memcpy-redundant-memset.ll>” which > uses i128 type for destination size. > > I am curious when we can get i128 type dest_size calls for memset? >As far as I know, clang will never generate a memset like that, and LLVM optimizations won't either. But there isn't any rule against it, so other frontends could generate one, at least in theory. -Eli -- Employee of Qualcomm Innovation Center, Inc. Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20171221/15d1881f/attachment.html>