diff options
author | Brian Paul <[email protected]> | 2009-03-13 09:17:30 -0600 |
---|---|---|
committer | Brian Paul <[email protected]> | 2009-03-13 09:23:44 -0600 |
commit | 7d6478cfccf03c87f2b9daa541ae486dc24bb388 (patch) | |
tree | 71da440faa23d84f468cf8b9977564e828b00183 | |
parent | a10ec13143599344ecb4a486db1454b488cd9645 (diff) |
i965: more register number assertionsmesa_20090313
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_eu.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_eu.h b/src/mesa/drivers/dri/i965/brw_eu.h index b15e8403ccb..eb99c21711e 100644 --- a/src/mesa/drivers/dri/i965/brw_eu.h +++ b/src/mesa/drivers/dri/i965/brw_eu.h @@ -170,6 +170,13 @@ static INLINE struct brw_reg brw_reg( GLuint file, GLuint writemask ) { struct brw_reg reg; + if (type == BRW_GENERAL_REGISTER_FILE) + assert(nr < 128); + else if (type == BRW_MESSAGE_REGISTER_FILE) + assert(nr < 9); + else if (type == BRW_ARCHITECTURE_REGISTER_FILE) + assert(nr <= BRW_ARF_IP); + reg.type = type; reg.file = file; reg.nr = nr; |