Skip to content

Commit d4619de

Browse files
committed
compiler: Add ICX support
1 parent 7c897db commit d4619de

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

devito/arch/compiler.py

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -515,6 +515,22 @@ def __lookup_cmds__(self):
515515
self.MPICXX = 'mpicxx'
516516

517517

518+
class ICXCompiler(Compiler):
519+
520+
def __init__(self, *args, **kwargs):
521+
super().__init__(*args, **kwargs)
522+
523+
self.cflags += ['-Ofast', '-xHost', '-fiopenmp']
524+
525+
def __lookup_cmds__(self):
526+
# OneAPI Base Kit comes with dpcpp/icpx, both are clang++,
527+
# and icx, which is clang
528+
self.CC = 'icx'
529+
self.CXX = 'icpx'
530+
self.MPICC = 'mpic++'
531+
self.MPICXX = 'mpicxx'
532+
533+
518534
class PGICompiler(Compiler):
519535

520536
def __init__(self, *args, **kwargs):
@@ -779,6 +795,7 @@ def __lookup_cmds__(self):
779795
'intel': IntelCompiler,
780796
'icpc': IntelCompiler,
781797
'icc': IntelCompiler,
798+
'icx': ICXCompiler,
782799
'intel-knl': IntelKNLCompiler,
783800
'knl': IntelKNLCompiler,
784801
'dpcpp': DPCPPCompiler,

0 commit comments

Comments
 (0)