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

Fix interpreter_exec.jl test #53218

Merged
merged 6 commits into from Feb 10, 2024
Merged

Fix interpreter_exec.jl test #53218

merged 6 commits into from Feb 10, 2024

Conversation

Keno
Copy link
Member

@Keno Keno commented Feb 6, 2024

This test was supposed to check that we correctly handled PhiNodes in uninferred code in both the interpreter and the compiler. However, the compiler path wasn't actually exercised, because the inferred=true part of this forced it to be skipped. Drop that and fix the exposed issues in the compiler where we didn't handle PhiNodes properly.

base/compiler/abstractinterpretation.jl Outdated Show resolved Hide resolved
@vtjnash vtjnash added compiler:inference Type inference backport 1.10 Change should be backported to the 1.10 release labels Feb 6, 2024
test/compiler/interpreter_exec.jl Show resolved Hide resolved
Comment on lines 441 to 445
function find_ssavalue_uses!(e::PhiNode, uses::Vector{BitSet}, line::Int)
values = e.values
for i = 1:length(values)
isassigned(values) || continue
val = values[i]
Copy link
Sponsor Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Implemented a fix for the segmentation fault occurring in test/compiler/ssair.jl.

aviatesk added a commit that referenced this pull request Feb 8, 2024
This commit refines `interpreter_exec.jl` further, on top of #53218.
In detail, by using `Base.Experimental.@compiler_options compile=min`,
it's now possible to mimic the effect of `julia --compile=[min|yes]`.
This commit is leveraging it and includes `interpreter_exec.jl` from
`test/compiler/ssair.jl`, allowing us to get better stack traces and
test summaries.

In addition, I've introduced several tests concerning the `src.inferred`
values and have relocated the tests from #47066 within
`interpreter_exec.jl` to `test/compiler/irpasses.jl`, since it is
related to Julia-level compilation and not to interpreter execution.
aviatesk added a commit that referenced this pull request Feb 8, 2024
This commit refines `interpreter_exec.jl` further, on top of #53218.
In detail, by using `Base.Experimental.@compiler_options compile=min`,
it's now possible to mimic the effect of `julia --compile=[min|yes]`.
This commit is leveraging it and includes `interpreter_exec.jl` from
`test/compiler/ssair.jl`, allowing us to get better stack traces and
test summaries.

In addition, I've introduced several tests concerning the `src.inferred`
values and have relocated the tests from #47066 within
`interpreter_exec.jl` to `test/compiler/irpasses.jl`, since it is
related to Julia-level compilation and not to interpreter execution.
base/compiler/utilities.jl Outdated Show resolved Hide resolved
Keno and others added 4 commits February 9, 2024 09:44
This test was supposed to check that we correctly handled PhiNodes in uninferred
code in both the interpreter and the compiler. However, the compiler path wasn't
actually exercised, because the `inferred=true` part of this forced it to be skipped.
Drop that and fix the exposed issues in the compiler where we didn't handle PhiNodes
properly.
Co-authored-by: Shuhei Kadowaki <40514306+aviatesk@users.noreply.github.com>
aviatesk added a commit that referenced this pull request Feb 9, 2024
This commit refines `interpreter_exec.jl` further, on top of #53218.
In detail, by using `Base.Experimental.@compiler_options compile=min`,
it's now possible to mimic the effect of `julia --compile=[min|yes]`.
This commit is leveraging it and includes `interpreter_exec.jl` from
`test/compiler/ssair.jl`, allowing us to get better stack traces and
test summaries.

In addition, I've introduced several tests concerning the `src.inferred`
values and have relocated the tests from #47066 within
`interpreter_exec.jl` to `test/compiler/irpasses.jl`, since it is
related to Julia-level compilation and not to interpreter execution.
aviatesk and others added 2 commits February 9, 2024 11:02
This commit refines `interpreter_exec.jl` further, on top of #53218. In
detail, by using `Base.Experimental.@compiler_options compile=min`, it's
now possible to mimic the effect of `julia --compile=[min|yes]`. This
commit is leveraging it and includes `interpreter_exec.jl` from
`test/compiler/ssair.jl`, allowing us to get better stack traces and
test summaries.

In addition, I've introduced several tests concerning the `src.inferred`
values and have relocated the tests from #47066 within
`interpreter_exec.jl` to `test/compiler/irpasses.jl`, since it is
related to Julia-level compilation and not to interpreter execution.
@Keno Keno merged commit 35768c2 into master Feb 10, 2024
4 of 7 checks passed
@Keno Keno deleted the kf/interpexectest branch February 10, 2024 17:41
@KristofferC KristofferC mentioned this pull request Feb 20, 2024
19 tasks
KristofferC added a commit that referenced this pull request Feb 27, 2024
Backported PRs:
- [x] #53205 <!-- Profile: add notes to `print()` docs -->
- [x] #53170 <!-- Remove outdated discussion about externally changing
module bindings -->
- [x] #53228 <!-- SubArray: avoid invalid elimination of singleton
indices -->
- [x] #51361 <!-- code_warntype docs: more neutral reference to
@code_warntype -->
- [x] #50480 <!-- Document --heap-size-hint in Command-line Interface
-->
- [x] #53301 <!-- Fix typo in `Sys.total_memory` docstring. -->
- [x] #53354 <!-- fix code coverage bug in tail position and `else` -->
- [x] #53388 <!-- Fix documentation: thread pool of main thread -->
- [x] #53429 <!-- Subtype: skip slow-path in `local_∀_∃_subtype` if
inputs contain no ∃ typevar. -->
- [x] #53437 <!-- Add debug variant of loader_trampolines.o -->

Need manual backport:
- [ ] #52505 <!-- fix alignment of emit_unbox_store copy -->
- [ ] #53373 <!-- fix sysimage-native-code=no option with pkgimages -->
- [ ] #53439 <!-- staticdata: fix assert from partially disabled native
code -->

Contains multiple commits, manual intervention needed:
- [ ] #52913 <!-- Added docstring for Artifacts.jl -->
- [ ] #53218 <!-- Fix interpreter_exec.jl test -->

Non-merged PRs with backport label:
- [ ] #53424 <!-- yet more atomics & cache-line fixes on work-stealing
queue -->
- [ ] #53125 <!-- coverage: count coverage where explicitly requested by
inference only -->
- [ ] #52694 <!-- Reinstate similar for AbstractQ for backward
compatibility -->
- [ ] #51479 <!-- prevent code loading from lookin in the versioned
environment when building Julia -->
@KristofferC KristofferC mentioned this pull request Mar 12, 2024
25 tasks
@KristofferC KristofferC mentioned this pull request May 8, 2024
17 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport 1.10 Change should be backported to the 1.10 release compiler:inference Type inference
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants