From: | "Robert E(dot) Bruccoleri" <bruc(at)stone(dot)congenomics(dot)com> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Regression failure with PostgreSQL 8beta1 and Intel Itanium 2 C compiler |
Date: | 2004-08-10 23:12:22 |
Message-ID: | 200408102312.i7ANCMA1163657@stone.congenomics.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs pgsql-hackers |
Dear All,
I built PG 8.0 beta1 on an Itanium 2 platform using the Intel compilers
version 8, and got one real difference in the regression tests that affected
int2, int4, union, and numerology. Here's the key difference:
horta postgres 177 > diff -c int4.out ../expected/
*** int4.out Tue Aug 10 18:41:48 2004
--- ../expected/int4.out Wed Mar 10 21:11:13 2004
***************
*** 22,27 ****
--- 22,28 ----
INSERT INTO INT4_TBL(f1) VALUES (' asdf ');
ERROR: invalid input syntax for integer: " asdf "
INSERT INTO INT4_TBL(f1) VALUES ('- 1234');
+ ERROR: invalid input syntax for integer: "- 1234"
INSERT INTO INT4_TBL(f1) VALUES ('123 5');
ERROR: invalid input syntax for integer: "123 5"
INSERT INTO INT4_TBL(f1) VALUES ('');
PG 8.0 beta1 is accepting "- 1234" as a valid integer. Further investigation
reveals that this is a peculiarity of the Intel compilers. The following
program,
#include <stdio.h>
#include <stdlib.h>
main() {
char st[] = "- 1234";
int l;
char *endp;
l = strtol(st, &endp, 10);
printf("l = %d st = %lx endp = %lx\n", l, st, endp);
}
using the Intel compiler provided libraries prints
l = -1234 st = 60000fffffffb720 endp = 60000fffffffb726
whereas gcc and glibc yields
l = 0 st = 60000fffffffb710 endp = 60000fffffffb710
Boo hiss...
+-----------------------------+------------------------------------+
| Robert E. Bruccoleri, Ph.D. | email: bruc(at)acm(dot)org |
| President, Congenair LLC | URL: http://www.congen.com/~bruc |
| P.O. Box 314 | Phone: 609 818 7251 |
| Pennington, NJ 08534 | |
+-----------------------------+------------------------------------+
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Fuhr | 2004-08-11 00:08:33 | Re: SOLARIS 9 ULTRASPARC BUILD |
Previous Message | Gaetano Mendola | 2004-08-10 22:49:18 | Re: Installation of PostgreSQL |
From | Date | Subject | |
---|---|---|---|
Next Message | Cason, Kenny | 2004-08-11 00:21:26 | Looking for C++ bytea example |
Previous Message | Tom Lane | 2004-08-10 23:06:31 | Re: Add Missing From? |