Merge pull request #3904 from martin-frbg/issue3901

Don't add -tp for the nvc compiler if there is one already in CFLAGS
This commit is contained in:
Martin Kroeker 2023-02-09 18:06:50 +01:00 committed by GitHub
commit 2158dc64a3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 0 deletions

View File

@ -968,16 +968,19 @@ endif
endif endif
ifdef BINARY64 ifdef BINARY64
ifeq ($(ARCH), x86_64) ifeq ($(ARCH), x86_64)
ifeq (,$(findstring tp,$(CFLAGS)))
ifneq ($(NEWPGI2),1) ifneq ($(NEWPGI2),1)
CCOMMON_OPT += -tp p7-64 CCOMMON_OPT += -tp p7-64
else else
CCOMMON_OPT += -tp px CCOMMON_OPT += -tp px
endif endif
endif
ifneq ($(NEWPGI),1) ifneq ($(NEWPGI),1)
CCOMMON_OPT += -D__MMX__ -Mnollvm CCOMMON_OPT += -D__MMX__ -Mnollvm
endif endif
else else
ifeq ($(ARCH), power) ifeq ($(ARCH), power)
ifeq (,$(findstring tp,$(CFLAGS)))
ifeq ($(CORE), POWER8) ifeq ($(CORE), POWER8)
CCOMMON_OPT += -tp pwr8 CCOMMON_OPT += -tp pwr8
endif endif
@ -986,14 +989,17 @@ CCOMMON_OPT += -tp pwr9
endif endif
endif endif
endif endif
endif
else else
ifneq ($(NEWPGI2),1) ifneq ($(NEWPGI2),1)
ifeq (,$(findstring tp,$(CFLAGS)))
CCOMMON_OPT += -tp p7 CCOMMON_OPT += -tp p7
else else
CCOMMON_OPT += -tp px CCOMMON_OPT += -tp px
endif endif
endif endif
endif endif
endif
ifeq ($(C_COMPILER), PATHSCALE) ifeq ($(C_COMPILER), PATHSCALE)
ifdef BINARY64 ifdef BINARY64