Open Bug 1647518 Opened 4 years ago Updated 2 years ago

Make sure we respect the mach_absolute_time timebase when sending TimeStamps across processes

Categories

(Core :: XPCOM, task)

All
macOS
task

Tracking

()

People

(Reporter: mstange, Assigned: bradwerth)

References

(Blocks 1 open bug)

Details

Attachments

(1 file, 2 obsolete files)

This Apple documentation says:

The value returned by the mach_absolute_time function is different for native and translated processes, and doesn’t necessarily correspond to the number of nanoseconds since boot. Applying timebase information ensures that you can distribute time values between processes and between different computers.

Well spotted!

Now, I would think all Firefox processes will either be fully translated (if we compiled Firefox for Intel), or fully native (if compiled for aarch), so will we ever send timestamps between different types of processes?

(Note to self: If yes, we'll probably need to deal with that in the profiler as well.)

I think it's implied that the timebases only differ between different types, but the docs don't outright state it, so it really sounds like they want us to be generic anyway.
And who knows, maybe we actually need to send timestamps between different types of processes in some cases. We supported IPC between mixed process types on macOS in the past when Flash was only available for 32 bit (so our plugin-container process needed to be a 32 bit process in order to be able to load the plug-in), to communicate with a 64 bit Firefox process. It's not unthinkable that we might need something like that again, for example for EME.

I can get this at least started.

Assignee: nobody → bwerth

Depends on D100733

Comment on attachment 9195329 [details]
Bug 1647518 Part 2: Re-apply clang-format to nsAppRunner.cpp.

Revision D100738 was moved to bug 1684982. Setting attachment 9195329 [details] to obsolete.

Attachment #9195329 - Attachment is obsolete: true

Comment on attachment 9255803 [details]
docs: Bug 1647518 Part 3: Update crash-ping documentation.

Revision D134072 was moved to bug 1744135. Setting attachment 9255803 [details] to obsolete.

Attachment #9255803 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: