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 1nA82x-0006XG-HK for pgsql-hackers@arkaria.postgresql.org; Wed, 19 Jan 2022 10:18:31 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nA82u-0005CA-TY for pgsql-hackers@arkaria.postgresql.org; Wed, 19 Jan 2022 10:18:28 +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 1nA82u-0005AA-HW for pgsql-hackers@lists.postgresql.org; Wed, 19 Jan 2022 10:18:28 +0000 Received: from mail-pg1-x536.google.com ([2607:f8b0:4864:20::536]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1nA82p-0003fJ-HC for pgsql-hackers@postgresql.org; Wed, 19 Jan 2022 10:18:27 +0000 Received: by mail-pg1-x536.google.com with SMTP id r11so1982465pgr.6 for ; Wed, 19 Jan 2022 02:18:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=l2F2wjGDg+UHeuB7scxYLSFAoohDD6VmC0oYAUWFZGY=; b=mJvwkzwwAfS53nktG1ong30ZToUvozdEAQv5nFGMTYDwWE62Mfc7KKFqNm1gv0GdeT PrHpmmdKJ58eJn2Fb/uzTRa1xqUZ0/jUl9q1t4YeynAyN1oAWXVNccNP/Y/vH/sOt4iC FtyMwhmqrjOwDSjnZkHnO/ygxnMprogI2sCsfBXgT5NwO16G88+WsV4WInyj6z5TOTdc AHjHfsVCIE4D+zOdGguIUIvPNl6ilDlcVAs3exq40UMPQyMLWlk/n2urOqVlwZFPUupx j55AWT13LmXVVWtkqF2EIxnpS71DGTbj6zjj1Rcf+Na21b41CUM9kuAaZvHaa6lqE8ww MA4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=l2F2wjGDg+UHeuB7scxYLSFAoohDD6VmC0oYAUWFZGY=; b=IWR0/7K+GlAbhrrrP1mCvbxmJBQMPae6OctniltzGMm5ukZ3uTcQ+L/w+3pPl2HAGx c6CebbAFUmYrO/RBNduKhKzDNXJpwsTX4SKyZ5PUKDDQuHiEVY6M2xG7lIEd33xFoUPX csx0nD2A4vN7jTz4Vgvupv2nILGp+L7gfGJnQilqP3pLeqOeyrbaU0OYwn434mvKsztq CWAAEtXmV8LT15rQf4H1CRAVFikVvDFoam7zyqHKySHKKtyhptaqWuzK/7xizivxGt+M BCelQBHyHxIDjHr6r8ajAOskhGGT6TQrlILtmd8N3bCC7uBekMquJBLJqsJ6oxgP1TML IyfA== X-Gm-Message-State: AOAM533tjehN84AdXYEr+biRLxOssNNo00+gyFiytLuDvjc9WZf6XfKQ yqlSR27l4mfF6l0phcCCjZ4= X-Google-Smtp-Source: ABdhPJzxUHuQLNlqZnRCzpJi6BirxVyzcK2x6oTfoKpItYpTvCCeGS6IOByjHGY7qcBApGtk+REvEw== X-Received: by 2002:a63:fd53:: with SMTP id m19mr26101537pgj.563.1642587501161; Wed, 19 Jan 2022 02:18:21 -0800 (PST) Received: from jrouhaud (1-171-184-213.dynamic-ip.hinet.net. [1.171.184.213]) by smtp.gmail.com with ESMTPSA id j8sm5632061pjb.19.2022.01.19.02.18.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 19 Jan 2022 02:18:20 -0800 (PST) Date: Wed, 19 Jan 2022 18:18:09 +0800 From: Julien Rouhaud To: Andres Freund Cc: Tomas Vondra , Justin Pryzby , pgsql-hackers@postgresql.org Subject: Re: using extended statistics to improve join estimates Message-ID: <20220119101809.wzrjvh4jsnoakgny@jrouhaud> References: <2ed75657-e084-9539-c6de-597e5675014c@enterprisedb.com> <20211122012315.GH17618@telsasoft.com> <0213d237-efd5-8e7e-fa29-3f36e6e26023@enterprisedb.com> <1ea3bf2b-57f9-e632-251a-e718623d7a72@enterprisedb.com> <20220104235550.dgr4rz6zkjx2rykz@alap3.anarazel.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220104235550.dgr4rz6zkjx2rykz@alap3.anarazel.de> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi, On Tue, Jan 04, 2022 at 03:55:50PM -0800, Andres Freund wrote: > On 2022-01-01 18:21:06 +0100, Tomas Vondra wrote: > > Here's an updated patch, rebased and fixing a couple typos reported by > > Justin Pryzby directly. > > FWIW, cfbot reports a few compiler warnings: Also the patch doesn't apply anymore: http://cfbot.cputube.org/patch_36_3055.log === Applying patches on top of PostgreSQL commit ID 74527c3e022d3ace648340b79a6ddec3419f6732 === === applying patch ./0001-Estimate-joins-using-extended-statistics-20220101.patch patching file src/backend/optimizer/path/clausesel.c patching file src/backend/statistics/extended_stats.c Hunk #1 FAILED at 30. Hunk #2 succeeded at 102 (offset 1 line). Hunk #3 succeeded at 2619 (offset 9 lines). 1 out of 3 hunks FAILED -- saving rejects to file src/backend/statistics/extended_stats.c.rej