aaron.ballman added subscribers: efriedma, rjmccall.
aaron.ballman added a comment.

In D129008#3640194 <https://reviews.llvm.org/D129008#3640194>, @tianshilei1992 
wrote:

> `callCStructCopyConstructor` is actually for Objective-C…Cannot use it here.

Is it for ObjC? Looking at the comments, it looks like it's for C:

  // These functions emit calls to the special functions of non-trivial C
  // structs.



================
Comment at: clang/lib/CodeGen/CGDecl.cpp:2501
+      LValue Src = MakeAddrLValue(Arg.getIndirectAddress(), Ty);
+      callCStructCopyConstructor(Dst, Src);
+      PushCleanupIfNeeded(Arg.getIndirectAddress());
----------------
tianshilei1992 wrote:
> Hi @aaron.ballman, is it possible to invoke the copy constructor of a 
> struct/class here, either it is user defined or default one?
CC @rjmccall and @efriedma for codegen owner opinions.

I'm honestly not certain; I would imagine that OpenMP defines what should 
happen, but this is outside of my area of expertise.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D129008/new/

https://reviews.llvm.org/D129008

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to