Live data from Hacker News

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

bugzilla.mozilla.org

381–390 of 443 posts

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

#381
post #121

Earlier quoted context omitted.

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

It detects the use of SQLite, then copies it, etc etc. Read the bug for more details.

I can assure you that I perfectly understand the bug and corresponding patch/fix. The patch fixes Event Tracing for Windows (ETW) and how it allocates temp buffers.

The speculation about SQLite at the top of that Mozilla bug report is mostly irrelevant.

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

#383

Earlier quoted context omitted.

Third party developers are free to go here and see what Apple is doing: https://github.com/WebKit/WebKit > Most users wouldn’t even notice that their choice to use Safari is responsible for their great battery life. Seeing that MacOS has called out which apps are using the most energy for years, users can definitely tell which apps are using the most battery life.

Apple can and does leave things out of that repo.

So you think there is a conspiracy by Apple to not allow third parties to be battery efficient and make there hardware look bad?

But you are free to download the source code, compile and run it yourself to see if it is less battery efficient than the official builds.

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

#384

Earlier quoted context omitted.

> Are you sure you want to invoke this logic? Because following it through imagine the energy savings if Firefox users switched to Chrome. Ironically, Mac users routinely complain about how power-hungry Chrome is on the Mac. Safari is significantly more efficient.

Is that because of the quality of Chrome or because Safari is a "blessed" application and probably gets to do things other applications do not? Entirely serious question. Apple is known to severely privilege their own applications over competitors.

I’ve not noticed a difference between safari and brave, so I’d say the former is not blessed.

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

#385
post #276

Earlier quoted context omitted.

Is that because of the quality of Chrome or because Safari is a "blessed" application and probably gets to do things other applications do not? Entirely serious question. Apple is known to severely privilege their own applications over competitors.

Blessed or not, I still end up using Safari. The improvement in battery life is too significant to ignore

Have you compared versus Orion, which is also based on WebKit (and can run most Chrome and Firefox extensions)?

IME, Safari is no better than Brave in terms of battery, even when I’ve got hundreds of tabs open.

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

#386

Earlier quoted context omitted.

Gaming on a mid-tier modern GPU probably uses around 50-100w, the Steam stats probably have a number of users to multiply with. I'm sure it's a massive amount of power. I don't like video games and they are not-necessary so I propose that we ban them globally, or only allow gaming if using renewable energy. If you don't live in a place where this is an option, too bad! Maybe instead of this we require all games to be…

This is a bad comparison, gaming presumably brings utility to someone whereas this was a pure bug with no upside.

The bug was an accident though, not something intentional!

My intention was to compare the listed things against MicroSoft engineers making mistakes while programming Windows Defender (the quote below), or programmers writing bugs in general.

>Because some Microsoft engineer missed a bug.

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

#387

Earlier quoted context omitted.

A bagel is a first-degree pretzel.

For those people unfamiliar with a pretzel, imagine eating something that is making you thirsty.

For those people unfamiliar with this joke, watch the TV show Seinfeld.

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

#388

Earlier quoted context omitted.

Don't forget the waste caused by people throwing away devices that are "too slow", and the resources required to build new computers/phones. Somewhere I saw a rough figure about phones. Something like: if everyone was able to keep their phone one year longer, it would be the equivalent of 600,000 cars off the road or something. (Just looked it up - source is possibly the founder of iFixit). But you know, development…

Yep. Most things most users do on our computers could be done just fine on a computer from 10 years ago. I think we're on a performance treadmill like this: - Developers get new, fast devices (yay). We make our software just fast enough to run smoothly (enough) on our own devices. Then we ship it. - Users' computers are slower than the developers' computers. Users experience is bad because the software is slow. - Use…

This is interesting, but maybe our software is doing a lot more today than it was back then. I guess the question is whether those things are necessary. There is of course some software that is just slower because of negligence too.

I remember using a computer 20 years, and they would take multiple minutes to boot into something that was usable, and executing programs would take quite a few seconds because the HDD had to go searching for stuff the executable required.

My current desktop has a Samsung 970 NVME SSD, it boots up in like 20 seconds or something, and everything is extremely responsive as far as reading from the disk goes.

It's interesting that the one thing that hasn't been completely neutralized by the treadmill is SSDs!

Also the LLVM and Rustc thing is interesting. I imagine they are doing much more advanced optimizations than what compilers did 20 years ago so they probably have a good excuse, but I think these optimizations are also neutralized by the treadmill eventually.

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

#389

Earlier quoted context omitted.

Actually, in the PC/laptop space, I believe this phenomenon has been waning somewhat over the past... oh, the better part of a decade. This is a result of: * Single-core performance no longer dramatically improving - almost plateauing * The rate or extent of "bells and whistles" and other OS overhead being added - decreasing. * Budget consumer CPUs having reached smooth desktop performance (with sufficient memory and…

I would say we're coming to that point with phones too. Phones have also largely reached the end of their breakneck big-annual-improvement phase; There's little annual improvement in performance, power consumption, form factor or feature set. Screen resolutions are plenty high for most users, similar for the cameras. Most people would also probably be quite happy with the version of Android or iOS they are using if i…

> Most people would also probably be quite happy with the version of Android or iOS they are using if it kept getting bugfixes and security updates.

Absolutely! Most non-tech folks would be delighted by this. Regular users generally don't care one bit about whatever fad style or trendy feature got added with the latest update, they are just annoyed that their buttons or icons got moved around.

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

#390

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.

Takeaway: If you're working for a tech company with billions of users, your personal CO2 footprint is completely irrelevant. Rather than agonizing over flights vs. trains, beef vs. pork vs. vegan alternatives, heating etc. - find some small thing that you have access to and that you can optimize.

That's about 2.2 TWh per year. A decent estimate for average worldwide CO2 intensity of electricity is 400 gCO2e/kWh (that's 400 tons per GWh). A typical personal footprint including some international flights will be in the tens of tons.

Post reply on HN