from openpower.simulator.program import Program
-def simulation(lst,RS,RA,RB):
-
- initial_regs = [0] * 32
- initial_regs[0] = RS
- initial_regs[1] = RA
- initial_regs[2] = RB
+def simulation_svp(lst,initial_regs):
with Program(lst, bigendian=False) as program:
sim = run_tst(program, initial_regs)
- print(sim.gpr)
- print("gpr 0 is : ")
- print(hex(sim.gpr[0].value))
- return sim.gpr(0).value
+ return sim.gpr
# this function is extracted from bigint_cases.py (should be in a library)
# it is a python implementation of dsrd, see pseudocode in