andikleen / pmu-tools

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

all-tester run failed #470

Closed likooooo closed 1 year ago

likooooo commented 1 year ago

hi, this is my first time using pmu. I get some traceback after the following steps :

  1. clone the event files from github : git clone git@github.com:intel/perfmon.git
  2. set the PERFMONDIR file to the cloned directory : export PERFMONDIR=/home/like/code/perfmon
  3. run pmu-tool's tester : /home/like/code/pmu-tools/all-tester

all-tester failed to run with traceback :

Traceback (most recent call last): 
File "/home/like/code/pmu-tools/./ocperf.py", line 1217, in <module>                                                                                  
    emap = find_emap(pmu=pmu.replace("/sys/devices/", ""))                                                                                             
File "/home/like/code/pmu-tools/./ocperf.py", line 992, in find_emap                                                                                   
    return json_with_extra(el, eventmap_is_file, pmu)                                                                                                  
File "/home/like/code/pmu-tools/./ocperf.py", line 887, in json_with_extra                                                                             
    name = event_download.eventlist_name(el, key=typ[0], hybridkey=typ[1])                                                                             
File "/home/like/code/pmu-tools/event_download.py", line 251, in eventlist_name                                                                        
    files = parse_map_file(name, key, acceptfile=True, hybridkey=hybridkey)                                                                            
File "/home/like/code/pmu-tools/event_download.py", line 192, in parse_map_file                                                                                                    
    getfile(url, dirfn, fn)                                                                                                                            
File "/home/like/code/pmu-tools/event_download.py", line 99, in getfile                                                                                
    f = urlopen(url)                                                                                                                                   
File "/usr/lib/python3.10/urllib/request.py", line 216, in urlopen                                                                                     
    return opener.open(url, data, timeout)                                                                                                             
File "/usr/lib/python3.10/urllib/request.py", line 503, in open                                                                                        
    req = Request(fullurl, data)                                                                                                                       
File "/usr/lib/python3.10/urllib/request.py", line 322, in __init__                                                                                    
    self.full_url = url                                                                                                                                
File "/usr/lib/python3.10/urllib/request.py", line 348, in full_url                                                                                    
    self._parse()                                                                                                                                      
File "/usr/lib/python3.10/urllib/request.py", line 377, in _parse                                                                                     
    raise ValueError("unknown url type: %r" % self.full_url)                                                                                         
ValueError: unknown url type: '/home/like/code/perfmon/HSW/events/haswell_core.json'  
andikleen commented 1 year ago

I don't know why you do the manual clone, pmu-tools automatically downloads the event files. If you use PERFMONDIR you have to use file://