[-] kornel@programming.dev 15 points 10 months ago

This is how security works in the C programming language.

[-] kornel@programming.dev 26 points 11 months ago

CS1 never fully integrated expansion packs, so there were three different ways to zone the industry, and a long disorganized list of ad-hoc zoning policies. CS2 had a chance to start with more of this more coherently designed.

Plus CS2 made road editing much more precise and flexible. You can add and remove lanes instead of having separate road types for 150 different lane configurations.

[-] kornel@programming.dev 15 points 11 months ago

It’s more likely that they’ve hit a driver bug, or accidentally pushed a build with some debug junk. They wouldn’t intentionally release game that runs 15fps on 4090.

22
Famous ADHDers part 1 (www.sciencedaily.com)
submitted 11 months ago by kornel@programming.dev to c/adhd@lemmy.world
[-] kornel@programming.dev 4 points 1 year ago

Happy to see Rust’s standard library near the top in performance. It’s nice to have a good implementation out of the box.

[-] kornel@programming.dev 4 points 1 year ago

This has always been the case. When Windows XP came out people hated it needed 64MB (not GB) of RAM, because that was more than the entire disk installation of Windows 95, which was also bloated compared to older Macs and Amigas.

[-] kornel@programming.dev 21 points 1 year ago

I’ve got an ARM Mac. I’ve got ARM VPSes from Hetzner, and I’m compiling native code for the server.

It’s definitely easier to develop, build, and test on the same architecture, than to deal with cross-compilation and emulation.

So I think Linus is right.

[-] kornel@programming.dev 10 points 1 year ago

Filomena is brilliant

1
[-] kornel@programming.dev 32 points 1 year ago* (last edited 1 year ago)
[-] kornel@programming.dev 31 points 1 year ago

Use the system webview, you cowards!

Developers bundle all of Chromium, because they're afraid the OS webview will have a different browser engine. Testing is too hard…

This is such a terrible excuse — usually the same app runs in browsers too, so it already has to deal with even wider variety of browser engines.

[-] kornel@programming.dev 18 points 1 year ago* (last edited 1 year ago)

The annoying popups are an act of malicious compliance from data harvesting companies. The tracking industry wants people to associate the right to privacy with stupid annoyance, so that people will stop demanding privacy.

The legislation does not say anything about cookies. It's about rights and responsibilities in data collection (no matter how it's done technically). The "consent" part of it exists as a compromise, because there has been heavy lobbying against the legislation.

This is not a technical problem — we've had many technologies for it, and the industry has sabotaged all of them. There was the P3P spec in 2002! It has been implemented in IE that had 90%+ market share back then. And Google has been actively exploiting a loophole in IE's implementation to bypass it and have unlimited tracking. Google has paid fines for actively subverting Safari's early anti-tracking measures. Then browsers tried DNT spec as the simplest possible opt-out, and even that has been totally rejected by the data harvesting industry. There are easy technical solutions, but there are also literally trillions of dollars at stake, and ad companies will viciously sabotage all of it.

[-] kornel@programming.dev 14 points 1 year ago

Generally yes.

GIF's ancient LZW compression is remarkably ill-suited for modern CPUs, and more expensive than modern algorithms. Combined with significantly larger file sizes, it costs much more to decode, on top of increased costs of transfer and caching.

GIF might have an edge if the animation is very small (<16px, few frames).

It also gets messy if you need to play hundreds of animations. GIF will be terribly inefficient, but also browsers aren't designed to have hundreds of video elements, so both will eat memory in their own way, and it will vary which is worse.

[-] kornel@programming.dev 6 points 1 year ago* (last edited 1 year ago)

I don't know about C++, but in Rust the push is inline, and still doesn't always optimize checks away due to an annoying edge case: integer overflow. Reserving (old_len + new_len) could give you a smaller buffer than new_len. The optimizer sees it and is pedantic about it.

view more: next ›

kornel

joined 1 year ago