--- a/testing/talos/talos/xtalos/etlparser.py
+++ b/testing/talos/talos/xtalos/etlparser.py
@@ -24,17 +24,26 @@ FNAME_COL = "FileName"
IMAGEFUNC_COL = "Image!Function"
EVENTGUID_COL = "EventGuid"
ACTIVITY_ID_COL = "etw:ActivityId"
NUMBYTES_COL = "NumBytes"
CEVT_WINDOWS_RESTORED = "{917b96b1-ecad-4dab-a760-8d49027748ae}"
CEVT_XPCOM_SHUTDOWN = "{26d1e091-0ae7-4f49-a554-4214445c505c}"
NAME_SUBSTITUTIONS = [
- (re.compile(r'{\w{8}-\w{4}-\w{4}-\w{4}-\w{12}}'), '{uuid}')
+ # Careful with your regex!
+ # Substitution happens after combinations like \t \s \n ... are replaced
+ # with their real representations. So, prepend them with extra backslash.
+ # Read more: https://docs.python.org/2.7/library/re.html#re.sub
+ (re.compile(r'{\w{8}-\w{4}-\w{4}-\w{4}-\w{12}}'), '{uuid}'),
+ (re.compile(r'talos\\tests\\tp5n\\.*'), r'talos\\tests\{tp5n_files}'),
+ (re.compile(r'nvidia corporation\\3d vision\\.*'), '{nvidia_3d_vision}'),
+ (re.compile(r'cltbld\.t-w732-ix-\d+\.\d+'), '{cltbld}'),
+ (re.compile(r'venv\\lib\\site-packages\\pip\\_vendor\\.*'),
+ r'venv\lib\\site-packages\\{pip_vendor}'),
]
stages = ["startup", "normal", "shutdown"]
net_events = {
"TcpDataTransferReceive": "recv",
"UdpEndpointReceiveMessages": "recv",
"TcpDataTransferSend": "send",
"UdpEndpointSendMessages": "send"
}
@@ -363,29 +372,29 @@ def etlparser(xperf_path, etl_filename,
if outputFile:
# close the file handle
outFile.close()
if debug:
uploadFile(outputFile)
# We still like to have the outputfile to record the raw data, now
# filter out acceptable files/ranges
- filename = None
+ whitelist_path = None
wl_temp = {}
dirname = os.path.dirname(__file__)
if os.path.exists(os.path.join(dirname, 'xperf_whitelist.json')):
- filename = os.path.join(dirname, 'xperf_whitelist.json')
+ whitelist_path = os.path.join(dirname, 'xperf_whitelist.json')
elif os.path.exists(os.path.join(dirname, 'xtalos')) and \
os.path.exists(os.path.join(dirname, 'xtalos',
'xperf_whitelist.json')):
- filename = os.path.join(dirname, 'xtalos', 'xperf_whitelist.json')
+ whitelist_path = os.path.join(dirname, 'xtalos', 'xperf_whitelist.json')
wl_temp = {}
- if filename:
- with open(filename, 'r') as fHandle:
+ if whitelist_path:
+ with open(whitelist_path, 'r') as fHandle:
wl_temp = json.load(fHandle)
# Approot is the full path where the application is located at
# We depend on it for dependentlibs.list to ignore files required for
# normal startup.
if approot:
if os.path.exists('%s\\dependentlibs.list' % approot):
with open('%s\\dependentlibs.list' % approot, 'r') as fhandle:
@@ -397,17 +406,17 @@ def etlparser(xperf_path, etl_filename,
# Windows isn't case sensitive, this protects us against mismatched
# systems.
wl = {}
for item in wl_temp:
wl[item.lower()] = wl_temp[item]
errors = []
for row in filekeys:
- filename = row[0]
+ filename = original_filename = row[0]
filename = filename.lower()
# take care of 'program files (x86)' matching 'program files'
filename = filename.replace(" (x86)", '')
paths = ['profile', 'firefox', 'desktop', 'talos']
for path in paths:
pathname = '%s\\' % path
parts = filename.split(pathname)
@@ -460,20 +469,21 @@ def etlparser(xperf_path, etl_filename,
# elif wl[filename]['maxcount'] < (files[row]['DiskReadCount'] +\
# files[row]['DiskWriteCount']):
# errors.append("%s: %s accesses, more than expected maximum:"
# " %s"
# % (filename, (files[row]['DiskReadCount'] +
# files[row]['DiskWriteCount']),
# wl[filename]['maxcount']))
else:
- errors.append("File '%s' was accessed and we were not expecting"
+ errors.append("File '%s' (normalized from '%s') was accessed and we were not expecting"
" it. DiskReadCount: %s, DiskWriteCount: %s,"
" DiskReadBytes: %s, DiskWriteBytes: %s"
% (filename,
+ original_filename,
files[row]['DiskReadCount'],
files[row]['DiskWriteCount'],
files[row]['DiskReadBytes'],
files[row]['DiskWriteBytes']))
if errors:
# output specific errors to be picked up by tbpl parser
for error in errors:
--- a/testing/talos/talos/xtalos/xperf_whitelist.json
+++ b/testing/talos/talos/xtalos/xperf_whitelist.json
@@ -1,108 +1,183 @@
{
- "C:\\$Extend\\$UsnJrnl:$J": {
- "ignore": true
+ "\\fi_unknown": {
+ "mincount": 0,
+ "maxcount": 2,
+ "minbytes": 0,
+ "maxbytes": 8192
},
- "C:\\$Mft": {
+ "c:\\$extend\\$usnjrnl:$j": {
"ignore": true
},
- "C:\\$Secure": {
+ "c:\\$logfile": {
"ignore": true
},
- "C:\\$logfile": {
+ "c:\\$mft": {
"ignore": true
},
- "Z:\\$logfile": {
- "ignore": true
- },
- "C:\\Windows\\Prefetch\\{prefetch}.pf": {
+ "c:\\$secure": {
"ignore": true
},
"c:\\program files\\desktop.ini": {
"mincount": 2,
"maxcount": 2,
"minbytes": 352,
"maxbytes": 352
},
- "c:\\program files\\nvidia corporation\\3d vision\\nvstereoapii.dll": {
+ "c:\\program files\\{nvidia_3d_vision}": {
"mincount": 0,
- "maxcount": 4,
- "minbytes": 2,
- "maxbytes": 33792
+ "maxcount": 24,
+ "minbytes": 0,
+ "maxbytes": 578560
},
"c:\\programdata\\nvidia corporation\\drs\\nvapptimestamps": {
"mincount": 22,
"maxcount": 22,
"minbytes": 704,
"maxbytes": 704
},
"c:\\programdata\\nvidia corporation\\drs\\nvdrssel.bin": {
"mincount": 2,
"maxcount": 2,
"minbytes": 2,
"maxbytes": 2
},
+ "c:\\slave\\test\\build\\venv\\lib\\site-packages\\{pip_vendor}": {
+ "ignore": true
+ },
+ "c:\\users\\{cltbld}\\appdata\\locallow\\mozilla": {
+ "mincount": 0,
+ "maxcount": 8,
+ "minbytes": 0,
+ "maxbytes": 32768
+ },
"c:\\users\\desktop.ini": {
"mincount": 2,
"maxcount": 2,
"minbytes": 352,
"maxbytes": 352
},
+ "c:\\windows\\fonts\\segoeuii.ttf": {
+ "mincount": 0,
+ "maxcount": 4,
+ "minbytes": 0,
+ "maxbytes": 90112
+ },
"c:\\windows\\fonts\\staticcache.dat": {
"mincount": 2,
"maxcount": 2,
"minbytes": 120,
"maxbytes": 120
},
+ "c:\\windows\\prefetch\\{prefetch}.pf": {
+ "ignore": true
+ },
"c:\\windows\\system32\\audioses.dll": {
"mincount": 4,
"maxcount": 4,
"minbytes": 16384,
"maxbytes": 32768
},
"c:\\windows\\system32\\dwrite.dll": {
"mincount": 4,
"maxcount": 4,
"minbytes": 16384,
"maxbytes": 90112
},
+ "c:\\windows\\system32\\gdi32.dll": {
+ "mincount": 0,
+ "maxcount": 4,
+ "minbytes": 0,
+ "maxbytes": 114688
+ },
+ "c:\\windows\\system32\\kernel32.dll": {
+ "mincount": 0,
+ "maxcount": 2,
+ "minbytes": 0,
+ "maxbytes": 65536
+ },
+ "c:\\windows\\system32\\mscms.dll": {
+ "mincount": 0,
+ "maxcount": 73728,
+ "minbytes": 0,
+ "maxbytes": 73728
+ },
"c:\\windows\\system32\\msctf.dll": {
"mincount": 0,
"maxcount": 2,
"minbytes": 0,
"maxbytes": 65536
},
+ "c:\\windows\\system32\\spool\\drivers\\color": {
+ "mincount": 0,
+ "maxcount": 2,
+ "minbytes": 0,
+ "maxbytes": 8192
+ },
"c:\\windows\\system32\\spool\\drivers\\color\\srgb color space profile.icm": {
"mincount": 2,
"maxcount": 2,
"minbytes": 8192,
"maxbytes": 8192
},
+ "z:\\$logfile": {
+ "ignore": true
+ },
"{appdata}\\local\\temp": {
"mincount": 0,
"maxcount": 4,
"minbytes": 0,
"maxbytes": 278528
},
"{desktop}\\desktop.ini": {
"mincount": 6,
"maxcount": 6,
"minbytes": 1692,
"maxbytes": 1692
},
- "{firefox}\\Crash Reports\\{time}": {
- "ignore": true
+ "{firefox}\\browser\\blocklist.xml": {
+ "mincount": 0,
+ "maxcount": 66,
+ "minbytes": 0,
+ "maxbytes": 540672
+ },
+ "{firefox}\\browser\\extensions\\{uuid}.xpi": {
+ "mincount": 0,
+ "maxcount": 2,
+ "minbytes": 0,
+ "maxbytes": 8192
+ },
+ "{firefox}\\browser\\features\\aushelper@mozilla.org.xpi": {
+ "mincount": 0,
+ "maxcount": 2,
+ "minbytes": 0,
+ "maxbytes": 24576
+ },
+ "{firefox}\\browser\\features\\flyweb@mozilla.org.xpi": {
+ "mincount": 0,
+ "maxcount": 2,
+ "minbytes": 0,
+ "maxbytes": 32768
},
"{firefox}\\browser\\omni.ja": {
"mincount": 0,
"maxcount": 28,
"minbytes": 0,
"maxbytes": 1835008
},
+ "{firefox}\\crash reports\\lastcrash": {
+ "mincount": 0,
+ "maxcount": 2,
+ "minbytes": 0,
+ "maxbytes": 20
+ },
+ "{firefox}\\crash reports\\{time}": {
+ "ignore": true
+ },
"{firefox}\\defaults\\pref\\channel-prefs.js": {
"mincount": 4,
"maxcount": 4,
"minbytes": 1432,
"maxbytes": 1432
},
"{firefox}\\dependentlibs.list": {
"mincount": 4,
@@ -165,16 +240,22 @@
"maxbytes": 512
},
"{profile}\\content-prefs.sqlite": {
"mincount": 6,
"maxcount": 6,
"minbytes": 65768,
"maxbytes": 65768
},
+ "{profile}\\content-prefs.sqlite-journal": {
+ "mincount": 14,
+ "maxcount": 116,
+ "minbytes": 112,
+ "maxbytes": 1244640
+ },
"{profile}\\cookies.sqlite": {
"mincount": 1,
"maxcount": 6,
"minbytes": 0,
"maxbytes": 200000
},
"{profile}\\cookies.sqlite-shm": {
"mincount": 1,
@@ -237,16 +318,22 @@
"maxbytes": 127000
},
"{profile}\\extensions\\pageloader@mozilla.org\\chrome\\report.js": {
"mincount": 0,
"maxcount": 4,
"minbytes": 0,
"maxbytes": 127000
},
+ "{profile}\\extensions\\pageloader@mozilla.org\\install.rdf": {
+ "mincount": 0,
+ "maxcount": 2,
+ "minbytes": 0,
+ "maxbytes": 8192
+ },
"{profile}\\extensions\\talos-powers@mozilla.org\\chrome.manifest": {
"mincount": 2,
"maxcount": 2,
"minbytes": 600,
"maxbytes": 600
},
"{profile}\\extensions\\talos-powers@mozilla.org\\chrome\\talos-powers-content.js": {
"mincount": 2,
@@ -255,16 +342,22 @@
"maxbytes": 2000
},
"{profile}\\favicons.sqlite": {
"mincount": 8,
"maxcount": 12,
"minbytes": 196808,
"maxbytes": 393216
},
+ "{profile}\\favicons.sqlite-journal": {
+ "mincount": 2,
+ "maxcount": 8,
+ "minbytes": 16,
+ "maxbytes": 9264
+ },
"{profile}\\favicons.sqlite-shm": {
"mincount": 0,
"maxcount": 4,
"minbytes": 65536,
"maxbytes": 131072
},
"{profile}\\favicons.sqlite-wal": {
"mincount": 0,
@@ -273,16 +366,22 @@
"maxbytes": 131072
},
"{profile}\\handlers.json": {
"mincount": 0,
"maxcount": 4,
"minbytes": 0,
"maxbytes": 1388
},
+ "{profile}\\invalidprefs.js": {
+ "mincount": 0,
+ "maxcount": 2,
+ "minbytes": 0,
+ "maxbytes": 25412
+ },
"{profile}\\key3.db": {
"mincount": 0,
"maxcount": 12,
"minbytes": 0,
"maxbytes": 32768
},
"{profile}\\key4.db": {
"mincount": 0,
@@ -315,16 +414,22 @@
"maxbytes": 16384
},
"{profile}\\places.sqlite": {
"mincount": 8,
"maxcount": 8,
"minbytes": 196808,
"maxbytes": 196808
},
+ "{profile}\\places.sqlite-journal": {
+ "mincount": 2,
+ "maxcount": 8,
+ "minbytes": 16,
+ "maxbytes": 9264
+ },
"{profile}\\places.sqlite-shm": {
"mincount": 2,
"maxcount": 2,
"minbytes": 65536,
"maxbytes": 65536
},
"{profile}\\places.sqlite-wal": {
"mincount": 0,
@@ -333,16 +438,22 @@
"maxbytes": 131072
},
"{profile}\\pluginreg.dat": {
"mincount": 2,
"maxcount": 2,
"minbytes": 1892,
"maxbytes": 1892
},
+ "{profile}\\pluginreg.dat.tmp": {
+ "mincount": 0,
+ "maxcount": 30,
+ "minbytes": 0,
+ "maxbytes": 958
+ },
"{profile}\\prefs-1.js": {
"mincount": 0,
"maxcount": 10,
"minbytes": 0,
"maxbytes": 53950
},
"{profile}\\prefs.js": {
"mincount": 4,
@@ -399,21 +510,15 @@
"maxbytes": 6000
},
"{profile}\\xulstore.json": {
"mincount": 0,
"maxcount": 0,
"minbytes": 0,
"maxbytes": 702
},
- "{talos}\\talos\\tests\\tp5n\\tp5n.manifest": {
+ "{talos}\\talos\\tests\\{tp5n_files}": {
"mincount": 0,
- "maxcount": 8,
+ "maxcount": 2,
"minbytes": 0,
- "maxbytes": 32786
- },
- "{talos}\\talos\\tests\\tp5n\\tp5n.manifest.develop": {
- "mincount": 0,
- "maxcount": 8,
- "minbytes": 0,
- "maxbytes": 32786
+ "maxbytes": 16384
}
-}
+}
\ No newline at end of file