diff --git a/src/asahi/compiler/agx_compile.c b/src/asahi/compiler/agx_compile.c index 63740517b39..165ae4fd7c5 100644 --- a/src/asahi/compiler/agx_compile.c +++ b/src/asahi/compiler/agx_compile.c @@ -2560,6 +2560,9 @@ agx_create_block(agx_context *ctx) { agx_block *blk = rzalloc(ctx, agx_block); + /* This is conservative, TODO: divergence analysis */ + blk->divergent = ctx->total_nesting > 0; + util_dynarray_init(&blk->predecessors, blk); return blk; diff --git a/src/asahi/compiler/agx_compiler.h b/src/asahi/compiler/agx_compiler.h index 2bdf1e64ce5..210f6ca7fa8 100644 --- a/src/asahi/compiler/agx_compiler.h +++ b/src/asahi/compiler/agx_compiler.h @@ -452,6 +452,9 @@ typedef struct agx_block { struct util_dynarray predecessors; bool unconditional_jumps; + /* Could there be masked execution? */ + bool divergent; + /* Liveness analysis results */ BITSET_WORD *live_in; BITSET_WORD *live_out;