mirror of
https://github.com/Alex313031/thorium.git
synced 2025-01-09 11:27:32 -03:00
cflags updates
This commit is contained in:
parent
ea8b2563bd
commit
b8070ecec8
3 changed files with 16 additions and 9 deletions
|
@ -47,7 +47,7 @@ cd ${CR_SRC_DIR} &&
|
|||
# For restoring individual build targets for customization
|
||||
#autoninja -C out/thorium thorium chromedriver clear_key_cdm thorium_shell policy_templates pack_policy_templates setup mini_installer -j$@ &&
|
||||
autoninja -C out/thorium thorium_all -j$@ &&
|
||||
autoninja -C out/thorium thorium_all setup mini_installer -j$@ &&
|
||||
autoninja -C out/thorium setup mini_installer -j$@ &&
|
||||
|
||||
mv -v -f ${CR_SRC_DIR}/out/thorium/mini_installer.exe ${CR_SRC_DIR}/out/thorium/thorium_mini_installer.exe &&
|
||||
|
||||
|
|
|
@ -33,7 +33,7 @@ declare_args() {
|
|||
# Only applicable to 32 Bit Windows and Linux builds, where
|
||||
# setting it to false allows making an SSE2 build. (`-mmmx -msse2`)
|
||||
# `-msse3`
|
||||
use_sse3 = true
|
||||
use_sse3 = current_cpu == "x86" || current_cpu == "x64"
|
||||
|
||||
# SSE4.1
|
||||
# Normal PrimoBrowser baseline
|
||||
|
@ -89,15 +89,16 @@ declare_args() {
|
|||
use_fma = use_avx2
|
||||
}
|
||||
|
||||
if (current_cpu == "arm" || current_cpu == "arm64") {
|
||||
use_sse3 = false
|
||||
}
|
||||
|
||||
if (is_debug) {
|
||||
assert(!use_polly, "use_polly only works with non-debug builds")
|
||||
assert(!use_bolt, "use_bolt only works with non-debug builds")
|
||||
}
|
||||
|
||||
# Make sure we are a x86 arch
|
||||
if (use_sse3 || use_sse41 || use_sse42 || use_avx || use_avx2 || use_avx512) {
|
||||
assert(current_cpu != "arm" && current_cpu != "arm64", "x86 SIMD intrinsic optimizations cannot be used with ARM targets.")
|
||||
}
|
||||
|
||||
# 32 Bit OSes cant use anything above SSE4.2, and 32 Bit Apps can't benefit
|
||||
# from anything higher usually.
|
||||
if (use_avx || use_avx2 || use_fma) {
|
||||
|
|
|
@ -132,9 +132,13 @@ config("compiler") {
|
|||
cflags += [
|
||||
"-mmmx",
|
||||
"-msse2",
|
||||
"/clang:-O3",
|
||||
"-Xclang", "-O3",
|
||||
]
|
||||
if (is_official_build) {
|
||||
cflags += [
|
||||
"/clang:-O3",
|
||||
"-Xclang", "-O3",
|
||||
]
|
||||
}
|
||||
if (use_sse3) {
|
||||
cflags += [
|
||||
"-msse3",
|
||||
|
@ -235,7 +239,9 @@ config("compiler") {
|
|||
|
||||
# Don't look for libpaths in %LIB%, similar to /X in cflags above.
|
||||
ldflags += [ "/lldignoreenv" ]
|
||||
ldflags += [ "/opt:lldlto=3", ]
|
||||
if (is_official_build) {
|
||||
ldflags += [ "/opt:lldlto=3", ]
|
||||
}
|
||||
}
|
||||
|
||||
# Some binaries create PDBs larger than 4 GiB. Increasing the PDB page size
|
||||
|
|
Loading…
Reference in a new issue