Live data from Hacker News

I reduced (incremental) Rust compile times by up to 40%

coderemote.dev

11–15 of 15 posts

Re: I reduced (incremental) Rust compile times by up to 40%

#11
post #6

I think this is unlikely to gain traction. I say that no to discourage you, just to explain. - The community has an instinctive distrust of closed source or a compiler from an untrusted source. If you’re familiar with the Trusting Trust attack you’ll understand why. People won’t send their code to you to compile, because they’re afraid of it being modified. People won’t use a closed source compiler, when an open sour…

I appreciate this detailed explanation! To preface, I took on macro expansion caching because it was a clear solution for the slow builds I saw in some projects (taking the "project-specific" approach I mentioned in the blog). That said, my medium-term vision for CodeRemote isn't to develop a superior closed-source Rust compiler fork; instead, it is to provide remote tooling for faster development (i.e. bring small d…

The Rust bhild config defaults are pretty fine for the general case. It's just that not everyone has the general case :) In Rust the normal distribution will be quite flattened.

Re: I reduced (incremental) Rust compile times by up to 40%

#12

I’m not sending you my code to compile on your machine. I understand wanting to make a successful product, and keepin your secret magic secure, but I’m afraid this just sets off so many alarm bells for me.

Thanks for raising this. I hadn't anticipated this as a major concern. Is your main concern that you can't see the compiler code -- in which case would it help if the the source were available? Or is it even more than that, that you want to ensure that your build outputs are untampered and verifiably produced by a (deterministic) compiler? I wonder though, would you trust remote CI/CD servers or Intel's proprietary C…

Often during early development I don’t want to share my code with others. Obviously a compiler on my machine could make a secret internet connection, but I guess that would be noticed, and certainly couldn’t be later denied.

Can I be at all sure you aren’t keeping a copy of all source you are ever submitted?

Usually I eventually submit to GitHub, then CI occurs, and all is public. However, only getting fast building on CI doesn’t motivate me that much, I don’t care if I burn GitHub/Microsoft’s CPU cycles as much as I mind about my own :)

Re: I reduced (incremental) Rust compile times by up to 40%

#13
post #11

Earlier quoted context omitted.

I appreciate this detailed explanation! To preface, I took on macro expansion caching because it was a clear solution for the slow builds I saw in some projects (taking the "project-specific" approach I mentioned in the blog). That said, my medium-term vision for CodeRemote isn't to develop a superior closed-source Rust compiler fork; instead, it is to provide remote tooling for faster development (i.e. bring small d…

The Rust bhild config defaults are pretty fine for the general case. It's just that not everyone has the general case :) In Rust the normal distribution will be quite flattened.

Ha yes that is a diplomatic way to put it. To the commenter's point though, I too question some of the defaults. mold does seem to be objectively better than the default linker. Stripping debuginfo does seem like it would have been a better default, which is why it was made so recently! Pipelined compilation also falls into this latter category, so perhaps because there is (understandably) just a delay until adoption to stable Rust.

I know you mean it as a figure of speech, but I would consider the complexity (and build time) distribution for Rust to be heavy-tailed and skewed right, more so than a flattened normal.

Re: I reduced (incremental) Rust compile times by up to 40%

#14

Earlier quoted context omitted.

Thanks for raising this. I hadn't anticipated this as a major concern. Is your main concern that you can't see the compiler code -- in which case would it help if the the source were available? Or is it even more than that, that you want to ensure that your build outputs are untampered and verifiably produced by a (deterministic) compiler? I wonder though, would you trust remote CI/CD servers or Intel's proprietary C…

Often during early development I don’t want to share my code with others. Obviously a compiler on my machine could make a secret internet connection, but I guess that would be noticed, and certainly couldn’t be later denied. Can I be at all sure you aren’t keeping a copy of all source you are ever submitted? Usually I eventually submit to GitHub, then CI occurs, and all is public. However, only getting fast building…

Gotcha, I respect that. With a few privacy-minded devs like you, I have offered them a custom compiler toolchain (and happy to make the source available) that they can "self-host". If you are interested in trying it out, I'd be happy to get you set up.

Re: I reduced (incremental) Rust compile times by up to 40%

#15

Earlier quoted context omitted.

Often during early development I don’t want to share my code with others. Obviously a compiler on my machine could make a secret internet connection, but I guess that would be noticed, and certainly couldn’t be later denied. Can I be at all sure you aren’t keeping a copy of all source you are ever submitted? Usually I eventually submit to GitHub, then CI occurs, and all is public. However, only getting fast building…

Gotcha, I respect that. With a few privacy-minded devs like you, I have offered them a custom compiler toolchain (and happy to make the source available) that they can "self-host". If you are interested in trying it out, I'd be happy to get you set up.

Thanks for the offer. I would mention it somewhere on your webpage, just so people (like me) don't get worried. Right now I'm too busy to try a new compiler, but if I find myself with a little more time, and a little longer rust compile times, in the future, I will remember to look you up!
Post reply on HN