-
Notifications
You must be signed in to change notification settings - Fork 27
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
Support for clang-16 in cppyy #25
Comments
I have a big incentive to get that done soon as modern compilers on all 3 major platforms are now failing with LLVM-13 (mainly b/c C++20 is the chosen default, which now brings in code in standard headers using features that makes 13 choke). I started the work, but then upstream is also close to moving to LLVM-18, so waiting for that instead would save me some time, which is in short supply still. Upstream (https://github.com/compiler-research) also has a fork of cppyy that, once completed, would make future updates to newer versions of LLVM much easier. (Time spent on that is one reason why I haven't kept up here.) |
That's great to hear @wlav! Do you have an idea of the time-frame for clang-16 or 18 backend? I'm trying to decide if its worthwhile to spend time on an alternative method or just wait a little bit longer. Any way contributors can help out? |
Always consider alternatives. :) cppyy fills a rather unique niche: it either fits or it doesn't. As for contributions, do you have access to / care about MS Windows? It's always a major holdup for preparing a release (I run it in a VM on Linux, but MS time limits on the images they provide so I have to redo everything for each new release and our IT security folks don't particularly like it), so if you could test LLVM16 there, that would be very helpful. I've put in the repo what I tested on Linux. Haven't run the CI yet to check Windows, nor updated the version numbers, which makes building from source a bit more complicated. But as-is, it still has six failing tests (on Linux, see below), so I want to get that fixed first before moving on to Mac (and finally Windows).
Alternatively, given that the above errors are all corner cases, building it from source and putting it through the wringer on Linux is helpful, too. Might catch some more, LLVM16 specific, errors before releasing it. |
@wlav, I have a Windows laptop I can test out LLVM16 on. Point me in the right direction (repo/branch and build/test instructions) and I'll give it a go. ETA: Just saw your commit, going to take a look now. |
Actually, I need some help knowing how to build locally for linux, mac, and windows. I have all three. I tried using the circleci recipe but that might not work well for working through errors and rebuilding/testing. |
The CI scripts were contributed; I never got the circleci one to work. The reason for its existence was that github emulates ARM, which is slow, and the jobs run out of time. A Linux ARM wheel has been requested frequently, though, so would have been useful. The CI on github also has other limitations: the Linux one uses the old ABI and the Mac one cross compiles for ARM. The latter can't work b/c the build process creates a few executables that are then to be used in the build. That fails when cross compiling. Intel Mac and Windows on github CI was functional, IIRC. I have CI disabled until I get closer to a release; builds take to long to bother with every little commit. Details on building from source are here: An important one is |
Ok, I'll need to follow these instructions and let you know how it goes. What's the latest commit in which you expect all the unit tests to pass in x86_64 linux? I'm using ubuntu 22.04, do you see any problems with that? Any specific compiler and python versions I should be using? |
Just prior to putting in the LLVM16 patches should work for all tests on Linux except 1 (test01_deque_byvalue_regression). That one fails b/c of a naming conflict between 2 tests (ie., it will work when run independently). Last fully functional commit is c84cc07 Note that there are a handful of tests that fail on Windows (have been for a long time); several esoteric, such as the use of I'm down to 4 failing tests on Linux. |
I'm getting a lot of failed tests on linux. I followed the instructions to build from source using cmake using gcc 13.1, python 3.10, and ubuntu 22.04. I'm not sure why I'm getting so many more failing tests than you. Let me know if there is a known stable combination of dependencies or a docker image I should use.
|
Typically, when a lot of unrelated tests fail, it's something basic with the setup. Can you post the actual errors? |
I'm having a hard time getting them to reproduce consistently. I'm going to build a docker image and script that should reproduce it consistently, then I will share that along with the errors. |
So I created a docker image to ensure the issue reproduced with a fresh install. I followed the instructions on the webpage you linked and created this docker file based on them: Running this image, I get similar failures as before: |
Running them without the |
Without
|
I was super excited to try out cppyy to enable some property based testing for several open source libraries we have at Intel that are highly dependent on template types and compile-time processing. However, our libraries need at least clang 16. I saw that cling has support for this now, when will cppyy be updated with the latest version of cling with clang 16 support?
The text was updated successfully, but these errors were encountered: