From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr1-x429.google.com (mail-wr1-x429.google.com [IPv6:2a00:1450:4864:20::429]) by sourceware.org (Postfix) with ESMTPS id 253B13858D32 for ; Thu, 26 Oct 2023 18:38:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 253B13858D32 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 253B13858D32 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2a00:1450:4864:20::429 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1698345484; cv=none; b=Xvwiy3pWuzTQJVpmoWnFlPXFyrYVTJT7byydF/XSe4iOWlb25ON7oxxA5moQSj7m2uAOH1JzDPH/oiZla7RrG0HIsh3wF5XTjBUa0IUNXfr60HuaE+aXDzEqXxSlaRiCEHQRkLW/5vuRsbJeDIw79TlrW5yTlGCdUe90paqhlrg= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1698345484; c=relaxed/simple; bh=9IFH8VOkmBl3RmgqxJFpEJTzZiQs8Df8vHAtpd9s2zQ=; h=DKIM-Signature:MIME-Version:From:Date:Message-ID:Subject:To; b=I3EbNN2GAUW9B7WATemVzIlC3lXZDLYWFrScycRtrAopvo0M8KmqwzEFet3b+yd8mkq9N7jT9YmIgbA37arJWbhYbGHw8ai+LvM4CWiXDdWixKV2+K5uIXbnF0dpXrg1AtaLJGdWxkaou2EMGkmXUTAPe/R5rbrL3N/PVIb5i5M= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-wr1-x429.google.com with SMTP id ffacd0b85a97d-32dff08bbdbso865192f8f.2 for ; Thu, 26 Oct 2023 11:38:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1698345482; x=1698950282; darn=gcc.gnu.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=9IFH8VOkmBl3RmgqxJFpEJTzZiQs8Df8vHAtpd9s2zQ=; b=q5/pPWHeiR6SAnQdDxDgbYe8MP9m8REhqnsUlv1mIZcMp7pO/dXf1v/qLGSc+mwfnJ gkWnOd5EPNZNddsGxId3kYv52i9zGtXaZ3SYq/weS6XbRIyiIQBmT6LaqD0qEPXwHNth D/ty2iZdDt2J3btq2j1/alzwbgSRPI3VxmqQMgKMj5qgFOi39xhJB5nJmvT8HyyE4iXS 7LcVzV92X8UqdNZ8mLje2ay7HyWSErNEOjTTFTUxg2JMNbdXeXhV+l1wDh9x0Skg/pZ2 P1mBc0NoMRCI0xACHtkqurvpKbiHDIwkyb6vm6GMj8guF+G8HHN29f6lvmmZSfOtxb79 rM3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698345482; x=1698950282; h=content-transfer-encoding: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=9IFH8VOkmBl3RmgqxJFpEJTzZiQs8Df8vHAtpd9s2zQ=; b=Uvgb5pO313vB0nwOSRHwZZBF8el6owAofeLjXapdIWEBymt2yCFkAOpGEvmkdyvYCM jBYTpeayY86l6jfvSteqwJBTA7BGdO2E/VCarpMgJbU7V5f6opG1LcuRBZ6q+ncOn43V LrFXUBmlUnQuunVt3wi9x7delcOIQNCODWcvKM1w5oR3e8oOnnL3VWKnoyVhzKVqOqav c9IF8R4ub4jVVdQs08xlNwcxroqHHG4GmhI8m4JZ2ep2GjdhiT+jl743y8P/qHQMjkKn /KL6TDHYv2js6O44GGRDobt0W46B/uxqc4czx8zahN0MeAZXGaIR1BAQdUKEnl/wwgrw 8XpA== X-Gm-Message-State: AOJu0YxFdcSp++WsQZoUreGjEjRNXVlRoYJGpMl1uuvnKObPoFXQuivj tJH4b4uqe40p8wYNzaVeYwgkIPd56+j18AskfkQGEselFN3kVNmSYhA= X-Google-Smtp-Source: AGHT+IFakLRQy5x3UB77xN6PYhGGV9WGCPeQ/P15WhyUiE+nc+aVlpq/4eMOpJhDrXXr/qfXW19VBpB9U7f7tnh9GeU= X-Received: by 2002:a19:771e:0:b0:507:96e5:2ff4 with SMTP id s30-20020a19771e000000b0050796e52ff4mr112669lfc.52.1698344997738; Thu, 26 Oct 2023 11:29:57 -0700 (PDT) MIME-Version: 1.0 References: <20230920041202.4099349-1-lhyatt@gmail.com> In-Reply-To: From: Christophe Lyon Date: Thu, 26 Oct 2023 20:29:49 +0200 Message-ID: Subject: Re: [PATCH] libcpp: Improve the diagnostic for poisoned identifiers [PR36887] To: Lewis Hyatt Cc: gcc-patches List Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-4.6 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,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: On Thu, 26 Oct 2023 at 19:44, Lewis Hyatt wrote: > > On Thu, Oct 26, 2023 at 12:48=E2=80=AFPM Christophe Lyon > wrote: > > > > On Thu, 26 Oct 2023 at 18:18, Lewis Hyatt wrote: > > > > > > On Thu, Oct 26, 2023 at 4:49=E2=80=AFAM Christophe Lyon > > > wrote: > > > > We have noticed that the new tests fail on aarch64 with: > > > > .../aarch64-unknown-linux-gnu/libc/usr/lib/crt1.o: in function `_st= art': > > > > .../sysdeps/aarch64/start.S:110:(.text+0x38): undefined reference t= o `main' > > > > > > > > Looking at the test, I'd say it lacks a dg-do compile (to avoid > > > > linking), but how does it work on other targets? > > > > > > Thanks for pointing it out. I am definitely under the impression that > > > { dg-do compile } is the default and doesn't need to be specified, I > > > have never seen it not be the case before... Is that just not correct= ? > > > I tried it out on the cfarm (gcc185) for aarch64-redhat-linux and it > > > works for me there too, I tried the test individually and also as par= t > > > of the whole check-gcc-c++ target. > > > > > > I do see that there are target-dependent functions in > > > testsuite/lib/*.exp that will change dg-do-what-default under some > > > circumstances... but I also see in dg-pch.exp (which is the one > > > relevant for this test g++.dg/pch/pr36887.C) that dg-do-what-default > > > is set to compile explicitly. > > > > Indeed, thanks for checking. > > > > > Note sure what the best next step is, should I just add { dg-do > > > compile } since it's harmless in any case, or is there something else > > > worth looking into here? I'm not sure why I couldn't reproduce the > > > issue on the compile farm machine either, maybe you wouldn't mind > > > please check if adding this line fixes it for you anyway? Thanks... > > > > Can you share the compile line for this test in g++.log? > > > > Sure, here is what I got on aarch64 for > > make RUNTESTFLAGS=3Dpch.exp=3Dpr36887.C check-gcc-c++ > > For making the PCH: > > xg++ -B/dev/shm/lhyatt/build/gcc/testsuite/g++/../../ ./pr36887.H > -fdiagnostics-plain-output -nostdinc++ > -I/dev/shm/lhyatt/build/aarch64-unknown-linux-gnu/libstdc++-v3/include/aa= rch64-unknown-linux-gnu > -I/dev/shm/lhyatt/build/aarch64-unknown-linux-gnu/libstdc++-v3/include > -I/dev/shm/lhyatt/src/libstdc++-v3/libsupc++ > -I/dev/shm/lhyatt/src/libstdc++-v3/include/backward > -I/dev/shm/lhyatt/src/libstdc++-v3/testsuite/util -fmessage-length=3D0 > -g -o pr36887.H.gch > > For compiling the test: > > xg++ -B/dev/shm/lhyatt/build/gcc/testsuite/g++/../../ > /dev/shm/lhyatt/src/gcc/testsuite/g++.dg/pch/pr36887.C > -fdiagnostics-plain-output -nostdinc++ > -I/dev/shm/lhyatt/build/aarch64-unknown-linux-gnu/libstdc++-v3/include/aa= rch64-unknown-linux-gnu > -I/dev/shm/lhyatt/build/aarch64-unknown-linux-gnu/libstdc++-v3/include > -I/dev/shm/lhyatt/src/libstdc++-v3/libsupc++ > -I/dev/shm/lhyatt/src/libstdc++-v3/include/backward > -I/dev/shm/lhyatt/src/libstdc++-v3/testsuite/util -fmessage-length=3D0 > -g -I. -Dwith_PCH -S -o pr36887.s > > (and then it repeats with -O2 added, or with -g removed as well) OK, thanks. Our CI harness adds a few linker options to g++ (-Wl,--dynamic-linker=3DXXX, -Wl-,-rpath...) which seem to force the GCC driver to invoke the linker. So, nothing to fix on the testsuite side ;-) I'll have a look to check if this is a driver bug, or if it can be fixed in our scripts. Sorry for the false alarm, Christophe > > > Actually I'm seeing several similar errors in our g++.log, not > > reported before because they were "pre-existing" failures. > > So something is confusing the testsuite and puts it into link mode. > > > > I am currently building from scratch, without our CI scripts to get > > some additional logs in a setup that probably matches yours. Then I > > should be able to add more traces a dejagnu level to understand what's > > happening. > > > > Thanks, > > > > Christophe