Live data from Hacker News

Retrobootstrapping Rust for some reason

graydon2.dreamwidth.org

21–30 of 54 posts

Re: Retrobootstrapping Rust for some reason

#21
Is there, or could there be, a simple implementation of a compiler for the latest full Rust language (in C, Python, Scheme/Racket, or anything except Rust) that is greatly simplified because, although it accepts the latest full Rust language as input, it assumes the input is correct?

Could this simple non-checking Rust implementation transliterate the real Rust compiler's code, to unchecked C, that is good enough for that minimal-steps, sustainable bootstrapping?

This simple non-checking compiler only has to be able to compile one program, and only under controlled conditions, possibly only on hardware with a ton of memory.

Re: Retrobootstrapping Rust for some reason

#22
post #21

Is there, or could there be, a simple implementation of a compiler for the latest full Rust language (in C, Python, Scheme/Racket, or anything except Rust) that is greatly simplified because , although it accepts the latest full Rust language as input, it assumes the input is correct? Could this simple non-checking Rust implementation transliterate the real Rust compiler's code, to unchecked C, that is good enough fo…

Is mrustc "simple" enough? Its purpose is as you describe, and it can bootstrap rustc to version 1.74.0. https://github.com/thepowersgang/mrustc

Re: Retrobootstrapping Rust for some reason

#23
post #21

Is there, or could there be, a simple implementation of a compiler for the latest full Rust language (in C, Python, Scheme/Racket, or anything except Rust) that is greatly simplified because , although it accepts the latest full Rust language as input, it assumes the input is correct? Could this simple non-checking Rust implementation transliterate the real Rust compiler's code, to unchecked C, that is good enough fo…

[deleted]

Re: Retrobootstrapping Rust for some reason

#24
post #15
post #3

Earlier quoted context omitted.

You're not the only one getting blocked. I emailed dreamwidth about this in the past and they say it's something their upstream network host does and they cannot even fix it if their site users wanted to fix it. They're a somewhat limited and broken host partially repackaging some other company's services. >Dreamwidth Studios Support: I'm sorry about the frustrations you're having. The "semi-randomly selected to solv…

This needs to be a catchy name, but I don't have a good one. CloudFlaritis? CloudFlareup? (CloudFlareDown?) Regardless of whether Cloudflare is the particular infra company, the company who uses them responds to blocked people: "We don't know why some users can't access our Web site, and we don't even know the percentage of users who get blocked, but we're just cargo-culting our jobs here, so sux2bu." The outsourced…

Hmm, "cloudfail" is already in use, and "cloudfuckyou" while descriptive is profane enough that it will cause unnecessary friction with certain people, and "clownflare" is too vague/silly (and is less applicable to other service providers).

So I propose "cloudfart" - just rude enough it can't be casually dismissed, but still tolerable in polite company. "I can't access your website (through the cloudfart |, it's just cloudfarting at me)."

Other names (not all applicable for this exact use): cloudfable, cloudunfair, cloudfalse, cloudfarce, cloudfault, cloudfear, cloudfeeble, cloudfeudalism, cloudflake, cloudfluke, cloudfreeze, cloudfuneral.

Re: Retrobootstrapping Rust for some reason

#25
post #21

Is there, or could there be, a simple implementation of a compiler for the latest full Rust language (in C, Python, Scheme/Racket, or anything except Rust) that is greatly simplified because , although it accepts the latest full Rust language as input, it assumes the input is correct? Could this simple non-checking Rust implementation transliterate the real Rust compiler's code, to unchecked C, that is good enough fo…

Is mrustc "simple" enough? Its purpose is as you describe, and it can bootstrap rustc to version 1.74.0. https://github.com/thepowersgang/mrustc

`mrustc` might be exactly what I wanted. Thank you.

Re: Retrobootstrapping Rust for some reason

#26
post #21

Is there, or could there be, a simple implementation of a compiler for the latest full Rust language (in C, Python, Scheme/Racket, or anything except Rust) that is greatly simplified because , although it accepts the latest full Rust language as input, it assumes the input is correct? Could this simple non-checking Rust implementation transliterate the real Rust compiler's code, to unchecked C, that is good enough fo…

Rust can selfbootstrap by compiling the rust code for the compiler.

Re: Retrobootstrapping Rust for some reason

#27
post #24
post #15

Earlier quoted context omitted.

This needs to be a catchy name, but I don't have a good one. CloudFlaritis? CloudFlareup? (CloudFlareDown?) Regardless of whether Cloudflare is the particular infra company, the company who uses them responds to blocked people: "We don't know why some users can't access our Web site, and we don't even know the percentage of users who get blocked, but we're just cargo-culting our jobs here, so sux2bu." The outsourced…

Hmm, "cloudfail" is already in use, and "cloudfuckyou" while descriptive is profane enough that it will cause unnecessary friction with certain people, and "clownflare" is too vague/silly (and is less applicable to other service providers). So I propose "cloudfart" - just rude enough it can't be casually dismissed, but still tolerable in polite company. "I can't access your website (through the cloudfart |, it's just…

Would be nice if the name punished a perpetrator's brand.

Not just sound like we're taking in stride an unavoidable fact of nature.

Want people to stop saying "ClouldFlareup" (like a social disease)? Stop causing it.

Re: Retrobootstrapping Rust for some reason

#28
post #21

Is there, or could there be, a simple implementation of a compiler for the latest full Rust language (in C, Python, Scheme/Racket, or anything except Rust) that is greatly simplified because , although it accepts the latest full Rust language as input, it assumes the input is correct? Could this simple non-checking Rust implementation transliterate the real Rust compiler's code, to unchecked C, that is good enough fo…

Is mrustc "simple" enough? Its purpose is as you describe, and it can bootstrap rustc to version 1.74.0. https://github.com/thepowersgang/mrustc

No it can't. Not for RISC-V/musl, so I'm sure that must be true for other platforms too.

Re: Retrobootstrapping Rust for some reason

#29

Earlier quoted context omitted.

I think we must have some software in use for which the compiler or the source code just isn’t around anymore. It probably isn’t a massive problem. There’s just a slow trickle of tech we can’t economically reproduce, but we replace it with better stuff. Or, if it was really crucial, it would become worth paying for, right?

I think with advances in AI-assisted decompilation, we may soon end up in the situation where given a binary you can produce realistic-looking source (sane variable and function names, comments even) which compiles to the same binary, even though non-identical to the original source code

Could be, although I don’t think that’ll give them any more HDL to train on (unless they also get access to a whole lot of high end microscopes!)

Re: Retrobootstrapping Rust for some reason

#30

Earlier quoted context omitted.

Is mrustc "simple" enough? Its purpose is as you describe, and it can bootstrap rustc to version 1.74.0. https://github.com/thepowersgang/mrustc

No it can't. Not for RISC-V/musl, so I'm sure that must be true for other platforms too.

So.... It can, just not for a particular target platform? Or am I missing your point?
Post reply on HN