summaryrefslogtreecommitdiff
path: root/src/cuda-sim/ptx_parser.cc
diff options
context:
space:
mode:
authorAhmed El-Shafiey <[email protected]>2012-08-14 13:53:25 -0800
committerAndrew Boktor <[email protected]>2014-08-14 13:48:54 -0700
commit0ce06988a6a13f9a8f48f2230b1b9727ee86081e (patch)
tree08a4f172a71b3a9b0de5bea1b1c74f38d97036cb /src/cuda-sim/ptx_parser.cc
parent8f2b4a6f61ef30d86b9bae7c92ed62f223550a76 (diff)
Fixing bugs 169, 170, 171
[git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 13761]
Diffstat (limited to 'src/cuda-sim/ptx_parser.cc')
-rw-r--r--src/cuda-sim/ptx_parser.cc17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/cuda-sim/ptx_parser.cc b/src/cuda-sim/ptx_parser.cc
index cc97b72..76d9a9c 100644
--- a/src/cuda-sim/ptx_parser.cc
+++ b/src/cuda-sim/ptx_parser.cc
@@ -689,8 +689,8 @@ void change_memory_addr_space(const char *identifier)
if(!strcmp(l, "l"))
{
g_operands.back().set_addr_space(local_space);
- parse_assert(g_current_symbol_table->lookup(identifier) != NULL, "Local memory segment was not defined.");
- g_operands.back().set_const_mem_offset(g_current_symbol_table->lookup(identifier)->get_address());
+ //parse_assert(g_current_symbol_table->lookup(identifier) != NULL, "Local memory segment was not defined.");
+ //g_operands.back().set_const_mem_offset(g_current_symbol_table->lookup(identifier)->get_address());
recognizedType = true;
}
@@ -711,6 +711,13 @@ void change_operand_lohi( int lohi )
}
+void set_immediate_operand_type ()
+{
+ DPRINTF("set_immediate_operand_type");
+ assert( !g_operands.empty() );
+ g_operands.back().set_immediate_addr();
+}
+
void change_double_operand_type( int operand_type )
{
/*
@@ -809,6 +816,12 @@ void add_address_operand( const char *identifier, int offset )
g_operands.push_back( operand_info(s,offset) );
}
+void add_address_operand2( int offset )
+{
+ DPRINTF("add_address_operand");
+ g_operands.push_back( operand_info((unsigned)offset) );
+}
+
void add_array_initializer()
{
g_last_symbol->add_initializer(g_operands);