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

Make sure fold_const exists wherever fold_ty does #2

Open
varkor opened this issue Feb 25, 2019 · 0 comments
Open

Make sure fold_const exists wherever fold_ty does #2

varkor opened this issue Feb 25, 2019 · 0 comments

Comments

@varkor
Copy link
Owner

varkor commented Feb 25, 2019

We've often missed these out in the past: before finishing, we should check that we haven't missed any. (...and visit_ty, walk_ty, etc.)

varkor pushed a commit that referenced this issue May 24, 2019
…erister

Use arenas to avoid Lrc in queries #2

The `Remove subtle Default impl for Value` makes the compilation stop due earlier due to cycle errors, since there's no longer a default value to continue the compilation with.

Based on rust-lang#59540.
varkor pushed a commit that referenced this issue May 24, 2019
Rollup of 6 pull requests

Successful merges:

 - rust-lang#59545 (Use arenas to avoid Lrc in queries #2)
 - rust-lang#61054 (Suggest dereferencing on assignment to mutable borrow)
 - rust-lang#61056 (tweak discriminant on non-nullary enum diagnostic)
 - rust-lang#61082 (fix dangling reference in Vec::append)
 - rust-lang#61086 (Box::into_unique: do the reborrow-to-raw *after* destroying the Box)
 - rust-lang#61098 (Fix overflowing literal lint in loops)

Failed merges:

r? @ghost
varkor pushed a commit that referenced this issue May 25, 2019
Some review feedback and other misc tweaks
varkor pushed a commit that referenced this issue Jul 22, 2019
Prerequisites from dep graph refactoring #2

Split out from rust-lang#60035 and overlaps with rust-lang#60559.
varkor pushed a commit that referenced this issue Jul 22, 2019
Rollup of 7 pull requests

Successful merges:

 - rust-lang#61665 (core: check for pointer equality when comparing Eq slices)
 - rust-lang#61923 (Prerequisites from dep graph refactoring #2)
 - rust-lang#62270 (Move async-await tests from run-pass to ui)
 - rust-lang#62425 (filedesc: don't use ioctl(FIOCLEX) on Linux)
 - rust-lang#62476 (Continue refactoring macro expansion and resolution)
 - rust-lang#62519 (Regression test for HRTB bug (issue 30786).)
 - rust-lang#62557 (Fix typo in libcore/intrinsics.rs)

Failed merges:

r? @ghost
varkor pushed a commit that referenced this issue Jul 22, 2019
varkor pushed a commit that referenced this issue Sep 15, 2019
Support static and dynamic linking mode for vxWorks in running test suite
varkor pushed a commit that referenced this issue Oct 14, 2019
Add `Instance::resolve_for_fn_ptr` (RFC 2091 #2/N)

Supercedes: rust-lang#65082
Depends on: rust-lang#65037
Tracking issue: rust-lang#47809
[RFC text](https://github.com/rust-lang/rfcs/blob/master/text/2091-inline-semantic.md)

steps taken:

* [x] add a `ReifyShim` that is similar to `VirtualShim` in behavior (see rust-lang#54183)
* [x] add `ty::Instance::resolve_for_fn_ptr` (leave `ty::Instance::resolve_vtable` alone), migrate appropriate callers
* [x] `resolve_for_fn_ptr` returns the shim if calling a `#[track_caller]` function
varkor pushed a commit that referenced this issue Oct 7, 2020
This is a combination of 18 commits.

Commit #2:

Additional examples and some small improvements.

Commit rust-lang#3:

fixed mir-opt non-mir extensions and spanview title elements

Corrected a fairly recent assumption in runtest.rs that all MIR dump
files end in .mir. (It was appending .mir to the graphviz .dot and
spanview .html file names when generating blessed output files. That
also left outdated files in the baseline alongside the files with the
incorrect names, which I've now removed.)

Updated spanview HTML title elements to match their content, replacing a
hardcoded and incorrect name that was left in accidentally when
originally submitted.

Commit rust-lang#4:

added more test examples

also improved Makefiles with support for non-zero exit status and to
force validation of tests unless a specific test overrides it with a
specific comment.

Commit rust-lang#5:

Fixed rare issues after testing on real-world crate

Commit rust-lang#6:

Addressed PR feedback, and removed temporary -Zexperimental-coverage

-Zinstrument-coverage once again supports the latest capabilities of
LLVM instrprof coverage instrumentation.

Also fixed a bug in spanview.

Commit rust-lang#7:

Fix closure handling, add tests for closures and inner items

And cleaned up other tests for consistency, and to make it more clear
where spans start/end by breaking up lines.

Commit rust-lang#8:

renamed "typical" test results "expected"

Now that the `llvm-cov show` tests are improved to normally expect
matching actuals, and to allow individual tests to override that
expectation.

Commit rust-lang#9:

test coverage of inline generic struct function

Commit rust-lang#10:

Addressed review feedback

* Removed unnecessary Unreachable filter.
* Replaced a match wildcard with remining variants.
* Added more comments to help clarify the role of successors() in the
CFG traversal

Commit rust-lang#11:

refactoring based on feedback

* refactored `fn coverage_spans()`.
* changed the way I expand an empty coverage span to improve performance
* fixed a typo that I had accidently left in, in visit.rs

Commit rust-lang#12:

Optimized use of SourceMap and SourceFile

Commit rust-lang#13:

Fixed a regression, and synched with upstream

Some generated test file names changed due to some new change upstream.

Commit rust-lang#14:

Stripping out crate disambiguators from demangled names

These can vary depending on the test platform.

Commit rust-lang#15:

Ignore llvm-cov show diff on test with generics, expand IO error message

Tests with generics produce llvm-cov show results with demangled names
that can include an unstable "crate disambiguator" (hex value). The
value changes when run in the Rust CI Windows environment. I added a sed
filter to strip them out (in a prior commit), but sed also appears to
fail in the same environment. Until I can figure out a workaround, I'm
just going to ignore this specific test result. I added a FIXME to
follow up later, but it's not that critical.

I also saw an error with Windows GNU, but the IO error did not
specify a path for the directory or file that triggered the error. I
updated the error messages to provide more info for next, time but also
noticed some other tests with similar steps did not fail. Looks
spurious.

Commit rust-lang#16:

Modify rust-demangler to strip disambiguators by default

Commit rust-lang#17:

Remove std::process::exit from coverage tests

Due to Issue rust-lang#77553, programs that call std::process::exit() do not
generate coverage results on Windows MSVC.

Commit rust-lang#18:

fix: test file paths exceeding Windows max path len
varkor pushed a commit that referenced this issue Dec 30, 2020
```
Benchmark #1: ./raytracer_cg_clif_pre
  Time (mean ± σ):      9.553 s ±  0.129 s    [User: 9.543 s, System: 0.008 s]
  Range (min … max):    9.438 s …  9.837 s    10 runs

Benchmark #2: ./raytracer_cg_clif_post
  Time (mean ± σ):      9.463 s ±  0.055 s    [User: 9.452 s, System: 0.008 s]
  Range (min … max):    9.387 s …  9.518 s    10 runs

Summary
  './raytracer_cg_clif_post' ran
    1.01 ± 0.01 times faster than './raytracer_cg_clif_pre'
```
varkor pushed a commit that referenced this issue Dec 30, 2020
Don't run `resolve_vars_if_possible` in `normalize_erasing_regions`

Neither `@eddyb` nor I could figure out what this was for. I changed it to `assert_eq!(normalized_value, infcx.resolve_vars_if_possible(&normalized_value));` and it passed the UI test suite.

<details><summary>

Outdated, I figured out the issue - `needs_infer()` needs to come _after_ erasing the lifetimes

</summary>

Strangely, if I change it to `assert!(!normalized_value.needs_infer())` it panics almost immediately:

```
query stack during panic:
#0 [normalize_generic_arg_after_erasing_regions] normalizing `<str::IsWhitespace as str::pattern::Pattern>::Searcher`
#1 [needs_drop_raw] computing whether `str::iter::Split<str::IsWhitespace>` needs drop
#2 [mir_built] building MIR for `str::<impl str>::split_whitespace`
rust-lang#3 [unsafety_check_result] unsafety-checking `str::<impl str>::split_whitespace`
rust-lang#4 [mir_const] processing MIR for `str::<impl str>::split_whitespace`
rust-lang#5 [mir_promoted] processing `str::<impl str>::split_whitespace`
rust-lang#6 [mir_borrowck] borrow-checking `str::<impl str>::split_whitespace`
rust-lang#7 [analysis] running analysis passes on this crate
end of query stack
```

I'm not entirely sure what's going on - maybe the two disagree?

</details>

For context, this came up while reviewing rust-lang#77467 (cc `@lcnr).`

Possibly this needs a crater run?

r? `@nikomatsakis`
cc `@matthewjasper`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant