Commit 3e88aaf8 by Nicolas Capens

Revert workarounds for ThinLTO linker builds.

Fixing Issue swiftshader:31 makes the workarounds obsolete and since they disabled some link-time optimizations they should be reverted. This reverts commit 628a8496. This reverts commit 158dcfc1. This reverts commit ad675fa1. Bug chromium:686980 Bug chromium:735508 Change-Id: I4c4e2466fdfcddd12854b87e5a62d6ec8c823a05 Reviewed-on: https://swiftshader-review.googlesource.com/10168Reviewed-by: 's avatarNicolas Capens <capn@google.com> Reviewed-by: 's avatarAlexis Hétu <sugoi@google.com> Tested-by: 's avatarNicolas Capens <capn@google.com>
parent 77de547f
...@@ -12,8 +12,6 @@ ...@@ -12,8 +12,6 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
import("//build/toolchain/toolchain.gni")
# Need a separate config to ensure the warnings are added to the end. # Need a separate config to ensure the warnings are added to the end.
config("swiftshader_libEGL_private_config") { config("swiftshader_libEGL_private_config") {
defines = [ "EGL_EGLEXT_PROTOTYPES" ] defines = [ "EGL_EGLEXT_PROTOTYPES" ]
...@@ -82,18 +80,6 @@ shared_library("swiftshader_libEGL") { ...@@ -82,18 +80,6 @@ shared_library("swiftshader_libEGL") {
[ "-Wl,--version-script=" + rebase_path("exports.map", root_build_dir) ] [ "-Wl,--version-script=" + rebase_path("exports.map", root_build_dir) ]
} }
if (use_thin_lto) {
# https://crbug.com/686980
# This target relies on the linker to be smart and garbage collect unused symbols.
# It is not the case for LLD + ThinLTO, so we have to use this ugly workaround.
cflags = [
"-Xclang",
"-fno-lto-unit",
"-fno-whole-program-vtables",
"-fno-sanitize=cfi",
]
}
configs -= [ "//build/config/compiler:chromium_code" ] configs -= [ "//build/config/compiler:chromium_code" ]
configs += [ configs += [
"//build/config/compiler:no_chromium_code", "//build/config/compiler:no_chromium_code",
......
...@@ -12,8 +12,6 @@ ...@@ -12,8 +12,6 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
import("//build/toolchain/toolchain.gni")
# Need a separate config to ensure the warnings are added to the end. # Need a separate config to ensure the warnings are added to the end.
config("swiftshader_libGLESv2_private_config") { config("swiftshader_libGLESv2_private_config") {
defines = [ defines = [
...@@ -100,18 +98,6 @@ shared_library("swiftshader_libGLESv2") { ...@@ -100,18 +98,6 @@ shared_library("swiftshader_libGLESv2") {
[ "-Wl,--version-script=" + rebase_path("exports.map", root_build_dir) ] [ "-Wl,--version-script=" + rebase_path("exports.map", root_build_dir) ]
} }
if (use_thin_lto) {
# https://crbug.com/686980
# This target relies on the linker to be smart and garbage collect unused symbols.
# It is not the case for LLD + ThinLTO, so we have to use this ugly workaround.
cflags = [
"-Xclang",
"-fno-lto-unit",
"-fno-whole-program-vtables",
"-fno-sanitize=cfi",
]
}
configs -= [ "//build/config/compiler:chromium_code" ] configs -= [ "//build/config/compiler:chromium_code" ]
configs += [ configs += [
"//build/config/compiler:no_chromium_code", "//build/config/compiler:no_chromium_code",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment