From c3c90c2dd95ba4f714c6d5fdf5793e1db1a191ca Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 31 Jul 2009 10:23:09 -0600 Subject: tgsi: added tgsi_get_opcode_name() --- src/gallium/auxiliary/tgsi/tgsi_info.c | 9 +++++++++ src/gallium/auxiliary/tgsi/tgsi_info.h | 4 ++++ 2 files changed, 13 insertions(+) (limited to 'src/gallium/auxiliary/tgsi') diff --git a/src/gallium/auxiliary/tgsi/tgsi_info.c b/src/gallium/auxiliary/tgsi/tgsi_info.c index cd8871e32dd..ccf4b205ffb 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_info.c +++ b/src/gallium/auxiliary/tgsi/tgsi_info.c @@ -170,3 +170,12 @@ tgsi_get_opcode_info( uint opcode ) assert( 0 ); return NULL; } + + +const char * +tgsi_get_opcode_name( uint opcode ) +{ + const struct tgsi_opcode_info *info = tgsi_get_opcode_info(opcode); + return info->mnemonic; +} + diff --git a/src/gallium/auxiliary/tgsi/tgsi_info.h b/src/gallium/auxiliary/tgsi/tgsi_info.h index 16577598bb0..b2375c69710 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_info.h +++ b/src/gallium/auxiliary/tgsi/tgsi_info.h @@ -47,6 +47,10 @@ struct tgsi_opcode_info const struct tgsi_opcode_info * tgsi_get_opcode_info( uint opcode ); +const char * +tgsi_get_opcode_name( uint opcode ); + + #if defined __cplusplus } #endif -- cgit v1.2.3