Re: How much slower are numerics? - Mailing list pgsql-general

From Jon Lapham
Subject Re: How much slower are numerics?
Date
Msg-id 435A4556.7020606@jandr.org
Whole thread Raw
In response to Re: How much slower are numerics?  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: How much slower are numerics?
List pgsql-general
Tom Lane wrote:
> On modern hardware, I'd expect float operations to be at least an order
> of magnitude faster than numerics
> [snip]
> regression$# declare x float8 := 0;
> regression=# select timeit(1000000);
> Time: 13700.960 ms
 > [snip]
> regression$# declare x numeric := 0;
> regression=# select timeit(1000000);
> Time: 22145.408 ms

But, this is less than a factor of 2 difference, similar to what one of
the previous INSERT examples showed.  Or am I missing something?

--
-**-*-*---*-*---*-*---*-----*-*-----*---*-*---*-----*-----*-*-----*---
  Jon Lapham  <lapham@jandr.org>                Rio de Janeiro, Brasil
  Personal: http://www.jandr.org/
***-*--*----*-------*------------*--------------------*---------------


pgsql-general by date:

Previous
From: Douglas McNaught
Date:
Subject: Re: pg_dump with low priority?
Next
From: David Busby
Date:
Subject: Large Table Performance