From dbe7dee4542faff3d747c5465633cbe454399fde Mon Sep 17 00:00:00 2001 From: Thomas Roehl Date: Wed, 16 Jun 2021 11:19:23 -0400 Subject: [PATCH] Add Fujitsu compiler to build system --- Makefile | 11 +++++++++++ bench/Makefile | 3 +++ ext/hwloc/Makefile | 5 ++++- make/include_FCC.mk | 34 ++++++++++++++++++++++++++++++++++ 4 files changed, 52 insertions(+), 1 deletion(-) create mode 100644 make/include_FCC.mk diff --git a/Makefile b/Makefile index 61ad18c53..930aabd8e 100644 --- a/Makefile +++ b/Makefile @@ -96,6 +96,17 @@ OBJ := $(filter-out $(BUILD_DIR)/access_x86_clientmem.o,$(OBJ)) else OBJ := $(filter-out $(BUILD_DIR)/loadDataARM.o,$(OBJ)) endif +ifeq ($(COMPILER), FCC) +OBJ := $(filter-out $(BUILD_DIR)/topology_cpuid.o,$(OBJ)) +OBJ := $(filter-out $(BUILD_DIR)/loadData.o,$(OBJ)) +OBJ := $(filter-out $(BUILD_DIR)/access_x86.o,$(OBJ)) +OBJ := $(filter-out $(BUILD_DIR)/access_x86_msr.o,$(OBJ)) +OBJ := $(filter-out $(BUILD_DIR)/access_x86_pci.o,$(OBJ)) +OBJ := $(filter-out $(BUILD_DIR)/access_x86_rdpmc.o,$(OBJ)) +OBJ := $(filter-out $(BUILD_DIR)/access_x86_clientmem.o,$(OBJ)) +else +OBJ := $(filter-out $(BUILD_DIR)/loadDataARM.o,$(OBJ)) +endif ifeq ($(COMPILER), ARMCLANG) OBJ := $(filter-out $(BUILD_DIR)/topology_cpuid.o,$(OBJ)) OBJ := $(filter-out $(BUILD_DIR)/loadData.o,$(OBJ)) diff --git a/bench/Makefile b/bench/Makefile index 201a3c72b..59e4948e9 100644 --- a/bench/Makefile +++ b/bench/Makefile @@ -66,6 +66,9 @@ endif ifeq ($(COMPILER),ARMCLANG) BENCH_DIR = ./armv8 endif +ifeq ($(COMPILER),FCC) +BENCH_DIR = ./armv8 +endif ifeq ($(COMPILER),GCCPOWER) BENCH_DIR = ./power endif diff --git a/ext/hwloc/Makefile b/ext/hwloc/Makefile index 3f90b4827..9ee1f1f36 100644 --- a/ext/hwloc/Makefile +++ b/ext/hwloc/Makefile @@ -8,7 +8,7 @@ include $(MAKE_DIR)/include_$(COMPILER).mk include $(MAKE_DIR)/config_checks.mk include $(MAKE_DIR)/config_defines.mk -CFLAGS = -O2 -Wall -fPIC -fvisibility=hidden +CFLAGS = -O2 -fPIC -fvisibility=hidden INCLUDES += -I./include #DEFINES = LIBS = -L. -lm @@ -42,6 +42,9 @@ endif ifeq ($(strip $(COMPILER)), ARMCLANG) OBJ := $(filter-out $(BUILD_DIR)/topology-x86.o, $(OBJ)) endif +ifeq ($(strip $(COMPILER)), FCC) +OBJ := $(filter-out $(BUILD_DIR)/topology-x86.o, $(OBJ)) +endif ifeq ($(COMPILER),GCCPOWER) OBJ := $(filter-out $(BUILD_DIR)/topology-x86.o,$(OBJ)) endif diff --git a/make/include_FCC.mk b/make/include_FCC.mk new file mode 100644 index 000000000..c1c36a72f --- /dev/null +++ b/make/include_FCC.mk @@ -0,0 +1,34 @@ +CC = fcc +FC = frt +AS = as +AR = ar +PAS = ./perl/AsmGen.pl +GEN_PAS = ./perl/generatePas.pl +GEN_GROUPS = ./perl/generateGroups.pl +GEN_PMHEADER = ./perl/gen_events.pl + +ANSI_CFLAGS = +#ANSI_CFLAGS += -pedantic +#ANSI_CFLAGS += -Wextra +#ANSI_CFLAGS += -Wall + +CFLAGS = -O2 -std=c99 -fPIC +FCFLAGS = -module ./ # ifort +#FCFLAGS = -J ./ -fsyntax-only #gfortran +PASFLAGS = ARMv8 +ASFLAGS = +CPPFLAGS = +LFLAGS = -pthread + +SHARED_CFLAGS = -fPIC -fvisibility=hidden +SHARED_LFLAGS = -shared -fvisibility=hidden + +DEFINES = -DPAGE_ALIGNMENT=4096 +DEFINES += -DLIKWID_MONITOR_LOCK +DEFINES += -DDEBUGLEV=0 +DEFINES += -D__ARM_ARCH_8A + +INCLUDES = +LIBS = -lm -lrt + +