make[4]: Entering directory '/var/tmp/portage/dev-debug/gdb-14.1-r1/work/gdb-14.1/sim' /bin/sh ./libtool --tag=CC --mode=link x86_64-pc-linux-gnu-gcc -Wall -Wdeclaration-after-statement -Wpointer-arith -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wempty-body -Wunused-but-set-parameter -Wno-error=maybe-uninitialized -Wmissing-declarations -Wmissing-prototypes -Wdeclaration-after-statement -Wmissing-parameter-type -Wpointer-sign -Wold-style-declaration -Wformat-nonliteral -O3 -pipe -march=alderlake -mabm -mno-cldemote -mno-kl -mno-pconfig -mno-sgx -mno-widekl -mshstk --param=l1-cache-line-size=64 --param=l1-cache-size=48 --param=l2-cache-size=30720 -flto -Werror=odr -Werror=lto-type-mismatch -Werror=strict-aliasing -ggdb3 -Wl,-O1 -Wl,--as-needed -o m32r/run m32r/nrun.o m32r/libsim.a ../bfd/libbfd.la ../opcodes/libopcodes.la ../libiberty/libiberty.a ../gnulib/import/libgnu.a -ltinfo -lm libtool: link: x86_64-pc-linux-gnu-gcc -Wall -Wdeclaration-after-statement -Wpointer-arith -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wempty-body -Wunused-but-set-parameter -Wno-error=maybe-uninitialized -Wmissing-declarations -Wmissing-prototypes -Wdeclaration-after-statement -Wmissing-parameter-type -Wpointer-sign -Wold-style-declaration -Wformat-nonliteral -O3 -pipe -march=alderlake -mabm -mno-cldemote -mno-kl -mno-pconfig -mno-sgx -mno-widekl -mshstk --param=l1-cache-line-size=64 --param=l1-cache-size=48 --param=l2-cache-size=30720 -flto -Werror=odr -Werror=lto-type-mismatch -Werror=strict-aliasing -ggdb3 -Wl,-O1 -Wl,--as-needed -o m32r/run m32r/nrun.o m32r/libsim.a ../bfd/.libs/libbfd.a -lz -lzstd ../opcodes/.libs/libopcodes.a ../libiberty/libiberty.a ../gnulib/import/libgnu.a -ltinfo -lm m32r/traps.c:115:43: error: type of 'm32r2f_h_psw_get' does not match original declaration [-Werror=lto-type-mismatch] 115 | m32r2f_h_bpsw_set (current_cpu, m32r2f_h_psw_get (current_cpu)); | ^ m32r/cpu2.c:130:1: note: return value type mismatch 130 | m32r2f_h_psw_get (SIM_CPU *current_cpu) | ^ m32r/cpu2.c:130:1: note: type 'UQI' should match type 'int' m32r/cpu2.c:130:1: note: 'm32r2f_h_psw_get' was previously declared here m32r/traps.c:110:43: error: type of 'm32rxf_h_psw_get' does not match original declaration [-Werror=lto-type-mismatch] 110 | m32rxf_h_bpsw_set (current_cpu, m32rxf_h_psw_get (current_cpu)); | ^ m32r/cpux.c:130:1: note: return value type mismatch 130 | m32rxf_h_psw_get (SIM_CPU *current_cpu) | ^ m32r/cpux.c:130:1: note: type 'UQI' should match type 'int' m32r/cpux.c:130:1: note: 'm32rxf_h_psw_get' was previously declared here m32r/sem2-switch.c:3099:17: error: type of 'm32r2f_h_psw_get_handler' does not match original declaration [-Werror=lto-type-mismatch] 3099 | UQI opval = GET_H_PSW (); | ^ m32r/m32r2.c:153:1: note: return value type mismatch 153 | m32r2f_h_psw_get_handler (SIM_CPU *current_cpu) | ^ m32r/m32r2.c:153:1: note: type 'UQI' should match type 'int' m32r/m32r2.c:153:1: note: 'm32r2f_h_psw_get_handler' was previously declared here m32r/sem2-switch.c:3274:16: error: type of 'm32r2f_h_accum_get_handler' does not match original declaration [-Werror=lto-type-mismatch] 3274 | DI opval = SRADI (SLLDI (SUBDI (GET_H_ACCUM (), SRADI (SLLDI (MULDI (EXTHIDI (TRUNCSIHI (* FLD (i_src1))), EXTHIDI (TRUNCSIHI (* FLD (i_src2)))), 32), 16)), 8), 8); | ^ m32r/m32r2.c:168:1: note: return value type mismatch 168 | m32r2f_h_accum_get_handler (SIM_CPU *current_cpu) | ^ m32r/m32r2.c:168:1: note: type 'DI' should match type 'int' m32r/m32r2.c:168:1: note: 'm32r2f_h_accum_get_handler' was previously declared here m32r/m32r2.c:168:1: note: code may be misoptimized unless '-fno-strict-aliasing' is used m32r/semx-switch.c:2931:17: error: type of 'm32rxf_h_psw_get_handler' does not match original declaration [-Werror=lto-type-mismatch] 2931 | UQI opval = GET_H_PSW (); | ^ m32r/m32rx.c:153:1: note: return value type mismatch 153 | m32rxf_h_psw_get_handler (SIM_CPU *current_cpu) | ^ m32r/m32rx.c:153:1: note: type 'UQI' should match type 'int' m32r/m32rx.c:153:1: note: 'm32rxf_h_psw_get_handler' was previously declared here m32r/semx-switch.c:3106:16: error: type of 'm32rxf_h_accum_get_handler' does not match original declaration [-Werror=lto-type-mismatch] 3106 | DI opval = SRADI (SLLDI (SUBDI (GET_H_ACCUM (), SRADI (SLLDI (MULDI (EXTHIDI (TRUNCSIHI (* FLD (i_src1))), EXTHIDI (TRUNCSIHI (* FLD (i_src2)))), 32), 16)), 8), 8); | ^ m32r/m32rx.c:168:1: note: return value type mismatch 168 | m32rxf_h_accum_get_handler (SIM_CPU *current_cpu) | ^ m32r/m32rx.c:168:1: note: type 'DI' should match type 'int' m32r/m32rx.c:168:1: note: 'm32rxf_h_accum_get_handler' was previously declared here m32r/m32rx.c:168:1: note: code may be misoptimized unless '-fno-strict-aliasing' is used m32r/semx-switch.c:1959:16: error: type of 'm32rxf_h_accums_get_handler' does not match original declaration [-Werror=lto-type-mismatch] 1959 | DI opval = SRADI (SLLDI (ADDDI (GET_H_ACCUMS (FLD (f_acc)), MULDI (EXTSIDI (ANDSI (* FLD (i_src1), 0xffff0000)), EXTHIDI (TRUNCSIHI (SRASI (* FLD (i_src2), 16))))), 8), 8); | ^ m32r/m32rx.c:187:1: note: return value type mismatch 187 | m32rxf_h_accums_get_handler (SIM_CPU *current_cpu, UINT regno) | ^ m32r/m32rx.c:187:1: note: type 'DI' should match type 'int' m32r/m32rx.c:187:1: note: 'm32rxf_h_accums_get_handler' was previously declared here m32r/m32rx.c:187:1: note: code may be misoptimized unless '-fno-strict-aliasing' is used m32r/traps.c:105:43: error: type of 'm32rbf_h_psw_get' does not match original declaration [-Werror=lto-type-mismatch] 105 | m32rbf_h_bpsw_set (current_cpu, m32rbf_h_psw_get (current_cpu)); | ^ m32r/cpu.c:114:1: note: return value type mismatch 114 | m32rbf_h_psw_get (SIM_CPU *current_cpu) | ^ m32r/cpu.c:114:1: note: type 'UQI' should match type 'int' m32r/cpu.c:114:1: note: 'm32rbf_h_psw_get' was previously declared here m32r/cpu.c:116:10: error: type of 'm32rbf_h_psw_get_handler' does not match original declaration [-Werror=lto-type-mismatch] 116 | return GET_H_PSW (); | ^ m32r/m32r.c:251:1: note: return value type mismatch 251 | m32rbf_h_psw_get_handler (SIM_CPU *current_cpu) | ^ m32r/m32r.c:251:1: note: type 'UQI' should match type 'int' m32r/m32r.c:251:1: note: 'm32rbf_h_psw_get_handler' was previously declared here lto1: some warnings being treated as errors lto-wrapper: fatal error: x86_64-pc-linux-gnu-gcc returned 1 exit status compilation terminated. /usr/libexec/gcc/x86_64-pc-linux-gnu/ld: error: lto-wrapper failed collect2: error: ld returned 1 exit status make[4]: *** [Makefile:3755: m32r/run] Error 1 make[4]: Leaving directory '/var/tmp/portage/dev-debug/gdb-14.1-r1/work/gdb-14.1/sim' Reproducible: Always
Created attachment 887514 [details] build.log.xz /// use xzless to see it in. or `xz -d -c > your_favourite_editor`
Created attachment 887515 [details] environment /// amd64 gcc stable openrc profile: desktop/plasma multilib -O3 -flto=auto + warnings for lto + verbose -march=native
reproducible with dev-debug/gdb-14.2