pan/mdg: Add MIDGARD_MESA_DEBUG=inorder option
Helpful to disable the scheduler when debugging, so the assembly can be compared against the NIR directly when lost in a big dEQP test. Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8973>
This commit is contained in:
parent
c7bcc40ec1
commit
73bbf08897
3 changed files with 8 additions and 0 deletions
|
|
@ -34,6 +34,7 @@
|
|||
#define MIDGARD_DBG_MSGS 0x0001
|
||||
#define MIDGARD_DBG_SHADERS 0x0002
|
||||
#define MIDGARD_DBG_SHADERDB 0x0004
|
||||
#define MIDGARD_DBG_INORDER 0x0008
|
||||
|
||||
extern int midgard_debug;
|
||||
|
||||
|
|
|
|||
|
|
@ -58,6 +58,7 @@ static const struct debug_named_value midgard_debug_options[] = {
|
|||
{"msgs", MIDGARD_DBG_MSGS, "Print debug messages"},
|
||||
{"shaders", MIDGARD_DBG_SHADERS, "Dump shaders in NIR and MIR"},
|
||||
{"shaderdb", MIDGARD_DBG_SHADERDB, "Prints shader-db statistics"},
|
||||
{"inorder", MIDGARD_DBG_INORDER, "Disables out-of-order scheduling"},
|
||||
DEBUG_NAMED_VALUE_END
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -674,6 +674,12 @@ mir_choose_instruction(
|
|||
unsigned max_active = 0;
|
||||
unsigned max_distance = 36;
|
||||
|
||||
#ifndef NDEBUG
|
||||
/* Force in-order scheduling */
|
||||
if (midgard_debug & MIDGARD_DBG_INORDER)
|
||||
max_distance = 1;
|
||||
#endif
|
||||
|
||||
BITSET_FOREACH_SET(i, worklist, count) {
|
||||
max_active = MAX2(max_active, i);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue