diff options
author | Keith Whitwell <keith@tungstengraphics.com> | 2004-12-23 18:26:40 +0000 |
---|---|---|
committer | Keith Whitwell <keith@tungstengraphics.com> | 2004-12-23 18:26:40 +0000 |
commit | 3deaf2174544f25df812af886c424383ba1dafdf (patch) | |
tree | c586a0b616b26523befebdf79f8637d8a705785e /src/mesa/drivers/dri/unichrome/via_context.h | |
parent | 9876730f7ac0497dcb6342997006be752536b0e3 (diff) |
Remove the VIA_PERFORMANCE code. A step towards moving the driver
back to using the shared template files.
Diffstat (limited to 'src/mesa/drivers/dri/unichrome/via_context.h')
-rw-r--r-- | src/mesa/drivers/dri/unichrome/via_context.h | 63 |
1 files changed, 0 insertions, 63 deletions
diff --git a/src/mesa/drivers/dri/unichrome/via_context.h b/src/mesa/drivers/dri/unichrome/via_context.h index 2e815685bc..b31f2683f2 100644 --- a/src/mesa/drivers/dri/unichrome/via_context.h +++ b/src/mesa/drivers/dri/unichrome/via_context.h @@ -291,70 +291,7 @@ struct via_context_t { }; /*#define DMA_OFFSET 16*/ #define DMA_OFFSET 32 -/*#define PERFORMANCE_MEASURE*/ -extern GLuint VIA_PERFORMANCE; - -#ifdef PERFORMANCE_MEASURE -#define HASH_TABLE_SIZE 1000 -#define HASH_TABLE_DEPTH 10 -typedef struct { - char func[50]; - GLuint count; -} hash_element; -extern hash_element hash_table[HASH_TABLE_SIZE][HASH_TABLE_DEPTH]; -#define P_M \ - do { \ - GLuint h_index,h_depth; \ - h_index = (GLuint)(((GLuint) __FUNCTION__)%HASH_TABLE_SIZE); \ - for (h_depth = 0; h_depth < HASH_TABLE_DEPTH; h_depth++) { \ - if (!strcmp(hash_table[h_index][h_depth].func, "NULL")) { \ - sprintf(hash_table[h_index][h_depth].func, "%s", __FUNCTION__); \ - hash_table[h_index][h_depth].count++; \ - break; \ - } \ - else if (!strcmp(hash_table[h_index][h_depth].func, __FUNCTION__)) { \ - hash_table[h_index][h_depth].count++; \ - break; \ - } \ - } \ - } while (0) - -#define P_M_X \ - do { \ - GLuint h_index,h_depth; \ - char str[80]; \ - strcpy(str, __FUNCTION__); \ - h_index = (GLuint)(((GLuint) __FUNCTION__)%HASH_TABLE_SIZE); \ - for (h_depth = 0; h_depth < HASH_TABLE_DEPTH; h_depth++) { \ - if (!strcmp(hash_table[h_index][h_depth].func, "NULL")) { \ - sprintf(hash_table[h_index][h_depth].func, "%s_X", __FUNCTION__); \ - hash_table[h_index][h_depth].count++; \ - break; \ - } \ - else if (!strcmp(hash_table[h_index][h_depth].func, strcat(str, "_X"))) { \ - hash_table[h_index][h_depth].count++; \ - break; \ - } \ - } \ - } while (0) - -#define P_M_R \ - do { \ - GLuint h_size, h_depth; \ - for (h_size = 0; h_size < HASH_TABLE_SIZE; h_size++) { \ - for (h_depth = 0; h_depth < HASH_TABLE_DEPTH; h_depth++) { \ - if (hash_table[h_size][h_depth].count) { \ - fprintf(stderr, "func:%s count:%d\n", hash_table[h_size][h_depth].func, hash_table[h_size][h_depth].count); \ - } \ - } \ - } \ - } while (0) -#else /* PERFORMANCE_MEASURE */ -#define P_M {} -#define P_M_X {} -#define P_M_R {} -#endif #define VIA_CONTEXT(ctx) ((viaContextPtr)(ctx->DriverCtx)) |