diff options
author | Brian <brian.paul@tungstengraphics.com> | 2007-09-29 10:43:29 -0600 |
---|---|---|
committer | Brian <brian.paul@tungstengraphics.com> | 2007-09-29 10:43:29 -0600 |
commit | 78f3cd1e08d68111a2db308c000b94cc580b3cad (patch) | |
tree | de8fd7a55ec37e47512fb554988af87f7054aa7a /src/mesa/pipe/tgsi/exec/tgsi_exec.h | |
parent | 91550f0a17488f41da4829a627db90f0081250dc (diff) |
Initial conditional execution support for loops and BRK instruction.
Also, instead of passing cond mask to each micro op, just apply it in the
store_dest() function.
Diffstat (limited to 'src/mesa/pipe/tgsi/exec/tgsi_exec.h')
-rw-r--r-- | src/mesa/pipe/tgsi/exec/tgsi_exec.h | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/src/mesa/pipe/tgsi/exec/tgsi_exec.h b/src/mesa/pipe/tgsi/exec/tgsi_exec.h index 54b38cb4b2..e67a8138e8 100644 --- a/src/mesa/pipe/tgsi/exec/tgsi_exec.h +++ b/src/mesa/pipe/tgsi/exec/tgsi_exec.h @@ -98,8 +98,12 @@ struct tgsi_exec_labels #define TGSI_EXEC_NUM_ADDRS 1 #define TGSI_EXEC_MAX_COND_NESTING 10 +#define TGSI_EXEC_MAX_LOOP_NESTING 10 +/** + * Run-time virtual machine state for executing TGSI shader. + */ struct tgsi_exec_machine { /* @@ -132,12 +136,18 @@ struct tgsi_exec_machine /* FRAGMENT processor only. */ const struct tgsi_interp_coef *InterpCoefs; - /* Conditional execution mask */ + /* Conditional execution masks */ uint CondMask; + uint LoopMask; + uint ExecMask; /**< = CondMask & LoopMask */ - /* Condition mask stack (for nested conditionals) */ - uint condStack[TGSI_EXEC_MAX_COND_NESTING]; + /** Condition mask stack (for nested conditionals) */ + uint CondStack[TGSI_EXEC_MAX_COND_NESTING]; int CondStackTop; + + /** Loop mask stack (for nested loops) */ + uint LoopStack[TGSI_EXEC_MAX_LOOP_NESTING]; + int LoopStackTop; }; |