4 ms·
The Commodore 64 ran at 320x200 at paletted 2bpp (16kB framebuffer size). My MacBook Pro runs at 2880x1800 24bpp (15.5MB framebuffer size). So one frame on your
by pcwalton 8y ago
The Commodore 64 ran at 320x200 at paletted 2bpp (16kB framebuffer size). My MacBook Pro runs at 2880x1800 24bpp (15.5MB framebuffer size). So one frame on your MacBook Pro has to render the equivalent of 972 C64 frames. That makes a big difference—and remember, what matters here is memory bandwidth, which is not subject to Moore's Law the way that CPU speed is.
What's more, we care about power efficiency nowadays in a way that the C64 did not. So while we could make things run as fast as possible, now we have to trade that off against power constraints. The C64 ran at about 22 W while sitting at the ready prompt [1]; my MBP is using about 11 W typing this comment in Firefox.
That's not even getting into the fact that we care about high-quality vector text (and now UI) rendering, secure multiplexing (e.g. having mutually untrusting Web pages share the display with each other) which tends to add extra blitting here and there, internalization, etc. Rendering is expensive because your needs are expensive.
[1]: https://www.lemon64.com/forum/viewtopic.php?t=48631&sid=fe030019ad4bea3f84607dfa34336009 https://www.lemon64.com/forum/viewtopic.php?t=48631&sid=fe03...
- dragontamer 8y ago> That makes a big difference—and remember, what matters here is memory bandwidth, which is not subject to Moore's Law the way that CPU speed is. I disagree. DDR4 bandwidths at 2666 MT/s are over 20GBps per stick, 40GBps on a standard dual-channel laptop is very common. 10 years ago, your DDR2-800 sticks would only give 6.4GBps (12.8GBps total). We now have 15.6GBps over PCIe 3.0 x16 (!!), I/O of a modern 2019 computer has the same bandwidth as DDR2 RAM of 2009. Bandwidth has been increasing plenty. Latency is still basically the same over the last 10 years, but the field of computers has grossly more bandwidth today than ever before. I agree that rendering is expensive, but modern computers are quite good.
- tmd83 8y agoI'm not a rendering expert but those numbers really is glossing over a lot of facts. If you are comparing power you have to remember how much progress semiconductors have made. Now both the processing need, display density etc. has increased so it's no way a straight comparison. But that's not even the main point. Most applications are a tremendous memory bloat and if memory bandwidth is a limitation factor 15.5MB is not the problem here but that bloat is. And for sure browsers are the worst offender and so a degree that it would have been if it wasn't so tragic. Now you can also say browsers have a lot to do, lots of complexity and I agree. But it's the complexity that we have added. And what browsers and website themselves (with bloated js tracking and add and pointless functionality) have done is to lower the standard to such a degree that there is no longer a concept of leanness. I know gmail would use more ram than older desktop clients and for sure provide on client side a fraction of the functionality. On the server side there's at least a performance concern for a lot of people but on client side it's like it's not my money why not waste it. I'm not saying individual developers are thinking about wastage but we have made an echo system where bloat and wastage is the norm. I will be truly hard pressed to find any client application in genre that is actually faster than it was five years or even ten years ago and doesn't stumble more than before on general usage.
- pcwalton 8y agoBrowsers are not "memory bloated". Go look at about:memory and see what the memory actually goes to. It's mostly the JS heap, images, media, etc. You need those things to be in memory because pages demand that those things be in memory. Browsers have probably gotten more effort put into memory usage than any other type of desktop or mobile app. Certainly it's far more effort than any of those apps in the 90s received.
- tmd83 8y agoAnd yet where we are. And why wouldn't I consider those parts of the browser specially not including JS heap from any measure is absurd. I am primarily using Chrome these days. I just looked at its own report. One of my gmail account tab is using 891M memory. I am not saying it's entirely the fault of the browser but whole web echo system. What you said is actually true that this is the result after millions of dollars worth of effort in trimming the fat. But that only turns it from absurd to actually pitiful. I am not faulting individual developers or just browsers of course. It's from the spec, to the browser, to the web developers but if people don't accept web as a whole for all the fabulous advantage/access they provide which I don't discount is out of control this will never fix. There are fundamental problem here and no amount of incremental improvement will probably fix it. I guess I will rant for a few more years to myself before accepting the status quo. I don't restart my browser or machine for fairly long time and those few long running tabs keep increasing in memory. I also just opened up firefox and loaded up that same gmail account fresh. I think it started off at 350 and 5 minutes later it's over 400MB. Maybe it happened after I switched to web based client fully but I think I never had a desktop mail client that took 400MB memory. I am a server side programmer who isn't really some grand expert in performance (nowhere close) and I work with fat bloated Java but I still know 400MB gets you a long way or it should.