mirror of
https://github.com/libretro/Lakka.git
synced 2025-03-02 20:56:07 +00:00
config/optimize: add support to en/disable LTO, GOLD, LOOP, GRAPHITE support via project files
Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
parent
94365f1a9e
commit
4f54bf2e18
@ -1,34 +1,45 @@
|
||||
if [ "$OPTIMIZATIONS" = fast ];then
|
||||
GCC_OPTIM="-Ofast"
|
||||
LD_OPTIM=""
|
||||
GCC_OPTIM="$GCC_OPTIM -fexcess-precision=fast"
|
||||
LD_OPTIM="-Wl,--as-needed"
|
||||
fi
|
||||
|
||||
if [ "$OPTIMIZATIONS" = speed ];then
|
||||
GCC_OPTIM="-O3"
|
||||
LD_OPTIM=""
|
||||
GCC_OPTIM="$GCC_OPTIM -O3"
|
||||
GCC_OPTIM="$GCC_OPTIM -fexcess-precision=fast"
|
||||
LD_OPTIM="-Wl,--as-needed"
|
||||
fi
|
||||
|
||||
if [ "$OPTIMIZATIONS" = normal ];then
|
||||
GCC_OPTIM="-O2"
|
||||
GCC_OPTIM="$GCC_OPTIM -O2"
|
||||
LD_OPTIM=""
|
||||
fi
|
||||
|
||||
if [ "$OPTIMIZATIONS" = size ];then
|
||||
GCC_OPTIM="-Os"
|
||||
GCC_OPTIM="$GCC_OPTIM -Os"
|
||||
LD_OPTIM=""
|
||||
fi
|
||||
|
||||
GCC_OPTIM="$GCC_OPTIM -ftree-loop-distribution"
|
||||
GCC_OPTIM="$GCC_OPTIM -floop-interchange"
|
||||
GCC_OPTIM="$GCC_OPTIM -floop-strip-mine"
|
||||
GCC_OPTIM="$GCC_OPTIM -floop-block"
|
||||
GCC_OPTIM="$GCC_OPTIM -fgraphite-identity"
|
||||
GCC_OPTIM="$GCC_OPTIM -fexcess-precision=fast"
|
||||
# GCC_OPTIM="$GCC_OPTIM -flto"
|
||||
if [ "$LOOP_SUPPORT" = yes ];then
|
||||
GCC_OPTIM="$GCC_OPTIM -ftree-loop-distribution"
|
||||
GCC_OPTIM="$GCC_OPTIM -floop-interchange"
|
||||
GCC_OPTIM="$GCC_OPTIM -floop-strip-mine"
|
||||
GCC_OPTIM="$GCC_OPTIM -floop-block"
|
||||
fi
|
||||
|
||||
LD_OPTIM="$LD_OPTIM -fuse-linker-plugin"
|
||||
LD_OPTIM="$LD_OPTIM -fuse-ld=gold"
|
||||
LD_OPTIM="$LD_OPTIM -Wl,--as-needed"
|
||||
if [ "$GRAPHITE_SUPPORT" = yes ];then
|
||||
GCC_OPTIM="$GCC_OPTIM -fgraphite-identity"
|
||||
fi
|
||||
|
||||
if [ "$LTO_SUPPORT" = yes ];then
|
||||
GCC_OPTIM="$GCC_OPTIM -flto"
|
||||
LD_OPTIM="$LD_OPTIM -fuse-linker-plugin"
|
||||
fi
|
||||
|
||||
if [ "$GOLD_SUPPORT" = yes ];then
|
||||
LD_OPTIM="$LD_OPTIM -fuse-linker-plugin"
|
||||
LD_OPTIM="$LD_OPTIM -fuse-ld=gold"
|
||||
fi
|
||||
|
||||
if [ "$DEBUG" = yes ]; then
|
||||
TARGET_CFLAGS="$TARGET_CFLAGS -ggdb"
|
||||
|
@ -77,6 +77,18 @@
|
||||
# Project CFLAGS
|
||||
PROJECT_CFLAGS=""
|
||||
|
||||
# LTO (Link Time Optimazion) support
|
||||
LTO_SUPPORT="no"
|
||||
|
||||
# GOLD (Google Linker) support
|
||||
GOLD_SUPPORT="yes"
|
||||
|
||||
# Graphite Support
|
||||
GRAPHITE_SUPPORT="yes"
|
||||
|
||||
# LOOP optimazion support
|
||||
LOOP_SUPPORT="yes"
|
||||
|
||||
# Bootloader to use (syslinux / u-boot / atv-bootloader)
|
||||
BOOTLOADER="atv-bootloader"
|
||||
|
||||
|
@ -77,6 +77,18 @@
|
||||
# Project CFLAGS
|
||||
PROJECT_CFLAGS="-mfpmath=sse -ftree-vectorize -mmovbe"
|
||||
|
||||
# LTO (Link Time Optimazion) support
|
||||
LTO_SUPPORT="no"
|
||||
|
||||
# GOLD (Google Linker) support
|
||||
GOLD_SUPPORT="yes"
|
||||
|
||||
# Graphite Support
|
||||
GRAPHITE_SUPPORT="yes"
|
||||
|
||||
# LOOP optimazion support
|
||||
LOOP_SUPPORT="yes"
|
||||
|
||||
# Bootloader to use (syslinux / u-boot / atv-bootloader)
|
||||
BOOTLOADER="syslinux"
|
||||
|
||||
|
@ -77,6 +77,18 @@
|
||||
# Project CFLAGS
|
||||
PROJECT_CFLAGS="-mmmx -msse -msse2 -mfpmath=sse"
|
||||
|
||||
# LTO (Link Time Optimazion) support
|
||||
LTO_SUPPORT="no"
|
||||
|
||||
# GOLD (Google Linker) support
|
||||
GOLD_SUPPORT="yes"
|
||||
|
||||
# Graphite Support
|
||||
GRAPHITE_SUPPORT="yes"
|
||||
|
||||
# LOOP optimazion support
|
||||
LOOP_SUPPORT="yes"
|
||||
|
||||
# Bootloader to use (syslinux / u-boot / atv-bootloader)
|
||||
BOOTLOADER="syslinux"
|
||||
|
||||
|
@ -77,6 +77,18 @@
|
||||
# Project CFLAGS
|
||||
PROJECT_CFLAGS="-mfpmath=sse -ftree-vectorize -mmovbe"
|
||||
|
||||
# LTO (Link Time Optimazion) support
|
||||
LTO_SUPPORT="no"
|
||||
|
||||
# GOLD (Google Linker) support
|
||||
GOLD_SUPPORT="yes"
|
||||
|
||||
# Graphite Support
|
||||
GRAPHITE_SUPPORT="yes"
|
||||
|
||||
# LOOP optimazion support
|
||||
LOOP_SUPPORT="yes"
|
||||
|
||||
# Bootloader to use (syslinux / u-boot / atv-bootloader)
|
||||
BOOTLOADER="syslinux"
|
||||
|
||||
|
@ -77,6 +77,18 @@
|
||||
# Project CFLAGS
|
||||
PROJECT_CFLAGS=""
|
||||
|
||||
# LTO (Link Time Optimazion) support
|
||||
LTO_SUPPORT="no"
|
||||
|
||||
# GOLD (Google Linker) support
|
||||
GOLD_SUPPORT="yes"
|
||||
|
||||
# Graphite Support
|
||||
GRAPHITE_SUPPORT="yes"
|
||||
|
||||
# LOOP optimazion support
|
||||
LOOP_SUPPORT="yes"
|
||||
|
||||
# Bootloader to use (syslinux / u-boot / atv-bootloader)
|
||||
BOOTLOADER="syslinux"
|
||||
|
||||
|
@ -77,6 +77,18 @@
|
||||
# Project CFLAGS
|
||||
PROJECT_CFLAGS="-mfpmath=sse -ftree-vectorize -mmovbe"
|
||||
|
||||
# LTO (Link Time Optimazion) support
|
||||
LTO_SUPPORT="no"
|
||||
|
||||
# GOLD (Google Linker) support
|
||||
GOLD_SUPPORT="yes"
|
||||
|
||||
# Graphite Support
|
||||
GRAPHITE_SUPPORT="yes"
|
||||
|
||||
# LOOP optimazion support
|
||||
LOOP_SUPPORT="yes"
|
||||
|
||||
# Bootloader to use (syslinux / u-boot / atv-bootloader)
|
||||
BOOTLOADER="syslinux"
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user