Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Format code for PR #6435 #5

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 4 additions & 9 deletions source/slang/slang-ir-glsl-legalize.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2397,24 +2397,19 @@ static void consolidateParameters(
fieldPtrType = builder->getPtrType(kIROp_InOutType, fieldType);
}

auto fieldAddr = builder->emitFieldAddress(
fieldPtrType,
consolidatedVar,
targetField->getKey());
auto fieldAddr =
builder->emitFieldAddress(fieldPtrType, consolidatedVar, targetField->getKey());

// Replace parameter uses with field address
_param->replaceUsesWith(fieldAddr);
}
}

static void handleMultipleParams(
GLSLLegalizationContext* context,
IRFunc* func,
IRParam* pp)
static void handleMultipleParams(GLSLLegalizationContext* context, IRFunc* func, IRParam* pp)
{
auto firstBlock = func->getFirstBlock();

// Now we run the consolidation step, but if we've already
// Now we run the consolidation step, but if we've already
// processed this parameter, skip it.
List<IRParam*>* processedParams = nullptr;
if (auto foundList = context->rayTracingProcessedParams.tryGetValue(func))
Expand Down
Loading