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

Big Endian CI #7685

Closed
dbaileychess opened this issue Dec 1, 2022 · 7 comments
Closed

Big Endian CI #7685

dbaileychess opened this issue Dec 1, 2022 · 7 comments
Labels
CI Continuous Integration

Comments

@dbaileychess
Copy link
Collaborator

We should have at least one CI build that uses big endian to test that things don't break in that environment. We usually get external reports (e.g. #7671) when things break.

@dbaileychess dbaileychess added the CI Continuous Integration label Dec 1, 2022
@dbaileychess
Copy link
Collaborator Author

Wow, twitter actually being useful. This tweet: https://twitter.com/simonw/status/1552703072500977664?lang=en lead me to https://til.simonwillison.net/docker/emulate-s390x-with-qemu

@sunwen18 Do you want to look into trying this out with out CI?

@dbaileychess
Copy link
Collaborator Author

@musicinmybrain FYI

@musicinmybrain
Copy link
Contributor

@musicinmybrain FYI

The Fedora tooling makes it pretty easy do to a local RPM package build for a different architecture using emulation as long as you have qemu-user-static installed:

$ fedpkg --release rawhide mockbuild --root fedora-rawhide-s390x

It’s not fast, by any means, but it works nicely. I do find that occasionally the results of the emulation don’t exactly match those from the real s390x builders, but I don’t have any good examples of this.

In this case, I can build flatbuffers successfully and reproduce #7671 in emulation, which suggests this could be a usable approach for your CI as well.

@sunwen18
Copy link
Contributor

sunwen18 commented Dec 2, 2022

Wow, twitter actually being useful. This tweet: https://twitter.com/simonw/status/1552703072500977664?lang=en lead me to https://til.simonwillison.net/docker/emulate-s390x-with-qemu

@sunwen18 Do you want to look into trying this out with out CI?

Sure, this seems pretty intuitive.

@sunwen18
Copy link
Contributor

So I created a job that can build a ubuntu on s390x architecture in #7707. But one problem with my current set up is that the job takes around 30 minutes. I think it is because everything is running in a docker container. This is really slowing down the CI. So I'm not quite sure about this job.

@musicinmybrain
Copy link
Contributor

I don’t know how long your CI normally takes, but there is a lot of overhead to emulating a different CPU architecture. Expect emulating s390x on x86_64 to take roughly 5–10× as long as running on real hardware.

On my x86_64 machine, a mock-build of the flatbuffers package in Fedora Linux (including installing dependencies, compiling, running the tests, and producing RPMs) takes (real 1m19s / user 5m47s / sys 0m22s). When I emulate s390x it takes (real 9m3s / user 53m20s / sys 0m47s).

@sunwen18
Copy link
Contributor

PR #7707 already merged, I think we can close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI Continuous Integration
Projects
None yet
Development

No branches or pull requests

3 participants