blob: 1dee2d6e3a5df056598103457490b831e217133d [file] [log] [blame]
Michal Simek21d62e62007-03-27 00:32:16 +02001#
Michal Simek766eeb52016-05-24 11:42:26 +02002# (C) Copyright 2007 - 2016 Michal Simek
Michal Simek21d62e62007-03-27 00:32:16 +02003#
Michal Simek766eeb52016-05-24 11:42:26 +02004# Michal SIMEK <monstr@monstr.eu>
Michal Simek21d62e62007-03-27 00:32:16 +02005#
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02006# SPDX-License-Identifier: GPL-2.0+
Michal Simek952d5142007-03-11 13:42:58 +01007#
Michal Simek766eeb52016-05-24 11:42:26 +02008
Michal Simek4af17742016-05-24 13:23:59 +02009CPU_VER := $(shell echo $(CONFIG_XILINX_MICROBLAZE0_HW_VER))
10
Michal Simek766eeb52016-05-24 11:42:26 +020011# USE_HW_MUL can be 0, 1, or 2, defining a hierarchy of HW Mul support.
12CPUFLAGS-$(subst 1,,$(CONFIG_XILINX_MICROBLAZE0_USE_HW_MUL)) += -mxl-multiply-high
13CPUFLAGS-$(CONFIG_XILINX_MICROBLAZE0_USE_HW_MUL) += -mno-xl-soft-mul
14CPUFLAGS-$(CONFIG_XILINX_MICROBLAZE0_USE_DIV) += -mno-xl-soft-div
15CPUFLAGS-$(CONFIG_XILINX_MICROBLAZE0_USE_BARREL) += -mxl-barrel-shift
16CPUFLAGS-$(CONFIG_XILINX_MICROBLAZE0_USE_PCMP_INSTR) += -mxl-pattern-compare
Michal Simek952d5142007-03-11 13:42:58 +010017
Michal Simek4af17742016-05-24 13:23:59 +020018CPUFLAGS-1 += $(call cc-option,-mcpu=v$(CPU_VER))
19
Michal Simek766eeb52016-05-24 11:42:26 +020020PLATFORM_CPPFLAGS += $(CPUFLAGS-1) $(CPUFLAGS-2)