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 ESMTP id D8574385782E for ; Wed, 25 Aug 2021 17:15:46 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org D8574385782E Received: from mail-qk1-f199.google.com (mail-qk1-f199.google.com [209.85.222.199]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-340-89LhIriTMiOAyaabfWum5g-1; Wed, 25 Aug 2021 13:15:44 -0400 X-MC-Unique: 89LhIriTMiOAyaabfWum5g-1 Received: by mail-qk1-f199.google.com with SMTP id 70-20020a370b49000000b003d2f5f0dcc6so55454qkl.9 for ; Wed, 25 Aug 2021 10:15:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=jn6Z+6q9L7p4b6H+UrrQeLEACWZUE2Aus/8Ve0YvNyU=; b=Fq1V5Ii1MZt09g/foPx30KhVHaTvm84+u6Y2dhUHOvZvePXDnqkRnZAvlmbHgnvyzk lOi1oI9nC08twPN2kscEOM/fxJ6kGJobGbAu8bQ5M8awnJoeuqgoITuIMxhZg7KQyEv6 fGv2lYpMi6LE1fcXfS9EqYC9RHfz05S6jQEB5V5keTBdJ18K8debZl+ZS5pHQ+YZ+pI6 b18hg+lKdT4v/YquPpNMqyR6r+WBHQ+8kP1D2mGkMdCWrfWje8uWzgW/TyKpXks9upuh ooj0FHpwvIBzzfWj2RlGQzlGy/V+q3GbVspnVf2un7UP5gE8lZ2lLtPfigAkPaupsRFl eE+g== X-Gm-Message-State: AOAM530tEMXQ6lg7//s6ZHJP6jmGQpj4u6ba/S6VwOnuiDJxEq0Q8d8T jxC5Z18VIJBUx+3xl4rTqIRABSwRoFzh4Bkh+Uo8LPDasGxGtp+LqGCg/3Xfz5Bo9j7TqyM0I1p rU5TjqFMQIqs7JiDJgg== X-Received: by 2002:ac8:758a:: with SMTP id s10mr35275267qtq.96.1629911744280; Wed, 25 Aug 2021 10:15:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJytWbEfz0rg8CGiMCC/qqDrbpXYjl58PUDcqhvM3ijeRqhYTS5G1Tnpw5ZQdClS38kliCB21Q== X-Received: by 2002:ac8:758a:: with SMTP id s10mr35275255qtq.96.1629911744009; Wed, 25 Aug 2021 10:15:44 -0700 (PDT) Received: from t14s.localdomain (c-73-69-212-193.hsd1.ma.comcast.net. [73.69.212.193]) by smtp.gmail.com with ESMTPSA id v7sm427268qkd.41.2021.08.25.10.15.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Aug 2021 10:15:43 -0700 (PDT) Message-ID: <7a999e68037cf92b857b2d987ec8e82385a4d6d9.camel@redhat.com> Subject: Re: [PATCH] analyzer: Impose recursion limit on indirect calls. From: David Malcolm To: Ankur Saini Cc: Martin =?UTF-8?Q?Li=C5=A1ka?= , gcc Patches Date: Wed, 25 Aug 2021 13:15:42 -0400 In-Reply-To: <6C8ACAA4-BD3A-480B-BB2D-FA7CD23E4AE0@gmail.com> References: <02524C4A-6B71-44BD-90E3-E9328DCE32E7@gmail.com> <5df6e7001a5792e5aeaf03de4658cad2c4bdc6e3.camel@redhat.com> <9C51062C-3457-4345-9BDC-20F7FE4BFA1E@gmail.com> <47cb93b4727ae6e4ff0f37e22947cc72705bf580.camel@redhat.com> <6C8ACAA4-BD3A-480B-BB2D-FA7CD23E4AE0@gmail.com> User-Agent: Evolution 3.38.4 (3.38.4-1.fc33) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00, BODY_8BITS, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Aug 2021 17:15:49 -0000 On Wed, 2021-08-25 at 21:25 +0530, Ankur Saini wrote: > > > > On 25-Aug-2021, at 8:35 PM, David Malcolm > > wrote: > > > > On Wed, 2021-08-25 at 20:31 +0530, Ankur Saini wrote: > > > > > > > > > > On 25-Aug-2021, at 7:24 PM, Martin Liška > > > > wrote: > > > > > > > > On 8/25/21 15:22, David Malcolm via Gcc-patches wrote: > > > > > On Wed, 2021-08-25 at 13:39 +0530, Ankur Saini wrote: > > > > > > This should also fix the failing regression found in PR > > > > > > analyzer/101980. > > > > > > > > > > > > - The patch is in sync with current master > > > > > > - successfully bootstrapped and tested on x86_64-linux-gnu. > > > > > > > > > > > The patch is OK for trunk. > > > > > Thanks for fixing this > > > > > Dave > > > > > > > > Hello. > > > > > > > > Quite accidentally, but I noticed the patch violates GNU coding > > > > style: > > > > > > > > $ git show 43a5d46feabd93ba78983919234f05f5fc9a0982 | > > > > ./contrib/check_GNU_style.py - > > > > > > > > === ERROR type #1: blocks of 8 spaces should be replaced with > > > > tabs > > > > (8 error(s)) === > > > > > > > > gcc/analyzer/engine.cc:3064:0:████████ that exceed it further. > > > > > > > > gcc/analyzer/engine.cc:3065:0:████████ This is something of a > > > > blunt > > > > workaround, but it only > > > > > > > > gcc/analyzer/engine.cc:3066:0:████████ applies to recursion > > > > (and > > > > mutual recursion), not to > > > > > > > > gcc/analyzer/engine.cc:3067:0:████████ general call stacks.  */ > > > > > > > > gcc/analyzer/engine.cc:3069:0:████████  > > > > > param_analyzer_max_recursion_depth) > > > > > > > > gcc/analyzer/engine.cc:3071:0:████████if (logger) > > > > > > > > gcc/analyzer/engine.cc:3072:0:████████  logger->log ("rejecting > > > > call edge: recursion limit exceeded"); > > > > > > > > gcc/analyzer/engine.cc:3073:0:████████return false; > > > > > > > > > > Looks like my editor again converted all the tabs to spaces. > > > > > > btw, I can also see a lot of other places where 8 spaces are not > > > begin converted to tabs, should I also change that accordingly or > > > leave them the way it is and just update this patch ? > > > > It's usually best to split out bugfixes from formatting/whitespace > > changes, so maybe do it as two patches: > > > > (1) an updated version of this patch to fix the recursion issue, > > using > > the correct whitespace for the lines that are touched > > unfortunately, I already checked in and pushed the changes to the > master before this was pointed out.  Fair enough. > But I can add them to the whitespace issue patch. Sounds good. Dave > > > > > (2) a patch that fixes whitespaces issues, but doesn't change the > > behavior of the code > > > > > > Dave >