andikleen / pmu-tools

Intel PMU profiling tools
GNU General Public License v2.0
2.04k stars 340 forks source link

mapfile.csv is malformed #380

Closed boramalper closed 3 years ago

boramalper commented 3 years ago

I found that mapfile.csv (that pmu-tools use) is malformed. The last line of mapfile.csv (updated on 2 June 2021 at 07:19) contains a redundant comma that causes an exception in toplev --print:

GenuineIntel-6-6C,V1.04,/ICX/icelakex_core_v1.04.json,core
GenuineIntel-6-6C,V1.04,/ICX/icelakex_uncore_v1.04.json,uncore
GenuineIntel-6-96,V1.01,/EHL/,elkhartlake_core_v1.01.json,core
                             ^
                            here
Traceback (most recent call last):
  File "/usr/local/pmu-tools/toplev", line 3457, in <module>
    ectx.emap = ocperf.find_emap()
  File "/usr/local/pmu-tools/ocperf.py", line 940, in find_emap
    return json_with_extra(el, eventmap_is_file)
  File "/usr/local/pmu-tools/ocperf.py", line 842, in json_with_extra
    name = event_download.eventlist_name(el, "core")
  File "/usr/local/pmu-tools/event_download.py", line 223, in eventlist_name
    files = parse_map_file(name, key, acceptfile=True)
  File "/usr/local/pmu-tools/event_download.py", line 140, in parse_map_file
    cpu, version, name, typ = n
ValueError: too many values to unpack (expected 4)

It is clearly an upstream bug but I could not find their maintainers. Would you perhaps be able to contact them?

andikleen commented 3 years ago

Thanks. It's fixed now, but it'll probably take a day to get out to the download server.