Skip to content

Commit 09b1e75

Browse files
authored
Fix the compare view when using the same profile in both entries (#5469)
1 parent 55d6087 commit 09b1e75

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

src/profile-logic/merge-compare.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,13 @@ export function mergeProfilesForDiffing(
9393

9494
// Copy over identical values for the ProfileMeta.
9595
for (const [key, value] of Object.entries(profiles[0].meta)) {
96+
// Do not copy over some properties though.
97+
// profilingStartTime and profilingEndTime, if present, are used to define
98+
// the root range directly. But because we adjust timestamps below in each
99+
// threads, these values won't be correct anymore.
100+
if (['profilingStartTime', 'profilingEndTime'].includes(key)) {
101+
continue;
102+
}
96103
if (profiles.every((profile) => profile.meta[key] === value)) {
97104
resultProfile.meta[key] = value;
98105
}

0 commit comments

Comments
 (0)