Dear all, here: https://github.com/H2020-COSSIM/cMcPAT you can find a slightly modified version of McPAT along with conversion scripts to connect GEM5 and McPAT.
The differences between McPAT v1.3 and cMcPAT are documented. The conversion scripts are based on the source code that you mention, however they are modified and updated so that no errors arise from using the newer versions of GEM5 or when using simpleCPU models that there are issues between gem5 outputs and what McPAT requires. Additionally you can find xml templates for McPAT that can be used when x86 and ARM simpleCPU models are used in gem5. Hope it proves useful. Best, Andreas On Wed, Jan 24, 2018 at 4:25 PM, Gus Smith <[email protected]> wrote: > You're going to have to debug the Python script and make changes yourself. > I used that same tool and had some issues. In this specific instance, it > looks like the statLine object (which I assume is a regex object) is not > finding any matches in the line object (which I assume is a string). Thus, > None is returned. When group() is called on None, that error is thrown. > > I didn't hit this specific issue with the script, but I did "fix" (not > really a great fix) another issue. Feel free to apply the following patch. > > diff --git a/GEM5ToMcPAT.py b/GEM5ToMcPAT.py > index 8db9674..8be8a32 100755 > --- a/GEM5ToMcPAT.py > +++ b/GEM5ToMcPAT.py > @@ -73,7 +73,11 @@ def dumpMcpatOut(outFile): > exprs[i] = str(eval(exprs[i])) > param.attrib['value'] = ','.join(exprs) > else: > - param.attrib['value'] = str(eval(str(value))) > + try: > + param.attrib['value'] = str(eval(str(value))) > + except: > + print("error: " + str(value)) > + param.attrib['value'] = "0" > > #replace stats with values from the GEM5 stats file > statRe = re.compile(r'stats\.([a-zA-Z0-9_:\.]+)') > > Good luck! > > Gus Smith > > _______________________________________________ > gem5-users mailing list > [email protected] > http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users >
_______________________________________________ gem5-users mailing list [email protected] http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
