Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 17 additions & 2 deletions src/profile-logic/tracks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ import {
computeStackTableFromRawStackTable,
computeFrameTableFromRawFrameTable,
} from './profile-data';
import {
computeCombinedMarkerSchemaList,
getMarkerTypesForDisplay,
} from './marker-data';
import { intersectSets, subtractSets } from '../utils/set';
import { StringTable } from '../utils/string-table';
import { splitSearchString, stringsToRegExp } from '../utils/string';
Expand Down Expand Up @@ -324,9 +328,16 @@ export function computeLocalTracksByPid(
}

// find markers that might have their own track.
const markerSchemasWithGraphs = (profile.meta.markerSchema || []).filter(
const markerSchema = computeCombinedMarkerSchemaList(
profile.meta.markerSchema || []
);
const markerSchemasWithGraphs = markerSchema.filter(
(schema) => Array.isArray(schema.graphs) && schema.graphs.length > 0
);
const ipcTimelineMarkerTypes = getMarkerTypesForDisplay(
markerSchema,
'timeline-ipc'
);

for (
let threadIndex = 0;
Expand Down Expand Up @@ -356,7 +367,11 @@ export function computeLocalTracksByPid(
tracks.push({ type: 'network', threadIndex });
}

if (markers.data.some((datum) => datum && datum.type === 'IPC')) {
if (
markers.data.some(
(datum) => datum && ipcTimelineMarkerTypes.has(datum.type)
)
) {
// This thread has IPC markers.
tracks.push({ type: 'ipc', threadIndex });
}
Expand Down
Loading