Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I think you are making more of a distinction between optimizations and runtime, not compilation. Doing compilation is about taking a lot of arbitrary user-input (in the form of urls and cmake files and code edits) and executing that. Then optimization occurs which is a lot of pure transforms. Then runtime occurs, which is when the program takes a lot of user-input again. But step one usually is in a different language than step three, which is extra effort to learn. And step 2 doesn’t really need to visible to users, since it is pure the user doesn’t really need to directly see the side effects from that.


That wasn't my intention if it came out that way.

Compilation is something that happens (generally) once and returns an executable artifact.

Runtime is execution of said artifact, and can happen many times, with many different environment setups.

Compile time functions and types capture stuff that can be known during compilation.


runtime_result = f(static state, dynamic state)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: