Re: On disable_cost - Mailing list pgsql-hackers

From Alexander Lakhin
Subject Re: On disable_cost
Date
Msg-id a8abb84a-92bb-f2f1-4299-3efc21a7180f@gmail.com
Whole thread Raw
In response to Re: On disable_cost  (Richard Guo <guofenglinux@gmail.com>)
List 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



pgsql-hackers by date:

Previous
From: Nitin Motiani
Date:
Subject: Re: race condition in pg_class
Next
From: "Господарський суд Одеської області"
Date:
Subject: Господарський суд Одеської області -позовна заява