Skip to content

Commit

Permalink
Bug 1884205: Include current time in ETW for markers with unspecified…
Browse files Browse the repository at this point in the history
… timing. r=mstange,profiler-reviewers

Differential Revision: https://phabricator.services.mozilla.com/D203947
  • Loading branch information
Bas-moz committed Mar 8, 2024
1 parent 3b67a4f commit 1f82c6e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion tools/profiler/public/ETWTools.h
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,11 @@ static inline void StoreBaseEventDataDesc(
BaseEventStorage& aStorage, EVENT_DATA_DESCRIPTOR* aDescriptors,
const mozilla::MarkerCategory& aCategory,
const mozilla::MarkerOptions& aOptions) {
if (!aOptions.IsTimingUnspecified()) {
if (aOptions.IsTimingUnspecified()) {
aStorage.mStartTime =
mozilla::TimeStamp::Now().RawQueryPerformanceCounterValue().value();
aStorage.mPhase = 0;
} else {
aStorage.mStartTime =
aOptions.Timing().StartTime().RawQueryPerformanceCounterValue().value();
aStorage.mEndTime =
Expand Down

0 comments on commit 1f82c6e

Please sign in to comment.