News for hackers. Stuff that matters.
Re:I can't stand using VSCode so I wrote my own by vbezhenar on Sunday April 21, 2024 @12:37PM (#40107082)
The trick is to have language "optimized for compilation" and do not do fancy optimizations.

Java is similar (but overall infrastructure around compiler makes it slow).

Golang also quite fast.

Re:I can't stand using VSCode so I wrote my own by thechao on Sunday April 21, 2024 @05:05PM (#40109242)
I think LLVM missed the boat, on this, by being an early mover. A lot of the optimizations are resource-only analyses; the few that re not are "just" various levels of interpretation. That kind of implies we need a framework to define resource utilization and evaluation at the instruction/machine-code level with a standard API. Having an optimizer for an abstract IR is less useful.

The point being that compilers would then target emitting reasonable machine code at speed, and The Real LLVM would do analysis/transform on the machine code.

Re:I can't stand using VSCode so I wrote my own by cjensen on Sunday April 21, 2024 @09:56PM (#40110863)
The tricks in the 80s were different than today's tricks.

(1) Single-pass compiler. No separate pass to convert to object or executable.

(2) Written in assembler (!). Helps that Pascal has fewer dark corners.

(3) No use of disk. A single file read or write would take 10-20s on a floppy. Instead, it's memory to memory.