-
Notifications
You must be signed in to change notification settings - Fork 12.4k
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
[flang] Fix build with AVOID_NATIVE_UINT128_T #63712
Comments
It is not clear here whether the failure is a failure to link a compiler together or a failure to link a compiled program. |
I've worked around the failure to link the compiler together (it's fine for me if that needs complier-rt), it's about the failure for linking an absolutely minimal hello world project. |
See the patch in https://reviews.llvm.org/D154660. Does it make progress on this problem for you? |
@llvm/issue-subscribers-flang-runtime |
Thanks a lot for the quick response! I've built this (on top of flang 16), but at runtime, I still get:
IIUC, the patch is still a clear improvement, but maybe it doesn't yet capture all uses of 128bit types? |
Do you have to work with such an old revision? You should see better results with llvm-project/main. |
Haha, it's the last released version. 😅 I get that flang is moving quickly though, so I'm looking forward to 17.0.0rc1. I could build everything for a given commit from main, but it'd be quite a hassle due to the way we need to build things separately (not least because public CI is too puny to do a full build of LLVM+clang+mlir+openmp+flang). Ideally, I was hoping to be raising bugs I found from trying to compile scipy with flang so that they'd have a chance to be tackled in time for 17.0.x, but I guess bug reports based on flang 16 would also not be that useful...? I guess rc1 is only 3 weeks away, so it might make sense to just wait a bit? |
If you know of bugs, please report them. Bug reports aren't getting a lot of attention, but unreported bugs get none. |
It's not a lack of willingness to report bugs. But to report bugs, it's a prerequisite to get flang 16 (or the required subset of LLVM for a given commit) working within our infrastructure - which I've been trying to do for quite a while (see #60730) -, in order to throw it at scipy1 and see what comes of it. Footnotes
|
In anticipation of the impending 17.0.0-rc1 tag, I've prepared our infra and built it consistently for a single commit from main (a4f4d82). When I apply your patch to that and build flang, I still get a missing symbol for a hello-world example:
|
Thanks @klausler for merging https://reviews.llvm.org/D154660! WDYT about backporting this to 17.x? Should not be too invasive I think...? If you agree, could you add it to the milestone? |
Go ahead if you want to. I don't have any time for this. |
Yeah, I can take care of this, except I don't have the rights to add this to the milestone, and the bot will fail without it: |
/cherry-pick 1c35c1a |
Error: Command failed due to missing milestone. |
/cherry-pick 1c35c1a |
/branch llvm/llvm-project-release-prs/issue63712 |
/pull-request llvm/llvm-project-release-prs#691 |
@tru |
In trying to get flang usable in the conda-forge ecosystem (think of it as a cross-platform quasi-distribution; see #60730), One of the main remaining problems is that building and running flang against the MSVC runtime fails with a linkage error for the symbol
__udivti3
, which is in compiler-rt but not the MSVC runtime.Linking to compiler-rt has its own set of problems, though, so I perked up when I stumbled over the following context for
__udivti3
:Even though flang doesn't use libcxx, I followed down this 128-bit rabbit hole a bit, and after some searching I found
AVOID_NATIVE_UINT128_T
. However, even having built flang with that (plus 21bff9c), it still runs into missing__udivti3
when trying to build a hello-world example.I ended up asking if building flang without native 128-bit types considered supported, and got the following response:
Hence this issue. I don't know how hard it would be to set up an extra build bot, but that sounds like something that would be really helpful on platforms without native 128bit types, of which windows is a prime example.
The text was updated successfully, but these errors were encountered: