[llvm-dev] llvm.memcpy for struct copy

Matthias Braun via llvm-dev llvm-dev at lists.llvm.org
Thu Feb 1 10:09:05 PST 2018


There's no need for anything else, you can bitcast any struct pointer to an i8 pointer (which is free/needs no instructions in all the targets I know of).

- Matthias

> On Jan 29, 2018, at 11:06 PM, ma jun via llvm-dev <llvm-dev at lists.llvm.org> wrote:
> 
> Hi all
>      why does llvm.memcpy intrinsic only support i8*  for first two arguments?  and does clang will also transform struct copy into llvm.memcpy ? what format does IR looks like? 
>      Thanks !
>      
>      Regards
>      Jun
> 
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20180201/6503cb77/attachment.html>


More information about the llvm-dev mailing list