Uh oh!
There was an error while loading. Please reload this page.
proc_macro/bridge: remove Closure. - #97045
Conversation
This comment was marked as off-topic.
This comment was marked as off-topic.
rust-highfive
commented
May 14, 2022
(rust-highfive has picked a reviewer for you, use r? to override) |
eddyb
commented
May 14, 2022
@bors try @rust-timer queue |
rust-timer
commented
May 14, 2022
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
bors
commented
May 14, 2022
⌛ Trying commit 9242c12 with merge 27e0a1ccff81e0c702800c4e46627bd584cded41... |
Urgau
commented
May 14, 2022
Perf bot is currently broken until #97044 is merged. See https://rust-lang.zulipchat.com/#narrow/stream/247081-t-compiler.2Fperformance/topic/perfrlo.20broken for additional information. |
bors
commented
May 14, 2022
☀️ Try build successful - checks-actions |
rust-timer
commented
May 14, 2022
Queued 27e0a1ccff81e0c702800c4e46627bd584cded41 with parent 8019fa0, future comparison URL. |
lqd
commented
May 14, 2022
note: only the bootstrap rustc benchmark is currently broken. |
rust-timer
commented
May 14, 2022
Finished benchmarking commit (27e0a1ccff81e0c702800c4e46627bd584cded41): comparison url. Summary:
If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf. Benchmarking this pull request likely means that it is perf-sensitive, so we're automatically marking it as not fit for rolling up. While you can manually mark this PR as fit for rollup, we strongly recommend not doing so since this PR may lead to changes in compiler perf. Next Steps: If you can justify the regressions found in this try perf run, please indicate this with @bors rollup=never Footnotes |
eddyb
commented
May 14, 2022
So maybe the extra TLS isn't feasible after all :/ I might still want to keep some of the refactors (that streamline |
petrochenkov
commented
May 21, 2022
I don't have enough time or interest to figure out how the bridge works and what this PR does. |
wesleywiser
commented
Jun 3, 2022
I see this is marked as a draft PR. @eddyb I'm going to mark this as |
eddyb
commented
Jun 3, 2022
It's a slowdown so I'll just close it. |
(Note: the first commit is from #97041, only based on it so I can build at all locally, will undraft as soon as that lands and is rebased over)
This is mostly a potential step towards bridge internals friendlier wrt process-level or wasm-based isolation.
(Follow-ups would likely involve never passing buffers and instead having more of an
io::{Read,Write}combo)The main change here is the client->server FFI call (the
dispatchfield ofBridge), which no longer passes any data other than theBufferitself - it's now effectively "global" (technically thread-local).While this direction is arguably less Rust-y, the client having a pointer to server data could only work in the same address space anyway (and in practice was always pointing higher up the stack on the same thread), and it's additional representational complexity (if one were, say, trying to construct one of these C ABI
Closures from outside a wasm VM, to pass to code inside the wasm VM).There's still a chance we can't do this, but it's down to performance (IMO at least) now.
cc @petrochenkov@mystor