HackerLangs
TopNewTrendsCommentsPastAskShowJobs

titzer

19,802 karmajoined 13 years ago
WebAssembly co-founder, former V8 compiler techlead and engineer.

My programming language: http://github.com/titzer/virgil My newest Wasm engine: http://github.com/titzer/wizard-engine

comments

titzer
·5 hours ago·discuss
When satellites smash into each other at high velocity, they explode. Some of that debris will end up in higher orbits and linger.
titzer
·2 days ago·discuss
I've picked up enough plastics off the beaches of the world already. Plastic ruins ecosystems and is a scourge on this planet. It's too late to fix, it's everywhere. 8 million tonnes of plastics enter the oceans every year, and it just keeps accumulating. We're ruining marine ecosystems.
titzer
·5 days ago·discuss
Typechecking is more less picking a decidable set of invalid programs and making an efficient checker for them. As for ruling out programming styles, a language is, after all, Turing complete, so one could write an IR and an interpreter and then encode the rest of the program in the IR...

Personally, while I see the social advantages of having all code in one language be similarly structured and use the same idioms, I think a language is meant to be used, and it should offer all the building blocks for writing programs in whatever is the most natural way.
titzer
·6 days ago·discuss
Because rich people want more money. They keep saying it's for the good of humanity and some useful idiots keep repeating that. A more balanced tax policy, regulation of financial markets, incentives to renewals, stopping investment in fossil fuels, increasing energy efficiency, and rewilding could all help, but we won't do a lick of it, because every single one of those things goes against the billionaires who own the political class.
titzer
·8 days ago·discuss
8 hours in fuzzy spot one, 8 hours in fuzzy spot two, fitting some gaussian distribution, and then a few points at other times, and boom, not anonymous at all.
titzer
·8 days ago·discuss
I didn't read the law but the article referred to it as "personal data". It's important to note that Big Tech believes it can "anonymize" fine-grained location data but just stripping PII and assigning a semi-stable random ID. They'll then argue this law doesn't apply because of that.

That's absolute crap because geolocation data is extremely easy to de-anonymize. I wonder whose phone is at my house 12am-8am everyday, takes more or less the same route through the city, and spends hours in my office everyday. I wonder.
titzer
·9 days ago·discuss
This just makes reviewers and authors lazier.

The purpose of code review is multi-faceted. Hard to maintain? Yes. Might have bugs? Yes. Can be done simpler/cleaner? Yes. Is in line with project code style? Yes. Get someone else to also understand the code? Yes. Onboard junior team member? Yes. Sanity check design decisions? Yes.

This flippant note is mostly more self-justification for being a lazy code reviewer.
titzer
·9 days ago·discuss
It's even worse when Google believes they have a legally defensible justification that your data has been "anonymized". E.g. "anonymized" location data directly from your phone that just so happens to be accurate to the meter. Such data just cannot be anonymized.
titzer
·9 days ago·discuss
Or buying some crappy app off the app store, from which they take a cut.
titzer
·9 days ago·discuss
By analogy, would complaining about any organization ridiculously more powerful than you (e.g. a government) without having a complete alternative ready to go also be "childish"?
titzer
·11 days ago·discuss
People are going to come out of the woodwork to argue about OO specifically, and I'd probably join in, but the higher-level view that I've come to over the years is that one programming paradigm is not the best in all situations. It really helps to work on a lot of different systems that are not all in the same class and look at a lot of code written by people of all skill levels. It's not possible to really talk about all programs, but I will say that the OO way of thinking can very easily be overdone and end up a giant mess. Similarly, the FP way of thinking can also be very easily be overdone and end up a giant mess. The old-style procedural programming (C with a pile of global variables) can easily be overdone and end up a giant mess. Yet all three of those can actually work out great at the right scale on the right problem!

I think the problem is that we can't really architect a program well until after it works and fulfills all of its design requirements. Those are usually in flux and then we have to engineer dimensions of extensibility to prevent committing to the wrong architecture in the beginning. Those extra dimensions of extensibility come at some cost too, as they often mean indirection and cognitive overhead.

We often don't write the same program twice, or even three times, unless it's a really important program or a we just like doing it. Contrast to other fields, e.g. building houses, where we have lots and lots of examples of how to do it and they started to form archetypes. We try to call those design patterns in programming, but they're actually pretty vague and low-level. Can you imagine going to build a house and thinking "yeah, I think I need to use the wood-and-nails design pattern here, and I think I'll do rafters-and-shingles there, with some brick-and-mortar there." Yeah, real specific ideas on how to do it.
titzer
·14 days ago·discuss
I have a fantasy of an alternate history where we as a society got our shit together and subsidized local libraries and ISPs so that they could offer cheap and even free NAS for everyone. Economies of scale and all that. It would have been a worthwhile public investment, but it's hard to justify spending public money on that and our politicians are so blinkered that cannot comprehend what "investment" means. Like...making it easier for kids to get smart? Why would we want that?

Instead we have the private marketplace fulfill all those needs for the low low price of ad infestation. Imagine how smart our kids would be if instead of 20 minutes of unsolicited ads a day, they saw 20 minutes of educational content and were required to pass a math quiz to access YouTube?
titzer
·14 days ago·discuss
I have a large collection of DVDs that I've amassed over the years.

There's something nice about physical media; the bits are physically stamped into the medium. They're DVD-encrypted but I lawfully extract these bits and view them regularly.

When streaming services start on-the-fly editing for content[1] and revoking licenses, they can absolutely shove it up their butts. My old man take is that if a TV show or movie or whatever isn't worth putting onto a physical medium and distributing it to people who will buy it, I won't miss it if--I mean when[2]--it's gone. I mean, these huge movie studios act like pirates are going to ruin their massive profits, when they won't.

[1] And yes, they will absolutely on-the-fly, 1984-style edit films and TV shows for content.

[2] And it will go [https://en.wikipedia.org/wiki/Digital_dark_age] along with lots of other things into the memory hole of the digital dark age.
titzer
·16 days ago·discuss
I don't see any data for anything past 2019.
titzer
·17 days ago·discuss
Second greatest.
titzer
·17 days ago·discuss
Well don't accept code from anyone ever then.

But seriously, if your format requires extensibility to the point that it embeds a bytecode, especially a Turing-complete bytecode, what format are you going to choose? Just design a new one? That's how you end up with a scripting engine with three ROP exploits.
titzer
·17 days ago·discuss
But Wasm has deterministic execution, so if decode fails for you, it should have failed for them. I.e. it's not a problem that your system has introduced; they should be able to reproduce the failure independent of any client.
titzer
·17 days ago·discuss
Many can, even if they have JITs, e.g. Wasmtime. Failing that, it's not that hard to add bytecode instrumentation that will count instructions and terminate early. Some execution platforms that utilize Wasm just inject bytecode instrumentation into guest programs before sending them to the Wasm engine. It's relatively easy to do and not that much overhead.
titzer
·17 days ago·discuss
And many of them have built-in gas metering, so you can time out the decode if it runs too many instructions.
titzer
·17 days ago·discuss
That exploit targeted an integer overflow in a bespoke Apple sandboxing mechanism. Bespoke sandboxing mechanisms have weird bugs.

Not that Wasm engines don't have bugs, but the whole point is to have an extremely solid, well-specified and efficient implementation of a widely accepted bytecode format. We can scope down the capabilities given to any program to a minimal set.