Skip to content
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

Remove NtVis and NtTy #133436

Merged
merged 3 commits into from
Feb 22, 2025
Merged

Remove NtVis and NtTy #133436

merged 3 commits into from
Feb 22, 2025

Conversation

nnethercote
Copy link
Contributor

@nnethercote nnethercote commented Nov 25, 2024

The next part of #124141. The first actual remove of Nonterminal variants. NtVis is a simple case that doesn't get much use, but NtTy is more complex.

r? @petrochenkov

@rustbot

This comment was marked as outdated.

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Nov 25, 2024
@rustbot rustbot assigned petrochenkov and unassigned fmease Nov 25, 2024
@nnethercote nnethercote changed the title Remove `Ntis nt ty Remove NtVis and NtTy Nov 25, 2024
@nnethercote nnethercote marked this pull request as ready for review November 25, 2024 07:47
@nnethercote
Copy link
Contributor Author

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Nov 26, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 26, 2024
Remove `NtVis` and `NtTy`

The next part of rust-lang#124141. The first actual remove of `Nonterminal` variants. `NtVis` is a simple case that doesn't get much use, but `NtTy` is more complex.

r? `@petrochenkov`
@bors
Copy link
Contributor

bors commented Nov 26, 2024

⌛ Trying commit 5552feb with merge 4286768...

@bors
Copy link
Contributor

bors commented Nov 26, 2024

☀️ Try build successful - checks-actions
Build commit: 4286768 (4286768a03a7e632381c6200a897b91da8f8a50c)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (4286768): comparison URL.

Overall result: ❌✅ regressions and improvements - please read the text below

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 @rustbot label: +perf-regression-triaged along with sufficient written justification. If you cannot justify the regressions please fix the regressions and do another perf run. If the next run shows neutral or positive results, the label will be automatically removed.

@bors rollup=never
@rustbot label: -S-waiting-on-perf +perf-regression

Instruction count

This is the most reliable metric that we have; it was used to determine the overall result at the top of this comment. However, even this metric can sometimes exhibit noise.

mean range count
Regressions ❌
(primary)
0.5% [0.1%, 1.2%] 17
Regressions ❌
(secondary)
0.8% [0.6%, 1.2%] 4
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.2% [-0.3%, -0.2%] 2
All ❌✅ (primary) 0.5% [0.1%, 1.2%] 17

Max RSS (memory usage)

Results (primary 4.8%, secondary -0.1%)

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.

mean range count
Regressions ❌
(primary)
4.8% [4.8%, 4.8%] 1
Regressions ❌
(secondary)
2.3% [2.3%, 2.3%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-2.4% [-2.4%, -2.4%] 1
All ❌✅ (primary) 4.8% [4.8%, 4.8%] 1

Cycles

Results (secondary 2.4%)

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.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
2.4% [1.7%, 3.1%] 4
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 795.777s -> 797.172s (0.18%)
Artifact size: 336.33 MiB -> 336.35 MiB (0.01%)

@rustbot rustbot added perf-regression Performance regression. and removed S-waiting-on-perf Status: Waiting on a perf run to be completed. labels Nov 26, 2024
@nnethercote
Copy link
Contributor Author

I double-checked the perf results with Cachegrind. It's from the extra pasting and reparsing of metavariables, as expected and seen in #124141. Not much to be done about it, though I am looking at other ways to speed up parsing in general.

@rustbot label: +perf-regression-triaged

@rustbot rustbot added the perf-regression-triaged The performance regression has been triaged. label Nov 26, 2024
@nnethercote
Copy link
Contributor Author

I am looking at other ways to speed up parsing in general.

#133793 has significant parsing speed wins.

@nnethercote
Copy link
Contributor Author

@petrochenkov: I rebased. The output for tests/ui/associated-consts/issue-93835 has changed a little. The code in that test is very broken that I guess the compilation aborts before every single problem is found. I guess the problems found are now a little different -- two new ones, and one old one gone.

@petrochenkov petrochenkov added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Feb 20, 2025
We now use invisible delimiters for expanded `vis` fragments, instead of
`Token::Interpolated`.
Notes about tests:

- tests/ui/parser/macro/trait-object-macro-matcher.rs: the syntax error
  is duplicated, because it occurs now when parsing the decl macro
  input, and also when parsing the expanded decl macro. But this won't
  show up for normal users due to error de-duplication.

- tests/ui/associated-consts/issue-93835.rs: similar, plus there are
  some additional errors about this very broken code.

- The changes to metavariable descriptions in rust-lang#132629 are now visible in
  error message for several tests.
@nnethercote
Copy link
Contributor Author

New code is up, addressing all the comments.

@petrochenkov petrochenkov added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Feb 21, 2025
@petrochenkov
Copy link
Contributor

Thanks!
@bors r+

@bors
Copy link
Contributor

bors commented Feb 21, 2025

📌 Commit 0f490b0 has been approved by petrochenkov

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Feb 21, 2025
@bors
Copy link
Contributor

bors commented Feb 22, 2025

⌛ Testing commit 0f490b0 with merge b6d3be4...

@bors
Copy link
Contributor

bors commented Feb 22, 2025

☀️ Test successful - checks-actions
Approved by: petrochenkov
Pushing b6d3be4 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Feb 22, 2025
@bors bors merged commit b6d3be4 into rust-lang:master Feb 22, 2025
7 checks passed
@rustbot rustbot added this to the 1.87.0 milestone Feb 22, 2025
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (b6d3be4): comparison URL.

Overall result: ❌ regressions - please read the text below

Our benchmarks found a performance regression caused by this PR.
This might be an actual regression, but it can also be just noise.

Next Steps:

  • If the regression was expected or you think it can be justified,
    please write a comment with sufficient written justification, and add
    @rustbot label: +perf-regression-triaged to it, to mark the regression as triaged.
  • If you think that you know of a way to resolve the regression, try to create
    a new PR with a fix for the regression.
  • If you do not understand the regression or you think that it is just noise,
    you can ask the @rust-lang/wg-compiler-performance working group for help (members of this group
    were already notified of this PR).

@rustbot label: +perf-regression
cc @rust-lang/wg-compiler-performance

Instruction count

This is the most reliable metric that we have; it was used to determine the overall result at the top of this comment. However, even this metric can sometimes exhibit noise.

mean range count
Regressions ❌
(primary)
0.4% [0.2%, 1.0%] 18
Regressions ❌
(secondary)
0.6% [0.3%, 0.9%] 11
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.4% [0.2%, 1.0%] 18

Max RSS (memory usage)

Results (primary -1.2%)

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.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-1.2% [-1.5%, -1.0%] 3
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -1.2% [-1.5%, -1.0%] 3

Cycles

Results (secondary -7.4%)

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.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-7.4% [-7.4%, -7.4%] 1
All ❌✅ (primary) - - 0

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 771.719s -> 773.139s (0.18%)
Artifact size: 363.15 MiB -> 361.03 MiB (-0.58%)

@nnethercote nnethercote deleted the rm-NtVis-NtTy branch February 24, 2025 02:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. perf-regression Performance regression. perf-regression-triaged The performance regression has been triaged. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants