================ @@ -5432,6 +5434,57 @@ LValue CodeGenFunction::EmitOpaqueValueLValue(const OpaqueValueExpr *e) { return getOrCreateOpaqueLValueMapping(e); } +LValue CodeGenFunction::BindHLSLOutArgExpr(const HLSLOutArgExpr *E, + Address OutTemp) { + LValue Result = MakeAddrLValue(OutTemp, E->getType()); + OpaqueValueMappingData::bind(*this, E->getCastedTemporary(), Result); + return Result; +} + +void CodeGenFunction::EmitHLSLOutArgExpr(const HLSLOutArgExpr *E, + CallArgList &Args, QualType Ty) { + + // Emitting the casted temporary through an opaque value. + LValue BaseLV = EmitLValue(E->getArgLValue()); + OpaqueValueMappingData::bind(*this, E->getOpaqueArgLValue(), BaseLV); + + LValue TempLV; + + if (E->isInOut()) { ---------------- rjmccall wrote:
I was hoping you'd extract that as a helper function you'd just call rather than duplicating the logic here. 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