================
@@ -4498,6 +4498,9 @@ Address CodeGenFunction::EmitArrayToPointerDecay(const
Expr *E,
if (!E->getType()->isVariableArrayType()) {
assert(isa<llvm::ArrayType>(Addr.getElementType()) &&
"Expected pointer to array");
+
+ if (getLangOpts().HLSL && getLangOpts().EmitStructuredGEP)
+ return Addr;
----------------
Keenuts wrote:
So looks like for now we'll handle this by emitting an SGEP with no indices and
removing this early return.
The special handling is done in CGHLSLRuntime when handling array access.
https://github.com/llvm/llvm-project/pull/177332
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits