760 karma · joined Jul 3, 2012 (14y ago) · 101 submissions
comment 2mo ago · link · parent
There are a lot of other replies here, but one additional consideration is which solution is generally beneficial outside the original problem domain. A Steam-specific bytecode is applicable to games on Steam, whereas x86 emulation on ARM is of general interest to many problem domains today. Working on the latter could be viewed altruistically (it benefits the larger community) or self-interestedly (other developers are more likely to do work for us), but either way, it's an argument for the generalist path.
comment 2mo ago · link · parent
I still didn't (and don't) love the practice, but it called in to question a lot of my assumptions about what people knew about software, why they used what they did, how they found it, etc.
comment 2mo ago · link · parent
Going above 5%, OTOH, I would be shocked to ever see happen, for two reasons. 1) Mass-market adoption requires working well on an enormous long tail, which is difficult without a large team. 2) The primary driver of playing at that size is mass marketing/distribution, which requires $$$. Engineering a great product is necessary, but not sufficient.
My perspective on this is informed by being on Google Chrome from inception to 2025. Chrome from near the beginning was well-engineered and had three compelling-according-to-user-research advantages over the IE of 2008 (speed, security, and not being made by Microsoft), but mass adoption depended on a large number of non-engineering factors, of which marketing/distribution was (to a then-mid-20s software engineer) the most surprising one. I didn't believe that was what made the difference in which browser most people used; I was very wrong. Techies are not the leading-edge trendsetters for the masses we sometimes believe we are.
IMO, taking mass market share in the future will require either a compelling-to-users product coupled with at least a couple hundred million dollars in marketing and distribution budget, or else something that is completely unlike web browsers of the past (maybe there's something that replaces the web entirely). No one has done the former since Chrome launched; the closest people have come to the latter thus far is things like Dia/Atlas that try to reimagine workflows in an AI context, and I think the market has not found those to be sufficiently different+compelling.
comment 3mo ago · link · parent
> A man is twice the age his wife was when he was the age she is now. When she reaches his present age, their combined years will be 100. Find the age of each.
This seemed initially like something amenable to guessing and checking a few ratios. <narrator voice>It was not.</narrator voice>
My answer: The man is 44 4/9 years old, the wife 33 1/3 years.
comment 6mo ago · link · parent
Hard errors up front are great when you control the full content pipeline. It's very rare that that's the case, and was rare even in 2004. As soon as including someone else's broken content in your page prevents users from seeing your content, and that someone else can break the content at any time and you can't control it... few people will want hard errors.
comment 6mo ago · link · parent
I also used to work on a production C compiler. Compilers can and do "guess what you meant" in various cases, notably for producing actual human-readable errors or proceeding past various warnings, but if I recall correctly even in more obscure non-error cases.
Hyrum's Law is a real jerk sometimes.
comment 10mo ago · link · parent
In Chromium's UI code, we have a lot of APIs that deal with coordinates, which may be in either px or dp. And we have a lot of code that needs to hardcode various constants, e.g. layout values for different dialogs. IMO, it's sane to have UDL support here, e.g. `20_px` (at least if we had separate types to represent these two things, which we don't... don't get me started).
comment 10mo ago · link · parent
I suspect if I dug into the archives, I'd find a discussion on cxx@ with some comments about how doing this would result in some esoteric risk. If I was still on the Chrome team I'd go looking and see if it made sense to reraise the issue now; I know we had at least one stable branch security bug this caused.
comment 10mo ago · link · parent
Anyway, I think there are two takeaways:
1. There probably do exist non-8-bit-byte architectures targeted by compilers that provide support for at-least-somewhat-recent C++ versions
2. Such cases are certainly rare
Where that leaves things, in terms of what the C++ standard should specify, I don't know. IIRC JF Bastien or one of the other Apple folks that's driven things like "twos complement is the only integer representation C++ supports" tried to push for "bytes are 8 bits" and got shot down?
comment 10mo ago · link · parent
comment 10mo ago · link · parent
comment 10mo ago · link · parent
There are cases, however, when the migration costs are significant enough that even those benefits aren't really enough. Migrating our date/time stuff to <chrono> seemed like one of those.
comment 10mo ago · link · parent
That's different from an inability to refactor.