From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id C29AE3857007 for ; Thu, 16 Mar 2023 14:45:41 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org C29AE3857007 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1678977941; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=DAoYNDEeg13yu0C3Yzeu7wyABQ/rsle13vVeSTX/2kg=; b=jACtqcumWAljyBAwvPPkgqqHeTXDLyq94EIN2lDL/tRxLUY+Xe5eT5mhrF20IfYRDcyHsK vzR/I9JSNwHuj5M1TiMWy/cyrRMJGDCM7aSruTl/+CUwlK1+UB1T5w3F4KgGyS7jYOEnAe PeuPsxIt12/ag0kbVC5XiVt9r2xhpCA= Received: from mail-qv1-f70.google.com (mail-qv1-f70.google.com [209.85.219.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-124-nX3RLi10OLKdLRq74YLEFw-1; Thu, 16 Mar 2023 10:45:39 -0400 X-MC-Unique: nX3RLi10OLKdLRq74YLEFw-1 Received: by mail-qv1-f70.google.com with SMTP id f8-20020a0cbec8000000b005b14a30945cso1174085qvj.8 for ; Thu, 16 Mar 2023 07:45:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678977939; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:to:from:subject:message-id:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=DAoYNDEeg13yu0C3Yzeu7wyABQ/rsle13vVeSTX/2kg=; b=iGy31u/ftcIgICjzohYhM9ZjIoJavsvP+uHoJ0R+t4XfheyTEzNmHY3Wn52yswKjAL CUbt27tfypBxCCSg6DMD3fzrwySlVc0Qinhth5sEg90QVj450/dpSWb2WsUuRUVN++hU CXoGsY0sVVZ8pHr+vPwwMEwzfwPtbrS5FMRE1soVTBYV7vsFLi33z87Q7MMWTgaODq+W InplXxDyijIY7LaBvPFLoOGrBpaCpLAzaigJvNNBwMPkuak8pQ6KtPOy4faZ/85uiDML yWekuPCK+MugAQMbTy6ZDI/uZi7bQMsbsc2F8VbTUoerpoJ4UiwVfaNC3DPfXHKCDD7o DtAA== X-Gm-Message-State: AO0yUKU3TUSIoUWHETTcH02HUS3BrfDOuMVMoh2+vnRLOiU+oMzW5uG5 McVlfNM7BSbYug4s98IxXnQrH7MQGuJv1vV6xoiNXvmvy8gtmpRh0zEE4IxRR+wj+SJ7QhjDL+Y kDAtR5CrK1SRutkqNrQ== X-Received: by 2002:a05:622a:10b:b0:3d8:a785:ec01 with SMTP id u11-20020a05622a010b00b003d8a785ec01mr2539928qtw.48.1678977939249; Thu, 16 Mar 2023 07:45:39 -0700 (PDT) X-Google-Smtp-Source: AK7set+fNSkvxBvazwhuapjacUSXVPhFBkHc/sInnpZD2dpp2USE1g0RDWjJfDwnEH4WLucruEcj8w== X-Received: by 2002:a05:622a:10b:b0:3d8:a785:ec01 with SMTP id u11-20020a05622a010b00b003d8a785ec01mr2539881qtw.48.1678977938811; Thu, 16 Mar 2023 07:45:38 -0700 (PDT) Received: from t14s.localdomain (c-73-69-212-193.hsd1.nh.comcast.net. [73.69.212.193]) by smtp.gmail.com with ESMTPSA id o7-20020a374107000000b00745c4d90aacsm5577804qka.115.2023.03.16.07.45.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 16 Mar 2023 07:45:38 -0700 (PDT) Message-ID: <7fd3f96fd6edd3d6e358d17ef193655e7a1460a6.camel@redhat.com> Subject: Re: [PATCH] diagnostics: fix crash with -fdiagnostics-format=json-file From: David Malcolm To: Martin =?UTF-8?Q?Li=C5=A1ka?= , gcc-patches@gcc.gnu.org Date: Thu, 16 Mar 2023 10:45:37 -0400 In-Reply-To: <3cf31374-0496-3119-7775-0c22bc03cb38@suse.cz> References: <60f9fd2b-211e-c1d5-e17a-1fab1ee51338@suse.cz> <3cf31374-0496-3119-7775-0c22bc03cb38@suse.cz> User-Agent: Evolution 3.44.4 (3.44.4-1.fc36) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-5.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,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 Tue, 2023-01-10 at 16:10 +0100, Martin Li=C5=A1ka wrote: > On 1/6/23 14:21, David Malcolm wrote: > > On Fri, 2023-01-06 at 12:33 +0100, Martin Li=C5=A1ka wrote: > > > Patch can bootstrap on x86_64-linux-gnu and survives regression > > > tests. > >=20 > > Thanks for the patch. > >=20 > > I noticed that you marked PR 108307 as a dup of this, which covers > > -fdiagnostics-format=3Dsarif-file (and a .S file as input). > >=20 > > The patch doesn't add any test coverage (for either of the > > diagnostic > > formats). > >=20 > > If we try to emit a diagnostic and base_file_name is NULL, and the > > user > > requested one of -fdiagnostics-format=3D{json,sarif}-file, where do > > the > > diagnostics go?=C2=A0 Where should they go? >=20 > Hey. >=20 > I've done a new version of the patch where I utilize > x_main_input_basename. >=20 > Patch can bootstrap on x86_64-linux-gnu and survives regression > tests. >=20 > Ready to be installed? Sorry about the long delay; the updated patch is good for trunk. Thanks Dave