Re: On disable_cost

From: Alexander Lakhin <exclusion(at)gmail(dot)com>
To: Richard Guo <guofenglinux(at)gmail(dot)com>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, David Rowley <dgrowleyml(at)gmail(dot)com>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>, Peter Geoghegan <pg(at)bowt(dot)ie>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: On disable_cost
Date: 2024-09-06 10:10:10
Message-ID: a8abb84a-92bb-f2f1-4299-3efc21a7180f@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hello Richard,

06.09.2024 12:51, Richard Guo wrote:
> Ah I see. label_sort_with_costsize is only used to label the Sort
> node nicely for EXPLAIN, and usually we do not display the cost
> numbers in regression tests.

In fact, I see the error with the following (EXPLAIN-less) query:
create table t (x int);

select * from t natural inner join
(select * from (values(1)) v(x)
  union all
 select 1 from t t1 full join t t2 using (x),
               t t3 full join t t4 using (x)
);

2024-09-06 10:01:48.034 UTC [696535:5] psql LOG:  statement: select * from t natural inner join
    (select * from (values(1)) v(x)
      union all
     select 1 from t t1 full join t t2 using (x),
                   t t3 full join t t4 using (x)
    );
createplan.c:5457:6: runtime error: 4.99254e+09 is outside the range of representable values of type 'int'
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior createplan.c:5457:6 in

(An UBSan-enabled build --with-blocksize=32 is required for this query to
trigger the failure.)

Best regards,
Alexander

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Господарський суд Одеської області 2024-09-06 10:29:19 Господарський суд Одеської області -позовна заява
Previous Message Nitin Motiani 2024-09-06 09:52:48 Re: race condition in pg_class