Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
hajile
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
34 ms
·
481.
▲
by
hajile
2y ago
> It's explicitly allowed by the language. This is like arguing that a null exception is fine because it's allowed by the language. If you get `undefined` when you expect another type, most future interaction are guaranteed to
482.
▲
by
hajile
2y ago
My balance point is StandardML. SML and TS both have structural typing (I believe this is why people find TS to be more ergonomic). SML has an actually sound type system (I believe there is an unsoundness related to assigning a function to
483.
▲
by
hajile
2y ago
Turning on EVERY safety feature won't mitigate the unsoundness because the problem goes beyond stuff like `any`.
484.
▲
by
hajile
2y ago
Ocaml types are USED by the compiler to generate FAST code. TS types are IGNORED by the JIT to generate SLOW code. All the features that make Typescript more ergonomic for devs also allow it to generate slower JS code. AssemblyScript tries
485.
▲
by
hajile
2y ago
Even haskell will generate a runtime error for an out-of-bounds index main = putStrLn (["a", "b", "c"]!!4)
486.
▲
by
hajile
2y ago
I think this is not a very good example. Not only does it also throw in TS, but it even throws in Haskell which is pretty much the poster boy for sound type systems. This isn't a type error unless your type system is also encoding leng
487.
▲
by
hajile
2y ago
Unsound types are never a problem until they are at which point you are staring at code that SHOULD be working, but is somehow breaking.
488.
▲
by
hajile
2y ago
JS JITs use something called an inline cache (IC) to speed up the lookup of object shapes. JS JITs consider it to be a different shape if the keys are different (even if just one is added or removed), if the values of the same key are diffe
489.
▲
by
hajile
2y ago
If there's a bad way to write JS, TS has something available to make sure it's typed. Does TS help you keep your functions monomorphic so they'll get optimized by the JIT? nope Does TS keep your object shape from changing so
490.
▲
by
hajile
2y ago
ReScript was an outgrowth of ReasonML and basically split the community killing both of them.
491.
▲
by
hajile
2y ago
TS is an intentionally unsound type system that tries to allow you to type your code no matter if it will run like garbage, is unreadably complex, and uses terrible parts of the language. What TC39 needs is a type system that limits what yo
492.
▲
by
hajile
2y ago
If JS ever adds type checking, I hope it doesn't choose Typescript. We need a type system that is actually sound and TS is intentionally unsound. We need a type system that doesn't allow bad coding practices like TS does. We need
493.
▲
by
hajile
2y ago
Flow tries to be sound and that makes it infinitely better than TS where the creators openly threw the idea of soundness out the window from the very beginning.
494.
▲
by
hajile
2y ago
I ask about FizzBuzz in coding interviews because (to my shock and horror), something like 90% of the applicants I've been handed to interview can't think through how to do it.
495.
▲
by
hajile
2y ago
My last "1 hour" test took me hours to complete. I asked them to implement it in front of me in an hour and they couldn't. Programmers are terrible at estimating and programmers will choose tasks that are obvious to them beca
496.
▲
by
hajile
2y ago
Where can I find FMA4 in modern AMD CPUs? What about 3dNow? XOP? Even SSE isn't guaranteed as Intel chips never implemented SSE4a. AVX-512 is especially weird. Cannon lake implemented VBMI, but not Cooper or Cascade Lake only for it to
497.
▲
by
hajile
2y ago
And L1 I-cache size has what seem to be very hard limits due to complexity and latency.
498.
▲
by
hajile
2y ago
Maintaining separation of concerns is the complete opposite of a CISC-style approach. If you are implementing garbage collection or OOP in hardware, you are bound to conflate things in weird ways just like this becomes unavoidable in softwa
499.
▲
by
hajile
2y ago
You are conflating complex with niche. RISC embraces niche while avoiding complex. iAPX432 has examples of complex with stuff like OOP, garbage collection, and even data structures baked into the ISA. These instructions are very complex and
500.
▲
by
hajile
2y ago
Imagine how much money and risk could be averted if a ton of companies came together to work on open core designs. We could fully commoditize the CPU market and lower costs across the board just like Linux did for server OSes or Android did
501.
▲
by
hajile
2y ago
RISC-V will ALWAYS be more simple than x86 because the core of the ISA isn't a disaster. Around 90% of all x86 instructions are just 12 major instructions. x86 gets those instructions very wrong while RISC-V gets them very right. This
502.
▲
by
hajile
2y ago
I simply refuse to play “free“ games. I’ll pay outright or not play at all.
503.
▲
by
hajile
2y ago
Which “one instruction” is the right one? You can have the exact same instruction represented many different ways in x86. Some are shorter and some are longer (and some are different, but the same length). When you say to add two numbers, w
504.
▲
by
hajile
2y ago
Jim Keller is confident that Ascalon will have performance close to zen5 when it is finished later this year. Chips in hand could be some than a lot of people seen to think.
505.
▲
by
hajile
2y ago
The first 4 minute mile was revolutionary. It’s not ordinary today, but isn’t super surprising either. Apple bet big that we hasn’t hit the limits of how wide a machine can go. They created ARM64 to push this idea as it tries to eliminate t
506.
▲
by
hajile
2y ago
Because clockspeed ramps power exponentially, there’s a limit to how high you can clock before the cost of racing outweighs the savings of running a short time. I believe I’ve read that Apple’s chips run under 3GHz unless their job runs lon
507.
▲
by
hajile
2y ago
An ordinary developer cannot write performant x86 without a massive optimizing compiler. Actual instruction encoding is horrible. If you’re arguing that you can write a high-level assembly over the top, then you aren’t so much writing assem
508.
▲
by
hajile
2y ago
x86 has a parity flag. It only takes the parity of the lowest 8 bits though. Why is it there? Because it was in the 8086 because it was in the 8080 because it was in the 8008 because Intel was trying to win a contract for the Datapoint 2200
509.
▲
by
hajile
2y ago
> I blame Intel for why so many folks avoid assembly language. x86 (the worst assembly of any of the top 50 most popular ISAs by a massive margin) and tricky MIPS branch delay slots trivia questions at university have done more to turn o
510.
▲
by
hajile
2y ago
I can imagine Qualcomm being quite interested in working with Framework on a Snapdragon X Elite design. I'd be interested in a Linux version of that laptop (especially given that all the current X Elite machines are completely locked d
More ›