Commit d7ab3529 authored by Tiago Jorge's avatar Tiago Jorge
Browse files

Update dispatcher with autogen call to HW (RMAP exchanges under 'Execute' to be implemented)

parent e8956223
...@@ -525,6 +525,7 @@ static void ErrorHandler( ...@@ -525,6 +525,7 @@ static void ErrorHandler(
self.C_SourceFile.write(" // Wait for processing logic to complete\n") self.C_SourceFile.write(" // Wait for processing logic to complete\n")
#self.C_SourceFile.write(" ZestSC1ReadRegister(g_Handle, BASE_ADDR + %s, &flag);\n" % #self.C_SourceFile.write(" ZestSC1ReadRegister(g_Handle, BASE_ADDR + %s, &flag);\n" %
# hex(int(VHDL_Circuit.lookupSP[sp._id]._offset))) # hex(int(VHDL_Circuit.lookupSP[sp._id]._offset)))
self.C_SourceFile.write(" flag = 1; // a dummy BRAVE always work\n")
self.C_SourceFile.write(" }\n\n") self.C_SourceFile.write(" }\n\n")
......
...@@ -703,7 +703,15 @@ class SynchronousToolGlueGeneratorGeneric(Generic[TSource, TDestin]): ...@@ -703,7 +703,15 @@ class SynchronousToolGlueGeneratorGeneric(Generic[TSource, TDestin]):
self.C_SourceFile.write(' if(!strcmp(p_szGlobalState, fConfig)){\n') self.C_SourceFile.write(' if(!strcmp(p_szGlobalState, fConfig)){\n')
self.C_SourceFile.write(' // delegate to HW\n') self.C_SourceFile.write(' // delegate to HW\n')
self.C_SourceFile.write(' printf("[###### Dispatcher ######] Delegating to HW ... (to be implemented) \\n");\n') self.C_SourceFile.write(' printf("[###### Dispatcher ######] Delegating to HW ... (to be implemented) \\n");\n')
self.C_SourceFile.write(' // called_compute_something_Brave_Fpga(pinp, size_inp, poutp, pSize_outp);\n') self.C_SourceFile.write(" %s_%s%s(" % (self.CleanNameAsADAWants(maybeFVname), self.CleanNameAsADAWants(sp._id), fpgaSuffix))
for param in sp._params:
if param._id != sp._params[0]._id:
self.C_SourceFile.write(', ')
if isinstance(param, InParam):
self.C_SourceFile.write('p' + self.CleanNameAsToolWants(param._id) + ', size_' + self.CleanNameAsToolWants(param._id))
else:
self.C_SourceFile.write('p' + self.CleanNameAsToolWants(param._id) + ', pSize_' + self.CleanNameAsToolWants(param._id))
self.C_SourceFile.write(");\n")
self.C_SourceFile.write(' // delegated to HW, return 0\n') self.C_SourceFile.write(' // delegated to HW, return 0\n')
self.C_SourceFile.write(' return 0;\n') self.C_SourceFile.write(' return 0;\n')
self.C_SourceFile.write(' }\n') self.C_SourceFile.write(' }\n')
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment