Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-95855: Refactor platform triplet detection code, add detection for MIPS soft float and musl libc#107221

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
erlend-aasland merged 12 commits intopython:mainfromjefferyto:gh-95855
Aug 24, 2023

Conversation

@jefferyto
Copy link
Contributor

@jefferytojefferyto commentedJul 25, 2023
edited by bedevere-bot
Loading

Most of the ideas in this come from#96001 so@tiran deserves the credit. But since the platform triplet detection code in configure.ac has changed since#96001, and because that PR is still in an unfinished state, I thought it would make more sense to reimplement it (as well as split it into commits that explain the major steps).

gpshead and erlend-aasland reacted with thumbs up emojitlaurion reacted with eyes emoji
@erlend-aasland
Copy link
Contributor

Thanks! I liked Christian's initial efforts in#96001; thanks for picking this up.

Instead of the grep exercises; what do you think of theprintf approach taken in the CMake-for-CPython project:https://github.com/python-cmake-buildsystem/python-cmake-buildsystem/blob/master/cmake/platform.c

@jefferyto
Copy link
ContributorAuthor

Instead of the grep exercises; what do you think of theprintf approach taken in the CMake-for-CPython project:https://github.com/python-cmake-buildsystem/python-cmake-buildsystem/blob/master/cmake/platform.c

That would require fully compiling the program (the current approach only requires the preprocessing step) and running it to get the output, which would not be feasible when cross-compiling.

My preference would be something similar toconfig.guess, where we output the triplet with a prefix likePLATFORM_TRIPLET= then grep for the prefix specifically (but withoutevaling the output). Would this be acceptable?

erlend-aasland reacted with thumbs up emoji

@erlend-aasland
Copy link
Contributor

That would require fully compiling the program (the current approach only requires the preprocessing step) and running it to get the output, which would not be feasible when cross-compiling.

That's a good point.

My preference would be something similar toconfig.guess, where we output the triplet with a prefix likePLATFORM_TRIPLET= then grep for the prefix specifically (but withoutevaling the output). Would this be acceptable?

Yeah, I would prefer something like that.

@jefferyto
Copy link
ContributorAuthor

Yeah, I would prefer something like that.

Updated 👍

erlend-aasland reacted with hooray emoji

@erlend-aaslanderlend-aaslandenabled auto-merge (squash)July 27, 2023 21:05
@erlend-aaslanderlend-aasland added the 🔨 test-with-buildbotsTest PR w/ buildbots; report in status section labelJul 27, 2023
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by@erlend-aasland for commit7fb142c 🤖

If you want to schedule another build, you need to add the🔨 test-with-buildbots label again.

@bedevere-botbedevere-bot removed the 🔨 test-with-buildbotsTest PR w/ buildbots; report in status section labelJul 27, 2023
@jefferyto
Copy link
ContributorAuthor

Not sure if the buildbot errors are related to this change?

@erlend-aasland
Copy link
Contributor

Not sure if the buildbot errors are related to this change?

Yeah, unfortunately we'll have to examine each bot. I'll see if I can find time later. Feel free to take a look yourself :)

@jefferyto
Copy link
ContributorAuthor

I have looked at every error log - while the errors do not look related to this change to me, I'm not familiar enough with the tests being run to say for certain.

@jefferyto
Copy link
ContributorAuthor

Is there anything else I can do to help resolve the buildbot errors (perhaps update/rebase the branch)?

@erlend-aasland
Copy link
Contributor

erlend-aasland commentedAug 9, 2023
edited
Loading

I did a fairly quick inspection of the buildbot run. Feel free to go through them as well (or even better a different subset).

Buildbotold tripletnew triplet
AMD64 Arch Linux TraceRefs PRx86_64-linux-gnu x86_64-linux-gnu
AMD64 Debian root PR x86_64-linux-gnux86_64-linux-gnu
AMD64 Fedora Stable Clang Installed PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL7 PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL8 PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Ubuntu Shared PRx86_64-linux-gnux86_64-linux-gnu
ARM Raspbian PRarm-linux-gnueabihfarm-linux-gnueabihf
ARM64 macOS PRaarch64-apple-darwin22.5.0/clangaarch64-apple-darwin22.5.0/clang
PPC64 Fedora PRpowerpc-linux-gnu❌ powerpc64-linux-gnu
PPC64LE Fedora Stable Clang Installed PRpowerpc64le-linux-gnu❌ powerpc-linux-gnu
PPC64LE RHEL7 PRpowerpc64le-linux-gnu❌ powerpc-linux-gnu
PPC64LE RHEL8 PR powerpc64le-linux-gnu❌ powerpc-linux-gnu
aarch64 Debian Clang LTO + PGO PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 Fedora Stable Clang Installed PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 RHEL8 PRaarch64-linux-gnuaarch64-linux-gnu
s390x Debian PRs390x-linux-gnus390x-linux-gnu
s390x Fedora Clang Installed PRs390x-linux-gnus390x-linux-gnu
s390x RHEL7 PRs390x-linux-gnu s390x-linux-gnu
s390x RHEL8 PRs390x-linux-gnus390x-linux-gnu
s390x SLES PRs390x-linux-gnus390x-linux-gnu
wasm32-emscripten browser (dynamic linking, no tests) PRwasm32-emscriptenwasm32-emscripten
wasm32-emscripten node (dynamic linking) PRwasm32-emscriptenwasm32-emscripten
wasm32-emscripten node (pthreads) PRwasm32-emscriptenwasm32-emscripten
wasm32-wasi PRwasm32-wasiwasm32-wasi
x86 Gentoo Installed with X PRi686-pc-linux-gnu❌ i386-linux-gnu
x86 Gentoo Non-Debug with X PRi386-linux-gnui386-linux-gnu
x86-64 macOS PRx86_64-apple-darwin21.6.0/clangx86_64-apple-darwin21.6.0/clang

As you see, there are some changes.

Also, I noticed this configure warning in the Gentoo Non-Debug buildbot (despite it getting thei386-linux-gnu triplet):

configure: WARNING: i686-pc-linux-gnu/gcc is not supported

@jefferyto
Copy link
ContributorAuthor

  • PPC64LE * (was powerpc64le-linux-gnu, now powerpc-linux-gnu)
    This should be fixed
  • PPC64 Fedora PR (was powerpc-linux-gnu, now powerpc64-linux-gnu) (build)
    I think the results are switched (was powerpc64-linux-gnu, now powerpc-linux-gnu) - the change is the same issue as with PPC64LE (and should also be fixed)
  • x86 Gentoo Installed with X PR (was i686-pc-linux-gnu, now i386-linux-gnu) (build)
    I checked several previous builds and they all found i386-linux-gnu as the platform triplet (with i686-pc-linux-gnu as the build/host system type)

@AA-TurnerAA-Turner added the 🔨 test-with-buildbotsTest PR w/ buildbots; report in status section labelAug 11, 2023
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by@AA-Turner for commitcbaf416 🤖

If you want to schedule another build, you need to add the🔨 test-with-buildbots label again.

@bedevere-botbedevere-bot removed the 🔨 test-with-buildbotsTest PR w/ buildbots; report in status section labelAug 11, 2023
@AA-Turner
Copy link
Member

@jefferyto I've kicked off another buildbot run for your latest changes.

A

erlend-aasland reacted with hooray emoji

@jefferyto
Copy link
ContributorAuthor

@AA-Turner thanks!

@erlend-aasland
Copy link
Contributor

Thanks, Adam!@jefferyto, can you do an audit of the buildbot run when it completes? I won't be able to return to this until probably late next week.

@jefferyto
Copy link
ContributorAuthor

Here are all the results:

BuildbotOld tripletNew triplet
AMD64 Arch Linux Asan Debug PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Arch Linux Asan PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Arch Linux Perf PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Arch Linux TraceRefs PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Arch Linux Usan PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Debian PGO PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Debian root PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Fedora Stable Clang Installed PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Fedora Stable Clang PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Fedora Stable LTO + PGO PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Fedora Stable LTO PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Fedora Stable PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Fedora Stable Refleaks PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL7 LTO + PGO PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL7 LTO PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL7 PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL7 Refleaks PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL8 FIPS Only Blake2 Builtin Hash PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL8 LTO + PGO PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL8 LTO PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL8 PRx86_64-linux-gnux86_64-linux-gnu
AMD64 RHEL8 Refleaks PRx86_64-linux-gnux86_64-linux-gnu
AMD64 Ubuntu Shared PRx86_64-linux-gnux86_64-linux-gnu
ARM Raspbian PRarm-linux-gnueabihfarm-linux-gnueabihf
ARM64 macOS PRdarwindarwin
PPC64 Fedora PRpowerpc64-linux-gnupowerpc64-linux-gnu
PPC64LE Fedora Stable Clang Installed PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE Fedora Stable Clang PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE Fedora Stable LTO + PGO PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE Fedora Stable LTO PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE Fedora Stable PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE Fedora Stable Refleaks PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE RHEL7 LTO + PGO PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE RHEL7 LTO PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE RHEL7 PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE RHEL7 Refleaks PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE RHEL8 LTO + PGO PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE RHEL8 LTO PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE RHEL8 PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
PPC64LE RHEL8 Refleaks PRpowerpc64le-linux-gnupowerpc64le-linux-gnu
aarch64 Debian Clang LTO + PGO PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 Fedora Stable Clang Installed PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 Fedora Stable Clang PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 Fedora Stable LTO + PGO PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 Fedora Stable LTO PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 Fedora Stable PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 Fedora Stable Refleaks PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 RHEL8 LTO + PGO PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 RHEL8 LTO PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 RHEL8 PRaarch64-linux-gnuaarch64-linux-gnu
aarch64 RHEL8 Refleaks PRaarch64-linux-gnuaarch64-linux-gnu
s390x Debian PRs390x-linux-gnus390x-linux-gnu
s390x Fedora Clang Installed PRs390x-linux-gnus390x-linux-gnu
s390x Fedora Clang PRs390x-linux-gnus390x-linux-gnu
s390x Fedora LTO + PGO PRs390x-linux-gnus390x-linux-gnu
s390x Fedora LTO PRs390x-linux-gnus390x-linux-gnu
s390x Fedora PRs390x-linux-gnus390x-linux-gnu
s390x Fedora Refleaks PRs390x-linux-gnus390x-linux-gnu
s390x RHEL7 LTO + PGO PRs390x-linux-gnus390x-linux-gnu
s390x RHEL7 LTO PRs390x-linux-gnus390x-linux-gnu
s390x RHEL7 PRs390x-linux-gnus390x-linux-gnu
s390x RHEL7 Refleaks PRs390x-linux-gnus390x-linux-gnu
s390x RHEL8 LTO + PGO PRs390x-linux-gnus390x-linux-gnu
s390x RHEL8 LTO PRs390x-linux-gnus390x-linux-gnu
s390x RHEL8 PRs390x-linux-gnus390x-linux-gnu
s390x RHEL8 Refleaks PRs390x-linux-gnus390x-linux-gnu
s390x SLES PRs390x-linux-gnus390x-linux-gnu
wasm32-emscripten browser (dynamic linking, no tests) PRwasm32-emscriptenwasm32-emscripten
wasm32-emscripten node (dynamic linking) PRwasm32-emscriptenwasm32-emscripten
wasm32-emscripten node (pthreads) PRwasm32-emscriptenwasm32-emscripten
wasm32-wasi PRwasm32-wasiwasm32-wasi
x86 Gentoo Installed with X PRi386-linux-gnui386-linux-gnu
x86 Gentoo Non-Debug with X PRi386-linux-gnui386-linux-gnu
x86-64 macOS PRdarwindarwin

I found no regressions, though I suppose this will need to be independently verified.

erlend-aasland and AlexWaygood reacted with heart emojierlend-aasland and AA-Turner reacted with rocket emoji

@erlend-aasland
Copy link
Contributor

Wow, good job! Thank you so much. I'll try to find time to verify it the coming week.

jefferyto reacted with thumbs up emoji

@jefferyto
Copy link
ContributorAuthor

@erlend-aasland ping 🙏

erlend-aasland reacted with eyes emoji

@erlend-aasland
Copy link
Contributor

@corona10, do you want to have a look?

@erlend-aasland
Copy link
Contributor

@tiran, if you are around; feel free to have a look :)

@corona10
Copy link
Member

Okay I will take a look but please wait until this weekend ;)

erlend-aasland reacted with thumbs up emoji

@erlend-aasland
Copy link
Contributor

Okay I will take a look but please wait until this weekend ;)

Sure, there is no hurry :)

@erlend-aasland
Copy link
Contributor

cc.@indygreg

Copy link
Member

@corona10corona10 left a comment

Choose a reason for hiding this comment

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

LGTM!

erlend-aasland reacted with hooray emoji
@erlend-aaslanderlend-aasland merged commitc163d7f intopython:mainAug 24, 2023
@erlend-aasland
Copy link
Contributor

Thanks@jefferyto, Christian, and Dong-hee!

AA-Turner and jefferyto reacted with hooray emoji

@jefferyto
Copy link
ContributorAuthor

Thanks@erlend-aasland for your help as well!

erlend-aasland reacted with heart emoji

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@corona10corona10corona10 approved these changes

@erlend-aaslanderlend-aaslanderlend-aasland approved these changes

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

5 participants

@jefferyto@erlend-aasland@bedevere-bot@AA-Turner@corona10

[8]ページ先頭

©2009-2025 Movatter.jp