[petsc-users] Modifying built files for use with Japan's K computer

Matthew Knepley knepley at gmail.com
Sun Apr 24 13:52:35 CDT 2016


On Sun, Apr 24, 2016 at 10:12 AM, Wee-beng TAY <zonexo at gmail.com> wrote:

> Hi Matt,
>
> I have attached the page which explains what to modify to use PETSc with
> the K computer.
>
These changes are now in knepley/feature-configure-kcomputer, so you

  cd $PETSC_DIR
  git fetch
  git checkout knepley/feature-configure-kcomputer
  <follow configure instructions from your email>

  Thanks,

    Matt


> Thanks
>
>
>
> On 24/4/2016 10:52 PM, Matthew Knepley wrote:
>
> On Sun, Apr 24, 2016 at 4:14 AM, Wee-beng TAY <zonexo at gmail.com> wrote:
>
>> Hi,
>>
>> I was recently given access to Japan's K computer. I'm trying to compile
>> PETSc on their sys, which uses Fujitsu's compiler. There's a help file but
>> it's in Japanese. I guess I need to change some options to make PETSc
>> compile with Fujitsu's compiler.
>>
> It looks like they want us to include some different options for the
> build. If you send what you want,
> I will make a branch for you to try out.
>
>   Thanks,
>
>      Matt
>
>> Part of the help is below. So how should I use the diff or some other
>> command to do the correction? I tried to run:
>>
>>  diff -u petsc-3.6.4/config/BuildSystem/config/package.py.org
>> petsc-3.6.4/config/BuildSystem/config/package.py
>>
>> but got the err:
>>
>> diff: petsc-3.6.4/config/BuildSystem/config/package.py.org: No such file
>> or directory
>>
>> Please advice. Thanks.
>>
>>
>> *$ diff -u petsc-**3.6**.**3**/config/BuildSystem/config/**package**.py.org
>> <http://py.org> petsc-**3.6**.**3**/config/BuildSystem/config/**package*
>> *.py*
>> *--- petsc-**3.6**.**3**/config/BuildSystem/config/**package**.py.org
>> <http://py.org>        **2015**-**12**-**04* *14**:**06**:**42.000000000*
>>  *+**0900*
>> *+++ petsc-**3.6**.**3**/config/BuildSystem/config/**package**.py    *
>> *2016**-**01**-**22* *11**:**09**:**37.000000000* *+**0900*
>> *@@ -**174**,**7* *+**174**,**7* *@@*
>>      *return* *''*
>>
>>    *def getSharedFlag(self,cflags):*
>> *-    **for* *flag in [**'-PIC'**, **'-fPIC'**, **'-KPIC'**, **'-qpic'*
>> *]:*
>> *+    **for* *flag in [**'-KPIC'**, **'-fPIC'**, **'-PIC'**, **'-qpic'*
>> *]:*
>>        *if* *cflags.find(flag) >=**0**: **return* *flag*
>>      *return* *''*
>>
>> *$ diff -u petsc-**3.6**.**3**/config/BuildSystem/config/setCompilers.py.org
>> <http://setCompilers.py.org> petsc-**3.6**.**3*
>> */config/BuildSystem/config/setCompilers.py*
>> *--- petsc-**3.6**.**3**/config/BuildSystem/config/setCompilers.py.org
>> <http://setCompilers.py.org>   **2015**-**07**-**23* *00**:**22**:*
>> *46.000000000* *+**0900*
>> *+++ petsc-**3.6**.**3*
>> */config/BuildSystem/config/setCompilers.py       **2016**-**01**-**22*
>> *11**:**10**:**05.000000000* *+**0900*
>> *@@ -**1017**,**7* *+**1017**,**7* *@@*
>>        *self.pushLanguage(language)*
>>        *#different compilers are sensitive to the order of testing these
>> flags. So separete out GCC test.*
>>        *if* *config.setCompilers.Configure.isGNU(self.getCompiler()):
>> testFlags = [**'-fPIC'**]*
>> *-      **else**: testFlags = [**'-PIC'**, **'-fPIC'**, **'-KPIC'**,*
>> *'-qpic'**]*
>> *+      **else**: testFlags = [**'-KPIC'**, **'-fPIC'**, **'-PIC'**,*
>> *'-qpic'**]*
>>        *for* *testFlag in testFlags:*
>>          *try**:*
>>            *self.logPrint(**'Trying '**+language+**' compiler flag '*
>> *+testFlag)*
>> *$ diff -u petsc-**3.6**.**3**/config/BuildSystem/config/packages/openmp.py.org
>> <http://openmp.py.org> petsc-**3.6**.**3*
>> */config/BuildSystem/config/packages/openmp.py*
>> *--- petsc-**3.6**.**3**/config/BuildSystem/config/packages/openmp.py.org
>> <http://openmp.py.org>        **2016**-**01**-**25* *15**:**42**:*
>> *23.000000000**+**0900*
>> *+++ petsc-**3.6**.**3*
>> */config/BuildSystem/config/packages/openmp.py    **2016**-**01**-**22*
>> *17**:**13**:**52.000000000* *+**0900*
>> *@@ -**19**,**7* *+**19**,**8* *@@*
>>      *self.found = **0*
>>      *self.setCompilers.pushLanguage(**'C'**)*
>>      *#*
>> *-    **for* *flag in [**"-fopenmp"**, # Gnu*
>> *+    **for* *flag in [**"-Kopenmp"**, # Fujitsu*
>> *+                 **"-fopenmp"**, # Gnu*
>>                   *"-qsmp=omp"**,# IBM XL C/C++*
>>                   *"-h omp"**,   # Cray. Must come after XL because XL
>> interprets **this* *option as meaning**"-soname omp"*
>>                   *"-mp"**,      # Portland Group*
>>
>> *$ diff -u ./petsc-**3.6**.**3**/config/BuildSystem/config/compilers.py.org
>> <http://compilers.py.org> ./petsc-**3.6**.**3*
>> */config/BuildSystem/config/compilers.py*
>> *--- ./petsc-**3.6**.**3**/config/BuildSystem/config/compilers.py.org
>> <http://compilers.py.org>    **2015**-**06**-**10* *06**:**24**:*
>> *49.000000000* *+**0900*
>> *+++ ./petsc-**3.6**.**3*
>> */config/BuildSystem/config/compilers.py        **2016**-**02**-**19*
>> *11**:**56**:**12.000000000* *+**0900*
>> *@@ -**164**,**7* *+**164**,**7* *@@*
>>    *def checkCLibraries(self):*
>>      *''**'Determines the libraries needed to link with C'**''*
>>      *oldFlags = self.setCompilers.LDFLAGS*
>> *-    self.setCompilers.LDFLAGS += **' -v'*
>> *+    self.setCompilers.LDFLAGS += **' -###'*
>>      *self.pushLanguage(**'C'**)*
>>      *(output, returnCode) = self.outputLink(**''**, **''**)*
>>      *self.setCompilers.LDFLAGS = oldFlags*
>> *@@ -**413**,**7* *+**413**,**7* *@@*
>>    *def checkCxxLibraries(self):*
>>      *''**'Determines the libraries needed to link with C++'**''*
>>      *oldFlags = self.setCompilers.LDFLAGS*
>> *-    self.setCompilers.LDFLAGS += **' -v'*
>> *+    self.setCompilers.LDFLAGS += **' -###'*
>>      *self.pushLanguage(**'Cxx'**)*
>>      *(output, returnCode) = self.outputLink(**''**, **''**)*
>>      *self.setCompilers.LDFLAGS = oldFlags*
>>
>>
>>
>>
>>
>>
>>
>
>
> --
> What most experimenters take for granted before they begin their
> experiments is infinitely more interesting than any results to which their
> experiments lead.
> -- Norbert Wiener
>
>
>


-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20160424/5470303a/attachment.html>


More information about the petsc-users mailing list