Add support to download Geckoprofiler trace. (#2838)
This commit is contained in:
parent
9a2da17601
commit
e3dcd3fdb7
|
|
@ -347,6 +347,13 @@ module.exports.parseCommandLine = function parseCommandLine() {
|
|||
describe: 'Add timer and metrics to the video',
|
||||
group: 'Browser'
|
||||
})
|
||||
.option('browsertime.cpu', {
|
||||
alias: 'cpu',
|
||||
type: 'boolean',
|
||||
describe:
|
||||
'Easy way to enable both chrome.timeline and CPU long tasks for Chrome and geckoProfile for Firefox',
|
||||
group: 'Browser'
|
||||
})
|
||||
.option('browsertime.videoParams.filmstripFullSize', {
|
||||
alias: 'videoParams.filmstripFullSize',
|
||||
type: 'boolean',
|
||||
|
|
@ -629,13 +636,6 @@ module.exports.parseCommandLine = function parseCommandLine() {
|
|||
'Enables CPU throttling to emulate slow CPUs. Throttling rate as a slowdown factor (1 is no throttle, 2 is 2x slowdown, etc)',
|
||||
group: 'Chrome'
|
||||
})
|
||||
.option('browsertime.cpu', {
|
||||
alias: 'cpu',
|
||||
type: 'boolean',
|
||||
describe:
|
||||
'Easy way to enable both chrome.timeline and CPU long tasks. Only works for Chrome.',
|
||||
group: 'Chrome'
|
||||
})
|
||||
.option('thirdParty.cpu', {
|
||||
type: 'boolean',
|
||||
describe:
|
||||
|
|
@ -1512,8 +1512,12 @@ module.exports.parseCommandLine = function parseCommandLine() {
|
|||
}
|
||||
|
||||
if (argv.cpu) {
|
||||
set(argv, 'browsertime.chrome.collectLongTasks', true);
|
||||
set(argv, 'browsertime.chrome.timeline', true);
|
||||
if (argv.browsertime.browser === 'chrome') {
|
||||
set(argv, 'browsertime.chrome.collectLongTasks', true);
|
||||
set(argv, 'browsertime.chrome.timeline', true);
|
||||
} else if (argv.browsertime.browser === 'firefox') {
|
||||
set(argv, 'browsertime.firefox.geckoProfiler', true);
|
||||
}
|
||||
}
|
||||
|
||||
// we missed to populate this to Browsertime in the cli
|
||||
|
|
|
|||
|
|
@ -9,6 +9,13 @@ if browsertime && browsertime.cpu && browsertime.cpu.events
|
|||
- const tracePath = 'data/trace-' + (runNumber? runNumber : 1) + '.json.gz'
|
||||
a.button.button-download(href=tracePath, download=downloadName + '-timeline.json.gz') Download trace log
|
||||
|
||||
if options.browsertime && options.browsertime.firefox && options.browsertime.firefox.geckoProfiler
|
||||
p Download the Firefox Geckoprofiler trace and drag and drop it into
|
||||
a(href='https://profiler.firefox.com') https://profiler.firefox.com
|
||||
.downloads
|
||||
- const tracePath = 'data/geckoProfile-' + (runNumber? runNumber : 1) + '.json.gz'
|
||||
a.button.button-download(href=tracePath, download=downloadName + '-geckoProfile.json.gz') Download trace
|
||||
|
||||
if browsertime && browsertime.cpu && browsertime.cpu.longTasks
|
||||
h3 Long Tasks
|
||||
p Collected using the Long Task API. A long task is a task that take 50 milliseconds or more.
|
||||
|
|
|
|||
|
|
@ -157,7 +157,7 @@ block content
|
|||
section#pagexray-panel
|
||||
include ../pagexray/index.pug
|
||||
|
||||
if options.cpu || (options.browsertime && options.browsertime.chrome && options.browsertime.chrome.collectLongTasks)
|
||||
if options.cpu || (options.browsertime && options.browsertime.chrome && options.browsertime.chrome.collectLongTasks) || (options.browsertime && options.browsertime.firefox && options.browsertime.firefox.geckoProfiler)
|
||||
section#cpu-panel
|
||||
include ../cpu/index.pug
|
||||
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
if d.pagexray && d.pagexray.run
|
||||
a(id='pagexray', href='#pagexray', onclick='return selectTab(this, true);')
|
||||
| PageXray
|
||||
if options.cpu || options.browsertime && options.browsertime.chrome && options.browsertime.chrome.collectLongTasks
|
||||
if options.cpu || options.browsertime && options.browsertime.chrome && options.browsertime.chrome.collectLongTasks || options.browsertime && options.browsertime.firefox && options.browsertime.firefox.geckoProfiler
|
||||
a(id='cpu', href='#cpu', onclick='return selectTab(this, true);')
|
||||
| CPU
|
||||
if d.thirdparty && d.thirdparty.run
|
||||
|
|
|
|||
|
|
@ -158,7 +158,7 @@ block content
|
|||
section#pagexray-panel
|
||||
include ../pagexray/index.pug
|
||||
|
||||
if options.cpu || options.browsertime && options.browsertime.chrome && options.browsertime.chrome.collectLongTasks
|
||||
if options.cpu || options.browsertime && options.browsertime.chrome && options.browsertime.chrome.collectLongTasks || (options.browsertime && options.browsertime.firefox && options.browsertime.firefox.geckoProfiler)
|
||||
section#cpu-panel
|
||||
include ../cpu/index.pug
|
||||
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
if d.pagexray && d.pagexray.pageSummary
|
||||
a(id='pagexray', href='#pagexray', onclick='return selectTab(this, true);')
|
||||
| PageXray
|
||||
if options.cpu || options.browsertime && options.browsertime.chrome && options.browsertime.chrome.collectLongTasks
|
||||
if options.cpu || options.browsertime && options.browsertime.chrome && options.browsertime.chrome.collectLongTasks || options.browsertime && options.browsertime.firefox && options.browsertime.firefox.geckoProfiler
|
||||
a(id='cpu', href='#cpu', onclick='return selectTab(this, true);')
|
||||
| CPU
|
||||
if d.thirdparty && d.thirdparty.pageSummary
|
||||
|
|
|
|||
Loading…
Reference in New Issue