-
Notifications
You must be signed in to change notification settings - Fork 12.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use FnSig
instead of raw FnDecl
for ForeignItemKind::Fn
, fix ICE for Fn
trait error on safe foreign fn
#128792
Conversation
The only thing I'm concerned about here is the increased size of hir nodes -- but it may not matter since we're arena allocating things anyways. @bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
Use `FnSig` instead of raw `FnDecl` for `ForeignItemKind::Fn`, fix ICE for `Fn` trait error on safe foreign fn Let's use `hir::FnSig` instead of `hir::FnDecl + hir::Safety` for `ForeignItemKind::Fn`. This consolidates some handling code between normal fns and foreign fns. Separetly, fix an ICE where we weren't handling `Fn` trait errors for safe foreign fns. If perf is bad for the first commit, I can rework the ICE fix to not rely on it. But if perf is good, I prefer we fix and clean up things all at once 👍 r? spastorino Fixes rust-lang#128764
This comment has been minimized.
This comment has been minimized.
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
Use `FnSig` instead of raw `FnDecl` for `ForeignItemKind::Fn`, fix ICE for `Fn` trait error on safe foreign fn Let's use `hir::FnSig` instead of `hir::FnDecl + hir::Safety` for `ForeignItemKind::Fn`. This consolidates some handling code between normal fns and foreign fns. Separetly, fix an ICE where we weren't handling `Fn` trait errors for safe foreign fns. If perf is bad for the first commit, I can rework the ICE fix to not rely on it. But if perf is good, I prefer we fix and clean up things all at once 👍 r? spastorino Fixes rust-lang#128764
reviewed r=me if perf is good. |
This comment has been minimized.
This comment has been minimized.
☀️ Try build successful - checks-actions |
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (9d52643): comparison URL. Overall result: no relevant changes - no action neededBenchmarking 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. @bors rollup=never Instruction countThis benchmark run did not return any relevant results for this metric. Max RSS (memory usage)Results (secondary 2.8%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResults (secondary -1.3%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 760.558s -> 760.505s (-0.01%) |
180b795
to
2be5599
Compare
@bors r=spastorino |
…orino Use `FnSig` instead of raw `FnDecl` for `ForeignItemKind::Fn`, fix ICE for `Fn` trait error on safe foreign fn Let's use `hir::FnSig` instead of `hir::FnDecl + hir::Safety` for `ForeignItemKind::Fn`. This consolidates some handling code between normal fns and foreign fns. Separetly, fix an ICE where we weren't handling `Fn` trait errors for safe foreign fns. If perf is bad for the first commit, I can rework the ICE fix to not rely on it. But if perf is good, I prefer we fix and clean up things all at once 👍 r? spastorino Fixes rust-lang#128764
This comment has been minimized.
This comment has been minimized.
💔 Test failed - checks-actions |
…orino Use `FnSig` instead of raw `FnDecl` for `ForeignItemKind::Fn`, fix ICE for `Fn` trait error on safe foreign fn Let's use `hir::FnSig` instead of `hir::FnDecl + hir::Safety` for `ForeignItemKind::Fn`. This consolidates some handling code between normal fns and foreign fns. Separetly, fix an ICE where we weren't handling `Fn` trait errors for safe foreign fns. If perf is bad for the first commit, I can rework the ICE fix to not rely on it. But if perf is good, I prefer we fix and clean up things all at once 👍 r? spastorino Fixes rust-lang#128764
This comment has been minimized.
This comment has been minimized.
💔 Test failed - checks-actions |
@bors retry |
…orino Use `FnSig` instead of raw `FnDecl` for `ForeignItemKind::Fn`, fix ICE for `Fn` trait error on safe foreign fn Let's use `hir::FnSig` instead of `hir::FnDecl + hir::Safety` for `ForeignItemKind::Fn`. This consolidates some handling code between normal fns and foreign fns. Separetly, fix an ICE where we weren't handling `Fn` trait errors for safe foreign fns. If perf is bad for the first commit, I can rework the ICE fix to not rely on it. But if perf is good, I prefer we fix and clean up things all at once 👍 r? spastorino Fixes rust-lang#128764
This comment has been minimized.
This comment has been minimized.
💔 Test failed - checks-actions |
5635a39
to
84633f4
Compare
@bors r=spastorino |
☀️ Test successful - checks-actions |
Finished benchmarking commit (feeba19): comparison URL. Overall result: ❌✅ regressions and improvements - no action needed@rustbot label: -perf-regression Instruction countThis is a highly reliable metric that was used to determine the overall result at the top of this comment.
Max RSS (memory usage)Results (secondary -3.3%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResults (secondary 2.0%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 750.326s -> 749.471s (-0.11%) |
Let's use
hir::FnSig
instead ofhir::FnDecl + hir::Safety
forForeignItemKind::Fn
. This consolidates some handling code between normal fns and foreign fns.Separetly, fix an ICE where we weren't handling
Fn
trait errors for safe foreign fns.If perf is bad for the first commit, I can rework the ICE fix to not rely on it. But if perf is good, I prefer we fix and clean up things all at once 👍
r? spastorino
Fixes #128764