================
@@ -4148,6 +4152,30 @@ static void emitWriteback(CodeGenFunction &CGF,
   assert(!isProvablyNull(srcAddr.getBasePointer()) &&
          "shouldn't have writeback for provably null argument");
 
+  if (CGF.getLangOpts().HLSL) {
+    if (!isa<OpaqueValueExpr>(writeback.CastExpr)) {
----------------
rjmccall wrote:

You at least need a comment explaining what you're trying to do here.  It looks 
like you're trying to avoid potentially creating a temporary if there's no 
conversion required as part of the writeback?

https://github.com/llvm/llvm-project/pull/101083
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to