From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-oi1-x232.google.com (mail-oi1-x232.google.com [IPv6:2607:f8b0:4864:20::232]) by sourceware.org (Postfix) with ESMTPS id 951AC3857803 for ; Thu, 16 Feb 2023 09:36:35 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 951AC3857803 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-oi1-x232.google.com with SMTP id cz14so1102067oib.12 for ; Thu, 16 Feb 2023 01:36:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20210112.gappssmtp.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=4CsLkk7WomFQeKs2rO8CMTHkwI9R87GOqWlzKgMRQB4=; b=ph9xyy3v8gI1eNflkCA2R6eKC3jZUKM2ELol8YbGdc4GtKfc4nBa0Er64cArkF8ZhQ 4M3Nu3SBteI/9+eHfbImauQmdJnxXlFdgvm44bP7DfuMHxtHhcxlmHsDaXnjJOhVqFyz en1zS+eM5+gz6M5SxyhVB2zsSvhZxsbXiyhP68Hztp4VdrIUIN2e+Qa3Vq0twR7hbaJH 1tn9igu5e0li4/SYnjRW32EXpcYq0Pq+SZmmaKFbP5OBOFnxp1c8YpDsfeCXc+jh+77q KZT8OA5dcyQwiOqVYOL26WG2a/WN78sq4uAE5P/joUbMqsd+EUyIrN/tWPo7nvHuhdhJ cvtw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=4CsLkk7WomFQeKs2rO8CMTHkwI9R87GOqWlzKgMRQB4=; b=8ORWravmsvXtyXnax23D4ZaA3zxulo2JwcQ/rn2dnkA9SHo9wfFkq3mfNKCabXpHa/ nf/4ErkmR82wWUQu0Z96scFuM5JNGOBN8YeSuvbXBvlHBmMJfIopMg7BHZKBmaeoWDc5 TtxKoKWxQKlYwsDEaN6OJuMqNfBiT+7vrE662Dcb7V85H8dBcwtL5zDYrGic7JDRBwy2 uE/k1Zx0a2BoYdDPkULzMo8M0LixXObYwp8jE2v0jBk/whUIKFCoixED7jpdUM6XYfTK nDQ73Aw/usz8wRTlNUlHAaLPgfhx5ZAm2+Bf2EzA+MN/4fraTLIPhVoWhSMZcWVJrzWh Tp/g== X-Gm-Message-State: AO0yUKXZa6XazmkR/BH+2kLwMd4fQSfHDzKRCjf1G+9i7+KtIs12mttB XwjW0eSzAxVMrijdGebEn9xZ48H/S/KXDK7GZRdXwg== X-Google-Smtp-Source: AK7set/e/HXkg4/5AGOx1k2jMrz2DtUs31oIZWIwHt7xucJqO5p9voVUbnQivOkPZbHqGuZwY3TFMbLjDgLhpbYGEho= X-Received: by 2002:a05:6808:1241:b0:35c:4435:fc2e with SMTP id o1-20020a056808124100b0035c4435fc2emr156874oiv.244.1676540194759; Thu, 16 Feb 2023 01:36:34 -0800 (PST) MIME-Version: 1.0 References: <2df3478a-3cd9-d7b5-670e-60683ae3066e@suse.com> <3bb126f6-5bf1-dab0-f540-25c386b9507e@suse.com> In-Reply-To: From: Nelson Chu Date: Thu, 16 Feb 2023 17:36:23 +0800 Message-ID: Subject: Re: [PATCH 2/2] RISC-V: adjust logic to avoid register name symbols To: Jan Beulich Cc: Binutils , Palmer Dabbelt , Andrew Waterman , Jim Wilson Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-3.4 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Yeah the logs are too big, so not sure where can be uploaded these kind of huge files. However, we should get the same result if we just run the gcc upstream testsuites. Seems many errors but a quick review, most of them are, *Assembler messages: *Error: register value used as expression ... Here are some details, Executing on host: /scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/xgcc -B/scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/ -march=rv64gc -mabi=lp64d -mcmodel=medlow -fdiagnostics-plain-output -O1 -w -c -o pr79780.o /scratch/riscv-gnu-toolchain/gcc/gcc/testsuite/gcc.c-torture/compile/pr79780.c (timeout = 600) spawn -ignore SIGHUP /scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/xgcc -B/scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/ -march=rv64gc -mabi=lp64d -mcmodel=medlow -fdiagnostics-plain-output -O1 -w -c -o pr79780.o /scratch/riscv-gnu-toolchain/gcc/gcc/testsuite/gcc.c-torture/compile/pr79780.c /tmp/cc1LYHhd.s: Assembler messages: /tmp/cc1LYHhd.s:17: Error: register value used as expression /tmp/cc1LYHhd.s:18: Error: register value used as expression /tmp/cc1LYHhd.s:28: Error: register value used as expression /tmp/cc1LYHhd.s:29: Error: register value used as expression /tmp/cc1LYHhd.s:54: Error: register value used as expression /tmp/cc1LYHhd.s:55: Error: register value used as expression /tmp/cc1LYHhd.s:61: Error: register value used as expression /tmp/cc1LYHhd.s:62: Error: register value used as expression /tmp/cc1LYHhd.s:65: Error: register value used as expression compiler exited with status 1 FAIL: gcc.c-torture/compile/pr79780.c -O1 (test for excess errors) ... Executing on host: /scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/xgcc -B/scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/ -march=rv64gc -mabi=lp64d -mcmodel=medlow -fdiagnostics-plain-output -O0 -w -c -o funcptr-1.o /scratch/riscv-gnu-toolchain/gcc/gcc/testsuite/gcc.c-torture/compile/funcptr-1.c (timeout = 600) spawn -ignore SIGHUP /scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/xgcc -B/scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/ -march=rv64gc -mabi=lp64d -mcmodel=medlow -fdiagnostics-plain-output -O0 -w -c -o funcptr-1.o /scratch/riscv-gnu-toolchain/gcc/gcc/testsuite/gcc.c-torture/compile/funcptr-1.c /tmp/cc1RjV1g.s: Assembler messages: /tmp/cc1RjV1g.s:34: Error: register value used as expression /tmp/cc1RjV1g.s:35: Error: register value used as expression compiler exited with status 1 FAIL: gcc.c-torture/compile/funcptr-1.c -O0 (test for excess errors) ... Executing on host: /scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/testsuite/g++/../../xg++ -B/scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/testsuite/g++/../../ -march=rv64gc -mabi=lp64d -mcmodel=medlow -fdiagnostics-plain-output -nostdinc++ -I/scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/riscv64-unknown-linux-gnu/libstdc++-v3/include/riscv64-unknown-linux-gnu -I/scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/riscv64-unknown-linux-gnu/libstdc++-v3/include -I/scratch/riscv-gnu-toolchain/gcc/libstdc++-v3/libsupc++ -I/scratch/riscv-gnu-toolchain/gcc/libstdc++-v3/include/backward -I/scratch/riscv-gnu-toolchain/gcc/libstdc++-v3/testsuite/util -fmessage-length=0 -std=c++17 -DCXX14_VS_CXX17 -w -I/scratch/riscv-gnu-toolchain/gcc/gcc/testsuite/g++.dg/compat -Wno-abi -c -o cp_compat_y_tst.o /scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/testsuite/g++/g++.dg-struct-layout-1//t032_y.C (timeout = 600) spawn -ignore SIGHUP /scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/testsuite/g++/../../xg++ -B/scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/testsuite/g++/../../ -march=rv64gc -mabi=lp64d -mcmodel=medlow -fdiagnostics-plain-output -nostdinc++ -I/scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/riscv64-unknown-linux-gnu/libstdc++-v3/include/riscv64-unknown-linux-gnu -I/scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/riscv64-unknown-linux-gnu/libstdc++-v3/include -I/scratch/riscv-gnu-toolchain/gcc/libstdc++-v3/libsupc++ -I/scratch/riscv-gnu-toolchain/gcc/libstdc++-v3/include/backward -I/scratch/riscv-gnu-toolchain/gcc/libstdc++-v3/testsuite/util -fmessage-length=0 -std=c++17 -DCXX14_VS_CXX17 -w -I/scratch/riscv-gnu-toolchain/gcc/gcc/testsuite/g++.dg/compat -Wno-abi -c -o cp_compat_y_tst.o /scratch/build-toolchains/rv64gc-linux/build-gcc-linux-stage2/gcc/testsuite/g++/g++.dg-struct-layout-1//t032_y.C /tmp/cci191w8.s: Assembler messages: /tmp/cci191w8.s:50: Error: register value used as expression /tmp/cci191w8.s:51: Error: register value used as expression ... too many... compiler exited with status 1 FAIL: tmpdir-g++.dg-struct-layout-1/t032 cp_compat_y_tst.o compile ... Sorry that I only extracted some small snippets, since there are too many. It would be better to just run the gcc testsuite again, with any environments. Hope these information are helpful, thanks Nelson On Wed, Feb 15, 2023 at 5:21 PM Jan Beulich wrote: > > On 15.02.2023 09:48, Nelson Chu wrote: > > Thanks for the detailed clarify :-) > > > > A quick update, I just use riscv-gnu-toolchain to build a linux toolchain with, > > gcc (releases/gcc-12.2.0) + binutils (master + these two patches) + > > glibc (release/2.37/master), > > and then I get some unexpected errors from gcc testsuite, which won't > > occurred without these patches. > > > > ========= Summary of gcc testsuite ========= > > | # of unexpected case / # of unique unexpected case > > | gcc | g++ | gfortran | > > rv64gc/ lp64d/ medlow | 347 / 62 | 29 / 9 | 0 / 0 | > > > > I haven't tested the elf regressions, and the whole linux regression, > > but it seems that there are some unexpected situations that we have > > not considered in this patch. > > Hmm, this suggests to me that testcases are missing in the gas testsuite. > > > Reproduce commands, > > 1. git clone https://github.com/riscv-collab/riscv-gnu-toolchain.git --recursive > > 2. need to install some tools before build, > > https://github.com/riscv-collab/riscv-gnu-toolchain#prerequisites > > 3. git checkout branches of gcc, binutils and glibc to the branches > > mentioned above > > 4. cd > > 5. configure > > --prefix=build-install --with-arch=rv64gc > > 6. make report-gcc-linux -j32 > > Instead of me trying to go through this (at least part of which looks like > it won't really fit my normal environment; among other things I would also > prefer to work from upstream gcc, not any RISC-V clone thereof), could you > provide me with the detailed gcc.log and g++.log from the run (I know > they're huge, so you may want to upload them somewhere, or you might simply > extract relevant fragments)? Of course if it would be the complete logs, > then I would also need to know which, if any, FAILs are pre-existing. > > From what you write it also doesn't look as if glibc was necessary to > include. > > Jan