All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* [kvm-unit-test] Unable to build kvm-unit-test on little-endian PowerPC (lswx/lswi invalid when little-endian)
@ 2021-06-10 10:44 Po-Hsu Lin
  0 siblings, 0 replies; only message in thread
From: Po-Hsu Lin @ 2021-06-10 10:44 UTC (permalink / raw)
  To: kvm

Hello,

We have found an issue while trying to build this test on little-endian PowerPC:
gcc -std=gnu99 -ffreestanding -O2 -msoft-float -mabi=no-altivec
-mno-altivec -I /home/ubuntu/upstream/kvm-unit-tests/lib -I
/home/ubuntu/upstream/kvm-unit-tests/lib/libfdt -I lib -Wa,-mregnames
-g -MMD -MF powerpc/.emulator.d -fno-strict-aliasing -fno-common -Wall
-Wwrite-strings -Wempty-body -Wuninitialized -Wignored-qualifiers
-Werror  -fomit-frame-pointer  -fno-stack-protector
-Wno-frame-address   -fno-pic  -no-pie  -Wclobbered
-Wunused-but-set-parameter  -Wmissing-parameter-type
-Wold-style-declaration -Woverride-init -Wmissing-prototypes
-Wstrict-prototypes -mlittle-endian   -c -o powerpc/emulator.o
powerpc/emulator.c
/tmp/ccO2j7oR.s: Assembler messages:
/tmp/ccO2j7oR.s:335: Error: `lswx' invalid when little-endian
/tmp/ccO2j7oR.s:381: Error: `lswx' invalid when little-endian
/tmp/ccO2j7oR.s:403: Error: `lswx' invalid when little-endian
/tmp/ccO2j7oR.s:432: Error: `lswx' invalid when little-endian
/tmp/ccO2j7oR.s:643: Error: `lswi' invalid when little-endian
/tmp/ccO2j7oR.s:669: Error: `lswi' invalid when little-endian
/tmp/ccO2j7oR.s:690: Error: `lswi' invalid when little-endian
make: *** [<builtin>: powerpc/emulator.o] Error 1

A quick search on the Internet [1] indicates this has something to do
with a new version of binutils:
commit 86c0f617ac5f3a5f4aab76c7f90255254ca27576
Author: Alan Modra <amo...@gmail.com>
Date:   Mon Aug 10 15:06:43 2020 +0930

    Error on lmw, lswi and related PowerPC insns when LE
            * config/tc-ppc.c (md_assemble): Error for lmw, stmw, lswi, lswx,
            stswi, or stswx in little-endian mode.
            * testsuite/gas/ppc/476.d,
            * testsuite/gas/ppc/476.s: Delete lmw, stmw, lswi, lswx, stswi,
stswx.
            * testsuite/gas/ppc/a2.d,
            * testsuite/gas/ppc/a2.s: Move lmw, stmw, lswi, lswx, stswi,
stswx..
            * testsuite/gas/ppc/be.d,
            * testsuite/gas/ppc/be.s: ..to here, new big-endian only test.
            * testsuite/gas/ppc/le_error.d,
            * testsuite/gas/ppc/le_error.l: New little-endian test.
            * testsuite/gas/ppc/ppc.exp: Run new tests.

Since this test is not expected to work with little-endian, maybe we
can modify the endianess check in powerpc/emulator.c to skip this test
code snippet?

Thanks
PHLin

[1] https://www.mail-archive.com/kde-bugs-dist@kde.org/msg489085.html
BugLink: https://bugs.launchpad.net/ubuntu-kernel-tests/+bug/1931534

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-06-10 10:44 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-10 10:44 [kvm-unit-test] Unable to build kvm-unit-test on little-endian PowerPC (lswx/lswi invalid when little-endian) Po-Hsu Lin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.