From f7be0e2b7adc4f6c4057f44f789bd7405844701c Mon Sep 17 00:00:00 2001 From: notaz Date: Wed, 22 Feb 2012 01:30:51 +0200 Subject: [PATCH] gpu_unai: update CFLAGS avoid -fPIC if not really needed, no need for a performance hit --- plugins/gpu_unai/Makefile | 2 +- plugins/gpulib/Makefile | 7 +++++-- plugins/gpulib/gpulib.mak | 3 ++- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/plugins/gpu_unai/Makefile b/plugins/gpu_unai/Makefile index dd9e4cad..57a03711 100644 --- a/plugins/gpu_unai/Makefile +++ b/plugins/gpu_unai/Makefile @@ -3,7 +3,7 @@ CC = $(CROSS_COMPILE)g++ ARCH = $(shell $(CC) -v 2>&1 | grep -i 'target:' | awk '{print $$2}' | awk -F '-' '{print $$1}') CFLAGS += -DREARMED -CFLAGS += -ggdb -Wall -fPIC -O2 -ffast-math +CFLAGS += -ggdb -Wall -O3 -ffast-math SRC_STANDALONE += gpu.cpp SRC_GPULIB += gpulib_if.cpp diff --git a/plugins/gpulib/Makefile b/plugins/gpulib/Makefile index a2445244..e65d81b2 100644 --- a/plugins/gpulib/Makefile +++ b/plugins/gpulib/Makefile @@ -4,14 +4,17 @@ AR = $(CROSS_COMPILE)ar ARCH = $(shell $(CC) -v 2>&1 | grep -i 'target:' | awk '{print $$2}' | awk -F '-' '{print $$1}') -CFLAGS += -ggdb -Wall -fPIC -O2 +CFLAGS += -ggdb -Wall +ifndef DEBUG +CFLAGS += -O2 +endif OBJS += gpu.o ifeq "$(ARCH)" "arm" ARM_CORTEXA8 ?= 1 ifeq "$(ARM_CORTEXA8)" "1" -CFLAGS += -mcpu=cortex-a8 -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp +CFLAGS += -mcpu=cortex-a8 -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp -fPIC ASFLAGS += -mcpu=cortex-a8 -mfpu=neon OBJS += cspace_neon.o else diff --git a/plugins/gpulib/gpulib.mak b/plugins/gpulib/gpulib.mak index cec6f5a6..2cc1e28c 100644 --- a/plugins/gpulib/gpulib.mak +++ b/plugins/gpulib/gpulib.mak @@ -5,7 +5,8 @@ LDFLAGS += -shared ifeq "$(ARCH)" "arm" ARM_CORTEXA8 ?= 1 ifeq "$(ARM_CORTEXA8)" "1" - CFLAGS += -mcpu=cortex-a8 -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp + CFLAGS += -mcpu=cortex-a8 -mtune=cortex-a8 -mfpu=neon \ + -fPIC -mfloat-abi=softfp ASFLAGS += -mcpu=cortex-a8 -mfpu=neon else CFLAGS += -mcpu=arm926ej-s -mtune=arm926ej-s -- 2.39.2