News for hackers. Stuff that matters.
Re:How to speed up the Rust compiler in August 2023 by amenghra on Friday August 25, 2023 @08:28AM (#37260935)
We could do day-to-day Rust/C++/any compiled language related development with an interpreter/JIT and then compile the code once a PR is ready and the code hits CI/CD or gets deployed. The "instant" runtime doesn't even need to have the exact same behavior -- it can be 99% accurate and still be very useful.
Re:How to speed up the Rust compiler in August 2023 by rewmie on Friday August 25, 2023 @10:23AM (#37262068)
Why would anyone subject himself to that?

All mainstream build systems already support incremental builds, and in some cases it's even possible to leverage compiler cache to further shave down the time it takes to rebuild a project.

Breaking down a monolithic project into submodules is all it takes to shave off a big chunk of time from a build.

Re:How to speed up the Rust compiler in August 2023 by amenghra on Friday August 25, 2023 @11:22AM (#37262727)
Imagine being able to set a breakpoint in a function, change something and ask the debugger to “travel” back in time and pretend the code was always what it’s been changed to. It’s something some languages give you but I’m not sure an incremental compiler is sufficient?

These kinds of few seconds/minutes shaved add up and can impact one’s productivity.

Re:How to speed up the Rust compiler in August 2023 by tomjakubowski on Friday August 25, 2023 @11:50AM (#37263105)
for that kind of thing I would imagine more late binding in the language is helpful

at the level Rust works, late binding is hard to do but I don't think it's impossible. Name mangling and calling conventions are a couple big obstacles.