Commit 7bfaa132 authored by Jesse Natalie's avatar Jesse Natalie Committed by Erik Faye-Lund
Browse files

microsoft/clc: Move function list pruning earlier

There's no reason to defer it after inlining, it just bloats the
output of NIR_PRINT.
parent af482435
......@@ -1378,6 +1378,13 @@ clc_to_dxil(struct clc_context *ctx,
NIR_PASS_V(nir, nir_lower_libclc, ctx->libclc_nir);
NIR_PASS_V(nir, nir_inline_functions);
// Pick off the single entrypoint that we want.
foreach_list_typed_safe(nir_function, func, node, &nir->functions) {
if (!func->is_entrypoint)
exec_node_remove(&func->node);
}
assert(exec_list_length(&nir->functions) == 1);
{
bool progress;
do
......@@ -1424,13 +1431,6 @@ clc_to_dxil(struct clc_context *ctx,
}
}
// Pick off the single entrypoint that we want.
foreach_list_typed_safe(nir_function, func, node, &nir->functions) {
if (!func->is_entrypoint)
exec_node_remove(&func->node);
}
assert(exec_list_length(&nir->functions) == 1);
NIR_PASS_V(nir, nir_lower_variable_initializers, ~(nir_var_function_temp | nir_var_shader_temp));
// Lower memcpy
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment