Hello all. Currently, I am working on setting up the gem5 simulation for a
project whose goal is to create a "modified"/"upgraded" cache, which is
extended to perform more than just reads and writes.

The first step in this project is the addition of an instruction that will
perform one of these new operations in our upgraded cache. We are
specifically trying to measure the change in total cycle latency between a
system which uses this upgraded cache and a baseline system which doesn't.
We can already compile a piece of source code into two different binaries:
a baseline version (with standard x86 instructions) and a version which
replaces certain operations with cache operations -- I now need to
implement the new instructions in the simulator.

*My question is this: should we add our instruction using a
pseudo-instruction, or via ISA extension?*

I have done my own research on the question, and found two primary
resources that touch on the difference between the two:
This Master's thesis
<http://scholarworks.umass.edu/cgi/viewcontent.cgi?article=1262&context=masters_theses_2>
touches
on the difference in section 1.2.
Gedare's great blog post
<http://gedare-csphd.blogspot.com/2013/02/add-pseudo-instruction-to-gem5.html>
about
adding a pseudo-instruction.
This is what I've gathered:

   - Pseudo-instructions are easier to add.
   - Pseudo-instructions are non-speculative and atomic, which means the
   pipeline is flushed when one of these instructions are found. This means
   that a program with a significant amount of pseudo-instructions will not
   have realistic cycle count statistics -- having realistic cycle count
   statistics is important to us.
   - ISA extension is much less documented (I can't find much on it, though
   the linked thesis may have all the information I need.)
   - ISA extension may be much harder to get right.

I am leaning towards ISA extension, but wanted to pose the question to the
community, as I feel I'm moving into uncharted territory. Feel free to also
share experiences in related projects -- i.e., is there anything I should
watch out for, or is there, perhaps, an easier way to do this?

Some more details about the planned simulation environment:

   - x86
   - Doing standard fs.py full-system simulation with the Linux images on
   the wiki

Thanks all!
_______________________________________________
gem5-users mailing list
[email protected]
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

Reply via email to