Skip to content

Patch to support Arm HPC compilers #89

@jlinford

Description

@jlinford
*** kgcompiler.py.orig	2019-02-19 17:33:36.211773842 +0000
--- kgcompiler.py	2019-02-19 17:34:18.051829788 +0000
***************
*** 120,125 ****
--- 120,139 ----
      def get_discard_opts_arg(self):
          return super(IntelFortranCompiler, self).get_discard_opts_arg() + self.discard_opts_arg
  
+ class ArmFortranCompiler(GenericFortranCompiler):
+     compid = 'armflang'
+     compnames = ['armflang']
+     openmp_opt = [ r'-fopenmp' ]
+     fpp = '-cpp'
+ 
+     discard_opts_arg = [ '-J' ]
+ 
+     def get_discard_opts_noarg(self):
+         return super(ArmFortranCompiler, self).get_discard_opts_noarg() + self.discard_opts_noarg
+ 
+     def get_discard_opts_arg(self):
+         return super(ArmFortranCompiler, self).get_discard_opts_arg() + self.discard_opts_arg
+ 
  class GnuFortranCompiler(GenericFortranCompiler):
      compid = 'gfortran'
      compnames = ['gfortran']

Without this you'll get an error similar to:

Error message:
kgutils.UserException: Module, calc_mod, is not found at  
/home/johlin02/workspace/KGen/examples/simple/src/update_mod.F90. Please check  
include paths for searching module files.
Makefile:11: recipe for target 'test' failed

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions