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 another bug in circular type detection #41516

Merged
merged 2 commits into from
Jul 13, 2021
Merged

fix another bug in circular type detection #41516

merged 2 commits into from
Jul 13, 2021

Conversation

vtjnash
Copy link
Member

@vtjnash vtjnash commented Jul 8, 2021

Similar to #35275, but through a supertype instead of through the parameters
Fixes #41503
Fixes #41349

Similar to #35275, but through a supertype instead of through the parameters
Fixes #41503
Fixes #41349
@vtjnash vtjnash added types and dispatch Types, subtyping and method dispatch bugfix This change fixes an existing bug backport 1.7 labels Jul 8, 2021
@vtjnash vtjnash requested a review from JeffBezanson July 8, 2021 18:58
src/builtins.c Outdated Show resolved Hide resolved
src/builtins.c Outdated Show resolved Hide resolved
src/builtins.c Outdated
// If a supertype can reference the same type, then we may not be
// able to compute the layout of the object before needing to
// publish it, so we must assume it cannot be inlined, if that
// check passes, then we also still need to check the object
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
// check passes, then we also still need to check the object
// check passes, then we also still need to check the fields too.

@JeffBezanson
Copy link
Member

Replaces #41359 ?

@Sacha0
Copy link
Member

Sacha0 commented Jul 8, 2021

Regarding #41503, we hit what appears to be that issue while testing 1.7-beta3. Carrying this patch regrettably does not seem to resolve the presentation that we hit, though reverting 7ffc10b does. Hope that's helpful :).

@Sacha0
Copy link
Member

Sacha0 commented Jul 9, 2021

(Please find a stacktrace in #41503 (comment).)

src/builtins.c Outdated Show resolved Hide resolved
Co-authored-by: Jeff Bezanson <jeff.bezanson@gmail.com>
@vtjnash vtjnash added the merge me PR is reviewed. Merge when all tests are passing label Jul 13, 2021
@DilumAluthge DilumAluthge merged commit 1c92e0d into master Jul 13, 2021
@DilumAluthge DilumAluthge deleted the jn/41503 branch July 13, 2021 21:45
@DilumAluthge DilumAluthge removed the merge me PR is reviewed. Merge when all tests are passing label Jul 13, 2021
@JeffBezanson
Copy link
Member

@Sacha0 can you provide an example of a case that still fails with this PR?

@Sacha0
Copy link
Member

Sacha0 commented Jul 15, 2021

@JeffBezanson I will try to reduce the issue enough to pass something useful along tomorrow. Would an rr trace do the trick, absent an MRE? :)

@antoine-levitt
Copy link
Contributor

The issue in #41532 is not fixed by this patch for me (tested in nightly). Reproducer is adding and testing DFTK.

KristofferC pushed a commit that referenced this pull request Jul 19, 2021
Co-authored-by: Jeff Bezanson <jeff.bezanson@gmail.com>
(cherry picked from commit 1c92e0d)
KristofferC pushed a commit that referenced this pull request Jul 20, 2021
Co-authored-by: Jeff Bezanson <jeff.bezanson@gmail.com>
(cherry picked from commit 1c92e0d)
@JeffBezanson
Copy link
Member

Would an rr trace do the trick, absent an MRE? :)

An rr trace is as good as gold, as always :)

@antoine-levitt
Copy link
Contributor

When running under --bug-report=rr I got a segfault ending with

┌ Error: Debugged process failed
│   exitcode = 0
│   termsignal = 11
└ @ BugReporting ~/.julia/packages/BugReporting/AZD4C/src/BugReporting.jl:191
Segmentation fault (core dumped)

with no prompt to upload a trace. There's 420M worth of files in a folder in .julia/artifacts/, should I upload that somewhere? But really Pkg.add("DFTK"); Pkg.test("DFTK") reproduces the bug reliably and so should be easier to debug than rr.

@Sacha0
Copy link
Member

Sacha0 commented Jul 24, 2021

Apologies for not noting the following in this thread earlier: We shipped an rr trace to relevant folks out-of-band, from which they were able to produce an MRE, so there may be no need for more at the moment :).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix This change fixes an existing bug types and dispatch Types, subtyping and method dispatch
Projects
None yet
7 participants