This is a BZ to track several backports from the gcc-5-branch. Preliminary list: r253734 - PR82274, libgcc parts r252926 - PR80362, PR68528, PR64516 (fold-const.c parts) r249707 - PR80692 r248662 - PR80129 r248635 - PR77767 r248626 - PR78416 r248623 - PR78378 (minus formatting)
Also r248608.
All related tests passed with gcc-4.8.5-28.el7, except that on aarch64, there were the following FAILs: FAIL: g++.dg/torture/pr68184.C -O2 -flto -flto-partition=none (test for excess errors) UNRESOLVED: g++.dg/torture/pr68184.C -O2 -flto -flto-partition=none compilation failed to produce executable FAIL: g++.dg/torture/pr68184.C -O2 -flto (test for excess errors) UNRESOLVED: g++.dg/torture/pr68184.C -O2 -flto compilation failed to produce executable gcc.sum:FAIL: gcc.dg/torture/pr80362.c -O2 -flto -flto-partition=none (test for excess errors) gcc.sum:UNRESOLVED: gcc.dg/torture/pr80362.c -O2 -flto -flto-partition=none compilation failed to produce executable gcc.sum:FAIL: gcc.dg/torture/pr80362.c -O2 -flto (test for excess errors) gcc.sum:UNRESOLVED: gcc.dg/torture/pr80362.c -O2 -flto compilation failed to produce executable gcc.sum:FAIL: gcc.dg/torture/pr78416.c -O2 -flto -flto-partition=none (test for excess errors) gcc.sum:UNRESOLVED: gcc.dg/torture/pr78416.c -O2 -flto -flto-partition=none compilation failed to produce executable gcc.sum:FAIL: gcc.dg/torture/pr78416.c -O2 -flto (test for excess errors) gcc.sum:UNRESOLVED: gcc.dg/torture/pr78416.c -O2 -flto compilation failed to produce executable gcc.sum:FAIL: gcc.c-torture/execute/pr77767.c compilation, -O2 -flto -flto-partition=none gcc.sum:UNRESOLVED: gcc.c-torture/execute/pr77767.c execution, -O2 -flto -flto-partition=none gcc.sum:FAIL: gcc.c-torture/execute/pr77767.c compilation, -O2 -flto gcc.sum:UNRESOLVED: gcc.c-torture/execute/pr77767.c execution, -O2 -flto gcc.sum:FAIL: gcc.c-torture/execute/pr78378.c compilation, -O2 -flto -flto-partition=none gcc.sum:UNRESOLVED: gcc.c-torture/execute/pr78378.c execution, -O2 -flto -flto-partition=none gcc.sum:FAIL: gcc.c-torture/execute/pr78378.c compilation, -O2 -flto gcc.sum:UNRESOLVED: gcc.c-torture/execute/pr78378.c execution, -O2 -flto g++.sum:FAIL: g++.dg/torture/pr80129.C -O2 -flto -flto-partition=none (test for excess errors) g++.sum:UNRESOLVED: g++.dg/torture/pr80129.C -O2 -flto -flto-partition=none compilation failed to produce executable g++.sum:FAIL: g++.dg/torture/pr80129.C -O2 -flto (test for excess errors) g++.sum:UNRESOLVED: g++.dg/torture/pr80129.C -O2 -flto compilation failed to produce executable All of the above fails look like the following: Executing on host: /mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/obj-aarch64-redhat-linux/gcc/xgcc -B/mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8 .5-20150702/obj-aarch64-redhat-linux/gcc/ /mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/gcc/testsuite/gcc.c-torture/execute/pr78378.c -fno-diagnostics-show-caret -fdiagnostics-color=never -w -O2 -flto -flto-partition=none -lm -o /mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/obj-aarch64-redhat-linux/gcc/testsuite/gcc3/pr78378.x7 (timeout = 300) spawn -ignore SIGHUP /mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/obj-aarch64-redhat-linux/gcc/xgcc -B/mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/obj-aarch64-redhat-linux/gcc/ /mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/gcc/testsuite/gcc.c-torture/execute/pr78378.c -fno-diagnostics-show-caret -fdiagnostics-color=never -w -O2 -flto -flto-partition=none -lm -o /mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/obj-aarch64-redhat-linux/gcc/testsuite/gcc3/pr78378.x7 /usr/bin/ld: /mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/obj-aarch64-redhat-linux/gcc/liblto_plugin.so: error loading plugin: /mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/obj-aarch64-redhat-linux/gcc/liblto_plugin.so: cannot restore segment prot after reloc: Permission denied collect2: error: ld returned 1 exit status compiler exited with status 1 output is: /usr/bin/ld: /mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/obj-aarch64-redhat-linux/gcc/liblto_plugin.so: error loading plugin: /mnt/tests/tools/gcc/Sanity/upstream-suite2/TMP/my_rpmbuild/BUILD/gcc-4.8.5-20150702/obj-aarch64-redhat-linux/gcc/liblto_plugin.so: cannot restore segment prot after reloc: Permission denied collect2: error: ld returned 1 exit status In my opinion they are not a big deal, however pasting it here to not lose it. In case the fails might be a problem, let's file another bug for it. I think we can move this to VERIFIED.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2018:0849