From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf1-x12a.google.com (mail-lf1-x12a.google.com [IPv6:2a00:1450:4864:20::12a]) by sourceware.org (Postfix) with ESMTPS id 7C7223858CDB for ; Mon, 28 Nov 2022 11:44:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 7C7223858CDB Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-lf1-x12a.google.com with SMTP id j16so16866686lfe.12 for ; Mon, 28 Nov 2022 03:44:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=B4SfNFjvZDkYfED3pq6z45nbTmnNb+qDmlKpTHJNiEA=; b=BP7hkcoQb3rp8vL84pJSBbfqxL63JPqR/LkQVOPZeUWonFAw9yaEeuqd3cL2aGLWZ+ pASOV1J0aTtqKUEiC+NCFkjbNFyNM/Jw5xX3Goak9Wi8NkNp+skkWMICbNlhYutaqao6 v/o1eDd4vi0f6RIS/Ll7MZ4kSyfEqNJRp/pyMwG30Up/C4xtXVgrsx7yRqhiQLfynyi9 IoIdd27yXGlmuk688+dj+NKteGzBlMkzR3HD7X0xQcHcr0J7uuMSRWtFsiqlJa0pULHP Rfbo5mY5oMCe+XOK9Y2p8AH0YW9VyN2hUqRbuU07AB6Uk0zAnACfwFZ/ADfYrwUPKxm1 OvCw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=B4SfNFjvZDkYfED3pq6z45nbTmnNb+qDmlKpTHJNiEA=; b=jCDl4jAvpxBGWMhb5hsp8ym+zE6Nm81jJLokCw3mJWKsAJCc/d8kglOKG2aDzmHSVB L580kTPozqsORQ2PdkhLMjozBn9IRqtOtzA/MODf7dQicfFogKOlp3cmDlyC3IMWtNGJ /U2SHAyNE7VZx4FdlpXWA7FKtCI3OOIeoOZmI3/o00tfxBlQPkl3eVhQA2GYHpk71hQz /lxC8YKxHXze/CVzYQncm7hriorc1U/F0SjyQOiJDuzC6Uws/nldPrWmOJUL6OAd4j5t VLxwyxaIa9lqssnqgtaGoTwuoRX3p5S74RxqnifuXWskSAj+/B4iVFRIxGSdeGeXZqTu 9ZsA== X-Gm-Message-State: ANoB5plyBHbEO5m/rkUCNmKuVhPGZ2VuMRlERDXLrtY46cQ9lANshIRi XdEYwettWR+dj3uWdQ+uD+ZbPack8me433QzouI= X-Google-Smtp-Source: AA0mqf6XntzIT/Ln6F6/PXYxgkpogurBdKpxxrG22gcODF92aVzL/J7B0pF0hrKeCMOQ9WyZDFQWffw9pf+uVoo9poM= X-Received: by 2002:a05:6512:3d10:b0:4b4:1177:a64c with SMTP id d16-20020a0565123d1000b004b41177a64cmr19143669lfv.647.1669635856780; Mon, 28 Nov 2022 03:44:16 -0800 (PST) MIME-Version: 1.0 References: <87y1rvs4gd.fsf@oldenburg.str.redhat.com> In-Reply-To: <87y1rvs4gd.fsf@oldenburg.str.redhat.com> From: Richard Biener Date: Mon, 28 Nov 2022 12:44:04 +0100 Message-ID: Subject: Re: Triggering -save-temps from the front-end code To: Florian Weimer Cc: gcc@gcc.gnu.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.0 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,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 Mon, Nov 28, 2022 at 12:30 PM Florian Weimer via Gcc w= rote: > > I've got some instrumentation for logging errors to a magic directory, > so that I can see if a build triggered them even when it did not > fail=E2=80=94and hid all compiler errors and warnings. > > Unfortunately, some build systems immediately delete the input source > files. Is there some easy way I can dump the pre-processed and > non-preprocessed sources to my log file? I tried to understand how > -save-temps for crash recovery works, but it seems that this runs > outside of the frontend, in the driver. Yep, there's no way to trigger -save-temps behavior after-the-fact. > Here's an example of the > challenges this would help to solve: > > Building in strict C99 mode > > > Thanks, > Florian >