https://gcc.gnu.org/bugzilla/show_bug.cgi?id=124320
Bug ID: 124320
Summary: FAIL: gcc.dg/lto/toplevel-extended-asm-1
c_lto_toplevel-extended-asm-1_0.o-c_lto_toplevel-exten
ded-asm-1_1.o link, -O2 -flto -flto-partition=1to1
Product: gcc
Version: 16.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: testsuite
Assignee: unassigned at gcc dot gnu.org
Reporter: azoff at gcc dot gnu.org
Target Milestone: ---
The default mode for an arm-none-eabi toolchain is arm mode and thus, when
testing such a toolchain in thumb mode, the testcase fails as the inline
assembler functions are defaulting back to arm mode and not all targets support
mixing arm and thumb modes.
The test case needs to be updated to support thumb mode and/or duplicated with
a dedicated thumb variant.
lto-execute:
/build/gcc_src/gcc/testsuite/gcc.dg/lto/toplevel-extended-asm-1_0.c
getting options for
/build/gcc_src/gcc/testsuite/gcc.dg/lto/toplevel-extended-asm-1_0.c: {
dg-lto-do 1 link } { dg-lto-options 2 {{-O2 -flto -flto-partition=1to1} } }
cmd is dg-lto-do
dg-lto-do command for " dg-lto-do 1 link " is link
cmd is dg-lto-options
dg-extra-tool-flags for main is {-O2 -flto -flto-partition=1to1}
src_list is:
/build/gcc_src/gcc/testsuite/gcc.dg/lto/toplevel-extended-asm-1_0.c
/build/gcc_src/gcc/testsuite/gcc.dg/lto/toplevel-extended-asm-1_1.c
Testing gcc.dg/lto/toplevel-extended-asm-1, -O2 -flto -flto-partition=1to1
doing compile
Executing on host: /build/r16-7687-g772499fd7e2f9a/bin/arm-none-eabi-gcc
-mthumb -march=armv6s-m -mtune=cortex-m0 -mfloat-abi=soft -mfpu=auto
-fdiagnostics-plain-output -O2 -flto -flto-partition=1to1 -c -o
c_lto_toplevel-extended-asm-1_0.o
/build/gcc_src/gcc/testsuite/gcc.dg/lto/toplevel-extended-asm-1_0.c (timeout
= 800)
spawn -ignore SIGHUP /build/r16-7687-g772499fd7e2f9a/bin/arm-none-eabi-gcc
-mthumb -march=armv6s-m -mtune=cortex-m0 -mfloat-abi=soft -mfpu=auto
-fdiagnostics-plain-output -O2 -flto -flto-partition=1to1 -c -o
c_lto_toplevel-extended-asm-1_0.o
/build/gcc_src/gcc/testsuite/gcc.dg/lto/toplevel-extended-asm-1_0.c
pid is 639527 -639527
pid is -1
output is status 0
PASS: gcc.dg/lto/toplevel-extended-asm-1 c_lto_toplevel-extended-asm-1_0.o
assemble, -O2 -flto -flto-partition=1to1
doing compile
Executing on host: /build/r16-7687-g772499fd7e2f9a/bin/arm-none-eabi-gcc
-mthumb -march=armv6s-m -mtune=cortex-m0 -mfloat-abi=soft -mfpu=auto
-fdiagnostics-plain-output -O2 -flto -flto-partition=1to1 -c -o
c_lto_toplevel-extended-asm-1_1.o
/build/gcc_src/gcc/testsuite/gcc.dg/lto/toplevel-extended-asm-1_1.c (timeout
= 800)
spawn -ignore SIGHUP /build/r16-7687-g772499fd7e2f9a/bin/arm-none-eabi-gcc
-mthumb -march=armv6s-m -mtune=cortex-m0 -mfloat-abi=soft -mfpu=auto
-fdiagnostics-plain-output -O2 -flto -flto-partition=1to1 -c -o
c_lto_toplevel-extended-asm-1_1.o
/build/gcc_src/gcc/testsuite/gcc.dg/lto/toplevel-extended-asm-1_1.c
pid is 639555 -639555
pid is -1
output is status 0
PASS: gcc.dg/lto/toplevel-extended-asm-1 c_lto_toplevel-extended-asm-1_1.o
assemble, -O2 -flto -flto-partition=1to1
doing compile
Executing on host: /build/r16-7687-g772499fd7e2f9a/bin/arm-none-eabi-gcc
c_lto_toplevel-extended-asm-1_0.o c_lto_toplevel-extended-asm-1_1.o -mthumb
-march=armv6s-m -mtune=cortex-m0 -mfloat-abi=soft -mfpu=auto -dumpbase ""
-fdiagnostics-plain-output -O2 -flto -flto-partition=1to1
--specs=rdimon.specs -o gcc-dg-lto-toplevel-extended-asm-1-01.exe (timeout =
800)
spawn -ignore SIGHUP /build/r16-7687-g772499fd7e2f9a/bin/arm-none-eabi-gcc
c_lto_toplevel-extended-asm-1_0.o c_lto_toplevel-extended-asm-1_1.o -mthumb
-march=armv6s-m -mtune=cortex-m0 -mfloat-abi=soft -mfpu=auto -dumpbase
-fdiagnostics-plain-output -O2 -flto -flto-partition=1to1 --specs=rdimon.specs
-o gcc-dg-lto-toplevel-extended-asm-1-01.exe
pid is 639590 -639590
lto-wrapper: warning: using serial compilation of 2 LTRANS jobs
lto-wrapper: note: see the '-flto' option documentation for more information
/build/r16-7687-g772499fd7e2f9a/arm-none-eabi/bin/ld:
/tmp/ccqkckVe.ltrans0.ltrans.o(asm_fn_used): Unknown destination type
(ARM/Thumb) in /tmp/ccqkckVe.ltrans1.ltrans.o
/tmp/ccqkckVe.ltrans1.ltrans.o: in function `local_caller':
<artificial>:(.text+0xa): dangerous relocation: unsupported relocation
collect2: error: ld returned 1 exit status
pid is -1
close result is 639590 exp5 0 1
output is lto-wrapper: warning: using serial compilation of 2 LTRANS jobs
lto-wrapper: note: see the '-flto' option documentation for more information
/build/r16-7687-g772499fd7e2f9a/arm-none-eabi/bin/ld:
/tmp/ccqkckVe.ltrans0.ltrans.o(asm_fn_used): Unknown destination type
(ARM/Thumb) in /tmp/ccqkckVe.ltrans1.ltrans.o
/tmp/ccqkckVe.ltrans1.ltrans.o: in function `local_caller':
<artificial>:(.text+0xa): dangerous relocation: unsupported relocation
collect2: error: ld returned 1 exit status
status 1
compiler exited with status 1
FAIL: gcc.dg/lto/toplevel-extended-asm-1
c_lto_toplevel-extended-asm-1_0.o-c_lto_toplevel-extended-asm-1_1.o link, -O2
-flto -flto-partition=1to1