Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lTnBJ-0003P9-Ql for pgsql-committers@arkaria.postgresql.org; Tue, 06 Apr 2021 14:59:53 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lTnBI-0003x0-OG for pgsql-committers@arkaria.postgresql.org; Tue, 06 Apr 2021 14:59:52 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lTnBI-0003wt-Dw for pgsql-committers@lists.postgresql.org; Tue, 06 Apr 2021 14:59:52 +0000 Received: from mail-ed1-x532.google.com ([2a00:1450:4864:20::532]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1lTnBF-00084I-Mk for pgsql-committers@lists.postgresql.org; Tue, 06 Apr 2021 14:59:51 +0000 Received: by mail-ed1-x532.google.com with SMTP id w23so5708302edx.7 for ; Tue, 06 Apr 2021 07:59:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=enterprisedb-com.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=44fnLKtfHhgRMPAIEsGitWx6ZdSzzAhh/w9m71v+7GU=; b=fC6oy8CEmhorRCalsZE49zbczM/wMWR3aLYRxeiuVit20NJsTDJxPZ1MXyzIfe4VP/ gdRLI7Nsc668LkiyJ+NvZ4LZ1dRt4afWS0BsHcCx+eKJTrKc48hfL5rLVCyFvfYoxkcl HG4wTu2PrrChgfJZAMeMq/crBuopKDbDFP+x7oHw2AxwRJ8yVa1urGgzP+ivigLntjvV Q54UnaGH/gtpAXNjNBpcyYKK13Yv/R6Nq92APSSYcbAJvFzRE/7WJV8Ju5Z3RDAw/Jwe UWAdX/cvNat5yyxz3eWIdoq62bvOfzcmVz7T+/Zhkzgq0bV/xbR1WmxbqmZo/suYPf2C Fzew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=44fnLKtfHhgRMPAIEsGitWx6ZdSzzAhh/w9m71v+7GU=; b=gpWaoQvjvAMmPxUYUX0zjP26LFPPzq+h2NZwCdMQgmScM6OW5kQZ+p/ZHMGjawbJmm pUd46JuwXU/Uoqv2KPSBoh2Du7GOjnm9EkNPuAEi5wjM7rcI8Zun2yPGyRCZtVVH0LLi 6lhURi4/xApqggbYp0FAIj3PNm10+arBTP4836ia8jKp9wa/lrr3x62wkQ1/FGSpkBVL uqsTzSPdjcjm4ZmwtZf21hloultfJe15Tn0SuMHDYAep2C79SxqQE2shMSC9snzZ1LNl DDBz7+R9twZYIFOSARiKQe1N+yrb0MEZWzHZ5iPYZFa9MlpQ1pfclgvRNrX7Nte+BCWY qstg== X-Gm-Message-State: AOAM532ZsM9vFQxvGglUEJ0ycH6uwI1RxCrsafUtRHe1GuBw/hPBxhua flkh1gyu37hNb7nrhy0aqe0x5sRtCC8S/o3tA9mcchtuf5fjhzLIauba9CpKQPXS/0clfeuv0TN E1lxl4qTIQP3tyiwvdjKCLO0FsMuITbST6G+8DRlJ375YLueicSw9ZT2xOVIfGuPmUajf9592en psknet8uG4hNQv5ZkGL7hS2v/E8OxU/oe4X2BYLVOYfGIJhAf3irIay8f7V7v6mlNRT6qd8P2m2 AAex85SOCED/tyTzI+pW9KxdPn2L8tzQuCCnFHPB+1h0D4E78Ap+cQYfhXCGQ== X-Google-Smtp-Source: ABdhPJw+NanrT1iZQqDmtlxbz7YXDNopx5UmyOEJnY5TdpfJATUQH/sH0k1JWlcuFAGW+BisBUiIWg== X-Received: by 2002:aa7:c9d1:: with SMTP id i17mr37266474edt.46.1617721183241; Tue, 06 Apr 2021 07:59:43 -0700 (PDT) Received: from [10.137.0.20] (ip-86-49-253-127.net.upcbroadband.cz. [86.49.253.127]) by smtp.gmail.com with ESMTPSA id a22sm13893655edu.14.2021.04.06.07.59.42 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 06 Apr 2021 07:59:42 -0700 (PDT) Subject: Re: pgsql: Extended statistics on expressions To: David Rowley Cc: Alvaro Herrera , pgsql-committers@lists.postgresql.org References: <20210331170828.GA26795@alvherre.pgsql> <09dcc19c-f2ed-78ec-5c6a-cce32faa785e@enterprisedb.com> From: Tomas Vondra Message-ID: Date: Tue, 6 Apr 2021 16:59:38 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-CLOUD-SEC-AV-Info: enterprisedb,google_mail,monitor X-CLOUD-SEC-AV-Sent: true X-Gm-Spam: 0 X-Gm-Phishy: 0 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 4/1/21 4:24 AM, David Rowley wrote: > On Thu, 1 Apr 2021 at 14:49, Tomas Vondra wrote: >> I think that's probably sufficient for now. More testing may be useful >> once I refactor the code a bit to make it more readable. > > Just to let you know, I left it running a bit longer. About 70 mins > now. No crashes yet. > I've pushed a fix for this. I've reworked the loop where we apply the selected extended statistics, breaking the complex "if" condition into smaller / easier to understand pieces. regards -- Tomas Vondra EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company