Live data from Hacker News

Microsoft fixes 5-year-old Defender bug, reducing Firefox-related CPU use by 75%

bugzilla.mozilla.org

121–130 of 443 posts

Re: Microsoft fixes 5-year-old Defender bug, reducing Firefox-related CPU use by 75%

#121
post #77
post #22

Earlier quoted context omitted.

Also worth noting that the "expensive platform feature" you refer to in this specific case means "writing to a file". Something as basic as this should be assumed to be fast on modern operating systems.

No it had nothing to do with Firefox writing files. Firefox was making a bunch of calls to VirtualProtect. Windows Defender (MsMpEng.exe) was then writing to file (an sqlite database) every time one of these calls was made, which was slowing down the system. This comment is a good summary of what the issue was once they understood the problem: https://bugzilla.mozilla.org/show_bug.cgi?id=1441918#c82

Where did you get that idea? Sqlite? Windows Defender isn't using sqlite at all.

Re: Microsoft fixes 5-year-old Defender bug, reducing Firefox-related CPU use by 75%

#123

It's so frustrating this discussion took five years . I'd be grateful for an overview of the bug. I don't think I've seen it on my two systems but I can't be confident.

Five years is nothing for MS. You should see how long the bug in File Explorer has been there, where after navigating to a folder and pressing the down arrow, the second item is selected instead of the first. And it's one of those things that, even though I'm aware of it, it still always catches me causing extra keystrokes. It's like they're trying to force me to use the mouse for some reason.

Re: Microsoft fixes 5-year-old Defender bug, reducing Firefox-related CPU use by 75%

#124
post #26
post #19

Earlier quoted context omitted.

> I don't think it's the FireFox' team's responsibility to be aware of and take into account arbitrary software intercepting system calls. Per the bug report, Firefox was generating up to ~14,000 calls where Chrome was generating ~300, though. Surely it is Firefox' team's responsibility to use system calls in a sane way, say not almost 50x more than the competition?

Did you read the bug report? This is literally about writing to files in a temp folder. Surely you can optimize that but you should also be able to assume that this does not use excessive amounts of CPU on a modern operating system.

I usually assume that even vaguely considering looking in the same direction as a file on windows will melt my CPU.

Re: Microsoft fixes 5-year-old Defender bug, reducing Firefox-related CPU use by 75%

#126

Quick napkin math of the wasted power : Firefox has ~300e6 users, let's assume the bug wasted 5 extra watts 4 hours a day. That's 250 megawatts saved, the equivalent of an average coal power plant. Because some Microsoft engineer missed a bug.

> That's 250 megawatts saved, the equivalent of an average coal power plant. Because some Microsoft engineer missed a bug. Are you sure you want to invoke this logic? Because following it through imagine the energy savings if Firefox users switched to Chrome.

Does Chrome really use significantly less resources than Firefox? Are there numbers there?

Re: Microsoft fixes 5-year-old Defender bug, reducing Firefox-related CPU use by 75%

#127

Earlier quoted context omitted.

You also have to assume that at least one Microsoft employee has Firefox installed. There's no bug if there's no users

I work at MS, tried to use Firefox but couldn't because FF doesn't integrate with the Windows cert store. Crucially, this keeps Windows Hello (TPM auth) from working, which makes it useless for any internal websites. For a while I used a hand-compiled PKCS#12 plugin that bridged to the cert store, but that was extremely fragile and eventually I gave up. I think this is probably a major blocker for many enterprise use…

Microsoft now blocks non edge browsers with conditional access policies.

Re: Microsoft fixes 5-year-old Defender bug, reducing Firefox-related CPU use by 75%

#128
post #73

Earlier quoted context omitted.

You really shouldn’t assume anything in software or any complex system. I know this wouldn’t fly at my job, and I don’t work at Mozilla. This is basic testing. Normally this is the mark of a bad software engineer, but attempting to blame the platform you’re on for your lack of testing takes it a to a new low. Mistakes happen, admitting full incompetence that basic testing isn’t done is damning. This is not a good def…

Not sure what your job is, but in my job: - we implement a feature, test it thoroughly for functional and non-functional requirements - when we are happy, we release it I don't see myself being responsible for a third party software company coming along years later and introducing a bug in code that injects itself between my software and the operating system that users of the software I wrote happens to install at so…

The OS isn't some random third party software, it's one of your dependencies. Your software doesn't work without the OS and if it also doesn't work with the OS, it just plain doesn't work.

Re: Microsoft fixes 5-year-old Defender bug, reducing Firefox-related CPU use by 75%

#129

Earlier quoted context omitted.

I don't know if that's the case. I'm a Firefox user but consider all the 3rd party apps nearly as much malware as the things they are trying to solve. I run strictly defender and try to make good choices when downloading and browsing.

well, if we're taking strictly subjective personal experiences as some sort of a relevant benchmark, then I'm a Windows Firefox user that has never used MS defender for any length of time, and always strictly a reliable low-impact 3rd party AV like ESET or Emsisoft. so I guess the two of us cancel each other out.

> strictly a reliable low-impact 3rd party AV

Sounds good

> like ESET

What?! ESET used to burn constant CPU when wifi disconnected.

Re: Microsoft fixes 5-year-old Defender bug, reducing Firefox-related CPU use by 75%

#130

Earlier quoted context omitted.

> That's 250 megawatts saved, the equivalent of an average coal power plant. Because some Microsoft engineer missed a bug. Are you sure you want to invoke this logic? Because following it through imagine the energy savings if Firefox users switched to Chrome.

Does Chrome really use significantly less resources than Firefox? Are there numbers there?

It took a lot longer for Firefox to get GPU accelerated video playback on Linux iirc

Perhaps a "niche" use case for some, but there's a lot more Firefox users on Linux in particular

Post reply on HN