5 ms·
Well, also Firefox is making an excessive number of calls to that slow system call compared to other browsers (Chrome, Edge).
by Diggsey 4y ago
Well, also Firefox is making an excessive number of calls to that slow system call compared to other browsers (Chrome, Edge).
- sfink 4y agoMy understanding is that until recently (January), V8 (inside Chrome & Edge) made a similar number of calls. The main use is making it so that JIT-generated code is not writable while it is executing. It's an important security measure. V8 switched to a more recent mechanism (memory protection keys) that have been gradually getting support from the various OSes. But IIUC, they switched off the mprotect/VirtualProtect calls unconditionally, and added in the protection key stuff only where supported, which suggests that they left some configurations without any protection at all. SpiderMonkey (in Firefox) has not yet switched to the cheaper mechanism. I may have some of the details wrong. https://source.chromium.org/chromium/_/chromium/v8/v8.git/+/32f82d0f4831dbdb242940d3dfb5048c986f5560 https://source.chromium.org/chromium/_/chromium/v8/v8.git/+/...
- nagisa 4y agopkeys are hardware-specific as far as I am aware, and at least last time I tried them didn't work on hardware as recent as zen 1.
- zokier 4y agoWell, it was fast system call until MS added AV hook to it.
- Diggsey 4y agoMy comment was only intended to add missing information to the TLDR (since this fact is important in the linked thread) not to say that Firefox is at fault. Now that you raised it however, even if the system call used to be fast, Firefox is making an extremely high number of calls to that sytem call, and there's always going to be some overhead to that. There are almost certainly ways that Firefox could reduce the number of calls it needs to make.
- gcp 4y agoWhat determines "excessive"? In this case it's for a security feature that Chrome lacks(!).