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

Generic compilation support #1471

Merged
merged 14 commits into from
Dec 9, 2015
Merged

Conversation

pescobar
Copy link
Member

No description provided.

systemtools.POWER: 'mcpu=native', # no support for march=native on POWER
}
optarch = build_option('optarch')
if optarch == 'GENERIC':
Copy link
Member

Choose a reason for hiding this comment

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

this should be a constant named GENERIC, that you import from easybuild.tools.toolchain.toolchain

@hpcugentbot
Copy link
Contributor

EasyBuild framework unit test suite FAILed.

See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2324/console for more details.

Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do.

@boegel boegel modified the milestone: v2.5.0 Nov 13, 2015
@hpcugentbot
Copy link
Contributor

EasyBuild framework unit test suite FAILed.

See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2335/console for more details.

Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do.

@hpcugentbot
Copy link
Contributor

EasyBuild framework unit test suite FAILed.

See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2336/console for more details.

Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do.

@hpcugentbot
Copy link
Contributor

EasyBuild framework unit test suite FAILed.

See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2337/console for more details.

Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do.

fix --list-toolchains, always include generic flags (regardless of 'optarch' toolchain option)
@boegel
Copy link
Member

boegel commented Nov 19, 2015

Jenkins: test this please

@hpcugentbot
Copy link
Contributor

EasyBuild framework unit test suite PASSed (see https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2355/console for more details).

This pull request is now ready for review/testing.

Please try and find someone who can tackle this; contact @boegel if you're not sure what to do.

@boegel
Copy link
Member

boegel commented Nov 20, 2015

@pescobar: this still needs:

  • enhanced unit test (see test_override_optarch in test/framework/toolchain.py)
  • docs update

@rjeschmi
Copy link
Contributor

Is it worth supporting something in between generic and native?

@pescobar
Copy link
Member Author

pescobar commented Dec 4, 2015

@rjeschmi I tried to build a software stack "in between" to use it as my generic software stack and I got problems.

My specific case was that I was compiling my "generic" software stack in the oldest cpu I had around which was a nehalem. I was building in the nehalem cpu with the default gcc option in easybuild of "-march=native" and I supposed that this would work in any other cpu but I found problems when trying to use this software stack in AMD cpus (magny-cours I think) and also when using it in xenserver virtual machines.

That's why I would suggest to build totally generic. I would focus this feature in portability and not in performance

@pescobar
Copy link
Member Author

pescobar commented Dec 9, 2015

I did some tests and seems to be working for GCC. See this three build logs:

This one is a normal build without using --optarch
https://gist.github.com/61a9a47dc513e5bb4af2

This one is with --optarch=GENERIC and toolchainopts = {'optarch': True}
https://gist.github.com/6e1bf60e5e51a4ace7f5

This one is with --optarch=GENERIC and toolchainopts = {'optarch': False}
https://gist.github.com/e53fec626cae9c75d2ad

If you grep for "march" in those build logs all them seem fine for me.

Opinions @boegel ?

@boegel
Copy link
Member

boegel commented Dec 9, 2015

@pescobar: seems to be working indeed, so go ahead with the docs update

optarch = build_option('optarch', default=None)
if optarch == OPTARCH_GENERIC:
# do generic build if --optarch=GENERIC
COMPILER_OPTIMAL_ARCHITECTURE_OPTION = {
Copy link
Member

Choose a reason for hiding this comment

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

this should be self.COMPILER_OPTIMAL_ARCHITECTURE_OPTION = {

@hpcugentbot
Copy link
Contributor

EasyBuild framework unit test suite PASSed (see https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2407/console for more details).

This pull request is now ready for review/testing.

Please try and find someone who can tackle this; contact @boegel if you're not sure what to do.

@boegel
Copy link
Member

boegel commented Dec 9, 2015

@pescobar: unit test + cleanup in pescobar#16

add unit test for --optarch=GENERIC + clean up way in which --optarch=GENERIC is handled
@hpcugentbot
Copy link
Contributor

EasyBuild framework unit test suite FAILed.

See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2411/console for more details.

Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do.

@hpcugentbot
Copy link
Contributor

EasyBuild framework unit test suite PASSed (see https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2412/console for more details).

This pull request is now ready for review/testing.

Please try and find someone who can tackle this; contact @boegel if you're not sure what to do.

@boegel
Copy link
Member

boegel commented Dec 9, 2015

Going in, thanks @pescobar!

docs update at easybuilders/easybuild#172 will be included soon too

boegel added a commit that referenced this pull request Dec 9, 2015
@boegel boegel merged commit 70c5fcc into easybuilders:develop Dec 9, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants