softdevteam / ykrustc

Yorick Meta-tracer
Other
6 stars 4 forks source link

Serialize SIR per codegen unit instead of per crate #125

Closed bjorn3 closed 4 years ago

vext01 commented 4 years ago

I've added Lukas as well, as I want to make sure he's OK with this.

vext01 commented 4 years ago

What's the reason behind the second commit?

bjorn3 commented 4 years ago

SIR is something codegen related, so it shouldn't be part of rustc_middle. Before it was necessary as Sir was part of TyCtxt, but it isn't anymore. Combined with the third commit it also makes the diff with upstream of rustc_middle empty.

vext01 commented 4 years ago

OK. I remember having a hell of a time juggling the dependencies when writing that code, so these simplifications are welcomed.

Let me check one thing. What was the crate hash is now a hash derived from the cgu name and the Svh.

The Svh is the same thing as the crate hash, right?

bjorn3 commented 4 years ago

Yes, that is both correct. The crate_hash field should probably be renamed in a future yk PR.

vext01 commented 4 years ago

Yes, that is both correct. The crate_hash field should probably be renamed in a future yk PR.

Yes there's going to need to be a follow up PR checking all uses of the term in our ykrustc changes and in the yk repo too.

How about cgu_hash?

Does the yk repo still work with this change?

@ptersilie what do you think?

bjorn3 commented 4 years ago

Does the yk repo still work with this change?

Yes, I have tested it. No changes to yk are necessary.

ptersilie commented 4 years ago

Looks good to me.

vext01 commented 4 years ago

Please squash.

bjorn3 commented 4 years ago

Splat

vext01 commented 4 years ago

bors r+

bors[bot] commented 4 years ago

Build succeeded: