diff options
| author | andrewboktor <[email protected]> | 2015-03-05 13:18:54 -0800 |
|---|---|---|
| committer | andrewboktor <[email protected]> | 2015-03-05 13:18:54 -0800 |
| commit | 4dc9d53085b568aea0cefe75d599f87bb5e0841f (patch) | |
| tree | b9eb3212e2b7730771103d86336a72b2963a5796 /src/cuda-sim/ptxinfo.y | |
| parent | d46bf67b50b265dd3afae7c9a6a13c4cbdd6176f (diff) | |
| parent | 66d5ba0e9143b1bd6b839643bbffff6fb7db4aa6 (diff) | |
Merge pull request #9 from ElTantawy/master
initial support for CUDA 5.0, 5.5, 6.0 to get template from SDK running
Diffstat (limited to 'src/cuda-sim/ptxinfo.y')
| -rw-r--r-- | src/cuda-sim/ptxinfo.y | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/cuda-sim/ptxinfo.y b/src/cuda-sim/ptxinfo.y index e4ba6b2..294412d 100644 --- a/src/cuda-sim/ptxinfo.y +++ b/src/cuda-sim/ptxinfo.y @@ -42,6 +42,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. %token LMEM %token SMEM %token CMEM +%token GMEM %token <string_value> IDENTIFIER %token PLUS %token COMMA @@ -65,6 +66,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. void ptxinfo_function(const char *fname ); void ptxinfo_regs( unsigned nregs ); void ptxinfo_lmem( unsigned declared, unsigned system ); + void ptxinfo_gmem( unsigned declared, unsigned system ); void ptxinfo_smem( unsigned declared, unsigned system ); void ptxinfo_cmem( unsigned nbytes, unsigned bank ); int ptxinfo_error(const char*); @@ -85,9 +87,10 @@ line_info: function_name | function_info { ptxinfo_addinfo(); } ; -function_name: FUNC QUOTE IDENTIFIER QUOTE { ptxinfo_function($3); } - | FUNC QUOTE IDENTIFIER QUOTE FOR QUOTE IDENTIFIER QUOTE { ptxinfo_function($3); } - +function_name: FUNC QUOTE IDENTIFIER QUOTE { ptxinfo_function($3); } + | FUNC QUOTE IDENTIFIER QUOTE FOR QUOTE IDENTIFIER QUOTE {ptxinfo_function($3); } + ; + function_info: info | function_info COMMA info ; @@ -96,6 +99,7 @@ info: USED INT_OPERAND REGS { ptxinfo_regs($2); } | tuple LMEM { ptxinfo_lmem(g_declared,g_system); } | tuple SMEM { ptxinfo_smem(g_declared,g_system); } | INT_OPERAND BYTES CMEM LEFT_SQUARE_BRACKET INT_OPERAND RIGHT_SQUARE_BRACKET { ptxinfo_cmem($1,$5); } + | INT_OPERAND BYTES GMEM { ptxinfo_gmem($1,0); } | INT_OPERAND BYTES LMEM { ptxinfo_lmem($1,0); } | INT_OPERAND BYTES SMEM { ptxinfo_smem($1,0); } | INT_OPERAND BYTES CMEM { ptxinfo_cmem($1,0); } |
