[Libre-soc-bugs] [Bug 1039] add hardware-cycle-accurate stastistical modelling to ISACaller for an in-order core

bugzilla-daemon at libre-soc.org bugzilla-daemon at libre-soc.org
Sun May 14 22:09:41 BST 2023


--- Comment #11 from Dmitry Selyutin <ghostmansd at gmail.com> ---
Jacob, Luke, I've re-checked the discussion[0][1], and came to conclusion that
you both have valid points, so I decided to go with something intermediate. The
branch tracefile contains the following functionality:
1. Every ISACaller instance can be provided with `tracefile` argument; this
argument must be any object which has a callable `write` attribute or None.
2. If `ISACaller.tracefile` is None, then we create a temporary file.
3. However, we don't save these temporary files, unless TRACEFILE environment
variable is set to anything. By default, these files are __transient__.
4. If and only if the user sets TRACEFILE environment variable, the tracefiles
are kept.
5. The files have names starting with "trace_" and ending with ".trace".
Everything inbetween obeys tempfile.NamedTemporaryFile rules.
6. test_runner has extended names, starting with either "trace_testXX_" or
"trace_subtestXX_", where XX stands for global test counter (if launched via
run_tst) or for test_case unique counter (nmutil.get_test_path.Counter).
Everything inbetween obeys tempfile.NamedTemporaryFile rules.

This way:
1. We avoid conditional code which checks whether `self.tracefile` is None or
2. We can turn tracefiles on/off via environment (I think it'd be a bad idea to
create these by default).
3. Unique per-test and per-subtest trace files are still created.


You are receiving this mail because:
You are on the CC list for the bug.

More information about the libre-soc-bugs mailing list