Commit e69a7ff8 authored by Heiko Carstens's avatar Heiko Carstens
Browse files

s390: allow to compile with z16 optimizations



Add config and compile options which allow to compile with z16
optimizations if the compiler supports it.

Signed-off-by: default avatarHeiko Carstens <hca@linux.ibm.com>
parent 6203ac30
Loading
Loading
Loading
Loading
+19 −0
Original line number Diff line number Diff line
@@ -255,6 +255,10 @@ config HAVE_MARCH_Z15_FEATURES
	def_bool n
	select HAVE_MARCH_Z14_FEATURES

config HAVE_MARCH_Z16_FEATURES
	def_bool n
	select HAVE_MARCH_Z15_FEATURES

choice
	prompt "Processor type"
	default MARCH_Z196
@@ -312,6 +316,14 @@ config MARCH_Z15
	  and 8561 series). The kernel will be slightly faster but will not
	  work on older machines.

config MARCH_Z16
	bool "IBM z16"
	select HAVE_MARCH_Z16_FEATURES
	depends on $(cc-option,-march=z16)
	help
	  Select this to enable optimizations for IBM z16 (3931 and
	  3932 series).

endchoice

config MARCH_Z10_TUNE
@@ -332,6 +344,9 @@ config MARCH_Z14_TUNE
config MARCH_Z15_TUNE
	def_bool TUNE_Z15 || MARCH_Z15 && TUNE_DEFAULT

config MARCH_Z16_TUNE
	def_bool TUNE_Z16 || MARCH_Z16 && TUNE_DEFAULT

choice
	prompt "Tune code generation"
	default TUNE_DEFAULT
@@ -372,6 +387,10 @@ config TUNE_Z15
	bool "IBM z15"
	depends on $(cc-option,-mtune=z15)

config TUNE_Z16
	bool "IBM z16"
	depends on $(cc-option,-mtune=z16)

endchoice

config 64BIT
+2 −0
Original line number Diff line number Diff line
@@ -42,6 +42,7 @@ mflags-$(CONFIG_MARCH_ZEC12) := -march=zEC12
mflags-$(CONFIG_MARCH_Z13)    := -march=z13
mflags-$(CONFIG_MARCH_Z14)    := -march=z14
mflags-$(CONFIG_MARCH_Z15)    := -march=z15
mflags-$(CONFIG_MARCH_Z16)    := -march=z16

export CC_FLAGS_MARCH := $(mflags-y)

@@ -54,6 +55,7 @@ cflags-$(CONFIG_MARCH_ZEC12_TUNE) += -mtune=zEC12
cflags-$(CONFIG_MARCH_Z13_TUNE)		+= -mtune=z13
cflags-$(CONFIG_MARCH_Z14_TUNE)		+= -mtune=z14
cflags-$(CONFIG_MARCH_Z15_TUNE)		+= -mtune=z15
cflags-$(CONFIG_MARCH_Z16_TUNE)		+= -mtune=z16

cflags-y += -Wa,-I$(srctree)/arch/$(ARCH)/include