Message ID | 20240509174236.2278921-9-dmalcolm@redhat.com |
---|---|
State | New |
Headers | show
Return-Path: <gcc-patches-bounces+incoming=patchwork.ozlabs.org@gcc.gnu.org> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=aWGjq0XT; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=2620:52:3:1:0:246e:9693:128c; helo=server2.sourceware.org; envelope-from=gcc-patches-bounces+incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=patchwork.ozlabs.org) Received: from server2.sourceware.org (server2.sourceware.org [IPv6:2620:52:3:1:0:246e:9693:128c]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4VZzvG5Qptz20fZ for <incoming@patchwork.ozlabs.org>; Fri, 10 May 2024 03:45:46 +1000 (AEST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id EF1843875426 for <incoming@patchwork.ozlabs.org>; Thu, 9 May 2024 17:45:44 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org 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 B431E3865479 for <gcc-patches@gcc.gnu.org>; Thu, 9 May 2024 17:42:51 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org B431E3865479 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org B431E3865479 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1715276573; cv=none; b=bAQod4FozX3uXzu4D5PPlCkF5K5KI4EcoPjh2Qt6rJ1P2oOxEpW5Be5C7BNfL8Oc8+gDOVZoVKWlbuc4Xupmop8qfmt5Kwg9GU5DWnCPecPUnsSpxHiPnvcU9Aaxe+O8hesA9ePxu65OAzDJFf4dLRo3kh3HNFI5/h1BRNUbyQ0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1715276573; c=relaxed/simple; bh=WyAOL9UgADbbVvBugcMT6OyEi52KPTdsURETedHXCvo=; h=DKIM-Signature:From:To:Subject:Date:Message-Id:MIME-Version; b=pL3fJdBKeB1coVygsge0oMFqJlpflQ/IT1a3rV1RfWOPOVkU5dHKKGBrZjCMNdH0pyAvPK3WmHUGx7XFW7p7PbHwXdnDjPnf+ESo+ofz9UkbrCxoWfnyCbvTvbZCLp3KVSHrvfjySk1H10aDLfC70KwlxnHKNTPHvRE1TAqu2js= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1715276571; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=lljLlWvDETCi28tLvEMv1ElXHbE0MeUxX1lumkd/6bM=; b=aWGjq0XTaQrpqakPzPKAcoedFrlkYl7EFdjAneJPUdYOIqqQnai+0Aytbbt82GoqwQP1L1 0Nw7QSvZsXTHxC3NXsihu+5sk8q9npt0bif+QafoAs2iWWaYyNrG0SaoKgL+IKZU49YW2+ TR/eQbn6QW48j4jgYPVpBNFfWK7PSV8= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-526-QXfLZDO4NbeawNGsSRUffQ-1; Thu, 09 May 2024 13:42:50 -0400 X-MC-Unique: QXfLZDO4NbeawNGsSRUffQ-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id B0B0E8025F9 for <gcc-patches@gcc.gnu.org>; Thu, 9 May 2024 17:42:49 +0000 (UTC) Received: from t14s.localdomain.com (unknown [10.22.18.2]) by smtp.corp.redhat.com (Postfix) with ESMTP id 89686746822; Thu, 9 May 2024 17:42:49 +0000 (UTC) From: David Malcolm <dmalcolm@redhat.com> To: gcc-patches@gcc.gnu.org Cc: David Malcolm <dmalcolm@redhat.com> Subject: [PATCH 08/21] testsuite, analyzer: add test case [PR108171] Date: Thu, 9 May 2024 13:42:23 -0400 Message-Id: <20240509174236.2278921-9-dmalcolm@redhat.com> In-Reply-To: <20240509174236.2278921-1-dmalcolm@redhat.com> References: <20240509174236.2278921-1-dmalcolm@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.10 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true X-Spam-Status: No, score=-11.7 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, 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 X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> Errors-To: gcc-patches-bounces+incoming=patchwork.ozlabs.org@gcc.gnu.org |
Series |
Various backports to gcc 13 (analyzer, jit, diagnostics)
|
expand
|
diff --git a/gcc/testsuite/gcc.dg/analyzer/pr108171.c b/gcc/testsuite/gcc.dg/analyzer/pr108171.c new file mode 100644 index 00000000000..5f7b9fd7875 --- /dev/null +++ b/gcc/testsuite/gcc.dg/analyzer/pr108171.c @@ -0,0 +1,31 @@ +struct nl_context { + void *cmd_private; +}; + +struct sfeatures_context { + int a; + int req_mask[0]; +}; + +int set_sf_req_mask_idx; + +extern void fill_legacy_flag(); + +void +fill_sfeatures_bitmap(struct nl_context *nlctx) { + while (nlctx) { + fill_legacy_flag(); + struct nl_context __trans_tmp_1 = *nlctx; + struct sfeatures_context *sfctx = __trans_tmp_1.cmd_private; + sfctx->req_mask[set_sf_req_mask_idx] |= 1; + } +} + +void +nl_sfeatures() { + struct nl_context nlctx; + struct sfeatures_context *sfctx; + nlctx.cmd_private = &sfctx; + sfctx = 0; + fill_sfeatures_bitmap(&nlctx); +}
The ICE in PR analyzer/108171 appears to be a dup of the recently fixed PR analyzer/110882 and is likewise fixed by it; adding this test case. gcc/testsuite/ChangeLog: PR analyzer/108171 * gcc.dg/analyzer/pr108171.c: New test. (cherry picked from commit r14-2957-gf80efa49b7a163) Signed-off-by: David Malcolm <dmalcolm@redhat.com> --- gcc/testsuite/gcc.dg/analyzer/pr108171.c | 31 ++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 gcc/testsuite/gcc.dg/analyzer/pr108171.c