Skip to content

Change MUMPS to allow it to build with clang+xlf compiler combination#8388

Merged
scheibelp merged 6 commits intospack:developfrom
serbanmaerean:fix-ibm-clang/mumps
Aug 2, 2018
Merged

Change MUMPS to allow it to build with clang+xlf compiler combination#8388
scheibelp merged 6 commits intospack:developfrom
serbanmaerean:fix-ibm-clang/mumps

Conversation

@djfitzgerald
Copy link
Copy Markdown
Contributor

The mumps package was unable to build using the llvm clang compiler suite, as it defaulted to using mpif90 for linking and mpif90 cannot be used for linking shared library code. This PR modifies the MUMPS package.py to allow it to use IBM XL Fortran for linking. It also eliminates the need for the existing MUMPS IBM XL patches by having package.py` specify a the compiler-dependent "shared" flag to the linker, and always using the compiler suite's Fortran compiler for linking.

# working only for intel and gnu compilers this is
# perhaps something the compiler should provide
['OPTF = %s -O -DALLOW_NON_INIT %s' % (fpic, '-fdefault-integer-8' if self.compiler.name == "gcc" else '-i8'), # noqa
'OPTL = %s -O ' % fpic,
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

So you changed from -O to -O3 here?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes. As we have been using -O3 for the XL compiler suite, it felt appropriate to use -O3 for llvm Fortran when its being compiled by xlf.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

But I meant OPTL and OPTC that are now outside of the if-xl-else branch.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@davydden Thats an oversight. I'll push an update.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

is this fixed?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

is this fixed?

i think so, there opt_level variable that is used.

Copy link
Copy Markdown
Contributor Author

@djfitzgerald djfitzgerald Jun 15, 2018

Choose a reason for hiding this comment

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

@tgamblin Yes, what @davydden said

@djfitzgerald
Copy link
Copy Markdown
Contributor Author

@adamjstewart @alalazo -- would either of you be willing to merge this PR?

@djfitzgerald
Copy link
Copy Markdown
Contributor Author

Fixed the flake8 errors I was getting

@djfitzgerald
Copy link
Copy Markdown
Contributor Author

@tgamblin Would you be willing to merge this?

@scheibelp scheibelp merged commit e554add into spack:develop Aug 2, 2018
tgamblin added a commit that referenced this pull request Aug 5, 2018
@djfitzgerald djfitzgerald deleted the fix-ibm-clang/mumps branch September 4, 2018 14:22
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.

5 participants