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
[fortran] Update gfortran disabled test list now that CLASS is lowered #109
base: main
Are you sure you want to change the base?
Conversation
All the TODOs and bugs related to CLASS have been implemented/fixed. Enable newly passing tests and move all other failing tests under existing or new categories. None of these failures are bugs, most are different TODOs, unimplemented runtime checks, or cases where flang will behave differently than gfortran on purpose.
I seem to be getting a segfault when I build
|
Thanks for testing Tarun! I could not reproduce with my build and valgrind is green. There may be some undefined behavior to catch in lowering here.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All passes for me on aarch64. Thanks for this!
Wait for Tarun's approval before merging.
I am building flang with clang 17. Below is a stacktrace from a debug build of flang. I haven't had a chance to look specifically if the
|
Jean, as you suspected |
No problem, thanks for finding the bug. Can you dump |
I use GNU libstdc++. The values of various variables in the code are below. They were printed immediately after they were set.
[edit] Added GNU |
And the value of
|
Thanks for this info @tarunprabhu! I could not reproduce with a static release build with clang 17.0.6 + gcc 13.1.0 libstdc++.... Can you give more details about the exact clang version and libstdc++ you are using? Looking at the info you provided, the issue is that the "_QM__fortran_builtinsT__builtin_c_ptr" was not properly lowered, its field should simply be But I do not get why it is only failing for specific builds, and why your build is passing the rest of the tests while usages of C_PTR are ubiquitous in flang (it is used under the hood in the derived type info every time a derived type is used)... So the undefined behaviour may also be somewhere else. |
I use GNU libstdc++ 12.1.0 and clang 17.0.6. I see the same error on a static release build and a non-static ( Thanks for the pointers, Jean. I'll do some debugging on my end and see if I can narrow things down even further. |
@tarunprabhu, I opened an issue for class_allocate_19.f03 and left it disabled until further investigation, please double check that the updated patch works for you now. |
Thanks Jean, Unfortunately, now I see a segfault in If no one else is running into these issues, I am fine with merging this patch so it's not blocked on me.
|
All still pass for me ( |
All the TODOs and bugs related to CLASS have been implemented/fixed. Enable newly passing tests and move all other failing tests under existing or new categories. None of these failures are bugs, most are different TODOs, unimplemented runtime checks, or cases where flang will behave differently than gfortran on purpose.