[HACKERS] PostgreSQL 8.2 : warnings during the built with ICC 9.1.045

2006-12-14 Thread DANTE Alexandra

Hello List,

I try to post this e-mail on this list, as nobody answers me on 
pgsql-general :-(
I work with an IA-64 server with Red Hat Enterprise Linux 4 AS update 2 
on which the Intel compiler icc 9.1.045 is available and I build 
PostgreSQL 8.2 with this compiler.
To do that I generated RPM from the "postgresql-8.2.0-2PGDG.src.rpm" 
with the command "rpmbuild -ba postgresql-8.2.spec"


I noticed a lot of warnings in the log of the "rpmbuild -ba" command.
I put below some of these warnings :
parse_expr.c(2066): warning #188: enumerated type mixed with another type
  rctype = 0; /* keep compiler 
quiet */


../../../../src/include/storage/s_lock.h(246): warning #167: argument of 
type "volatile slock_t={unsigned int} *" is incompatible with parameter 
of type "void *"
  ret = _InterlockedExchange(lock,1); /* this is a xchg asm 
macro */


hba.c(1476): warning #167: argument of type "int *" is incompatible with 
parameter of type "socklen_t={__socklen_t={unsigned int}} *restrict"
  if (getsockopt(sock, SOL_SOCKET, SO_PEERCRED, &peercred, &so_len) 
!= 0 ||


regc_locale.c(358): warning #186: pointless comparison of unsigned 
integer with zero

  return (c >= 0 && c <= UCHAR_MAX && isdigit((unsigned char) c));

dfmgr.c(117): warning #556: a value of type "void *" cannot be assigned 
to an entity of type "PGFunction"

  retval = pg_dlsym(lib_handle, funcname);
 ^
dfmgr.c(165): warning #120: return value type does not match the 
function type

  return pg_dlsym(filehandle, funcname);

fe-misc.c(167): warning #186: pointless comparison of unsigned integer 
with zero

  if (len < 0 || len > (size_t) (conn->inEnd - conn->inCursor))

mbuf.c(45): warning #108: implicitly-signed bit field of length 1
  int no_write:1;

These numbers of warning (#188, #167, #186, #556, #120, #186, #108) 
represent all the warrnings contained in the log file.


Could someone tell me if these warnings can have a negative impact on 
the performances of PostgreSQL ?


Thank you in advance.
Regards,
Alexandra DANTE

---(end of broadcast)---
TIP 4: Have you searched our list archives?

  http://archives.postgresql.org


Re: [HACKERS] PostgreSQL 8.2 : regression failures on IA-64

2006-12-12 Thread DANTE Alexandra

Thank you very much : it works 
-bash-3.00$ gmake check 2>&1 |tee traces_check8.2.0_gcc_121206_v2.log
... ... ...
test create_function_1... ok
triggers ... ok
... ... ...
===
All 103 tests passed.
===

The problems were those you found :
- I replaced AS '@abs_spidir@/[EMAIL PROTECTED]@' by AS 
'@abs_spidir@/[EMAIL PROTECTED]@'

- I added ' at lines 58, 63, 68

By doing this, the regression tests are OK !
Regards,
Alexandra

Tatsuhito Kasahara wrote:


Hi!

I think this was caused by a description mistake of 
"postgresql-test.patch".


> 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so 


>
>   LANGUAGE C;
> CREATE FUNCTION check_foreign_key ()
>   RETURNS trigger
> ! AS
> 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so 


>
>   LANGUAGE C;
> CREATE FUNCTION autoinc ()
>   RETURNS trigger
> ! AS
> 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so 


Single quotes (') of end of line is insufficient.


> CREATE FUNCTION autoinc ()
>   RETURNS trigger
> ! AS
> 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so 


We have to use "autoinc.so". (not "refint.so")

# And You had better fix 
"/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regress/" 
and
  
"/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/" 


  in "/usr/lib/pgsql/test/regress/".

best regards.

DANTE Alexandra wrote:


Hello List,

I have already posted an e-mail on the general mailing list but on 
the advice of Devrim Gunduz ;-) , I try on this mailing list.
I try to generate the RPM from the src.rpm downloaded on the 
postgresql.org web site. I work on an IA-64 server with Red Hat 
Enterprise Linux 4 AS update 2.

As root, the first command I launched was :
[EMAIL PROTECTED] SOURCES]# rpm -i postgresql-8.2.0-2PGDG.src.rpm
[EMAIL PROTECTED] SOURCES]# ls -ltr ../SPECS
total 28
-rw-r--r--  1 root root 24840 Dec  5 06:04 postgresql-8.2.spec
[EMAIL PROTECTED] SOURCES]# ls -ltr
total 24176
-rw-r--r--  1 root root 12459207 Dec  2 20:25 postgresql-8.2.0.tar.bz2
-rw-r--r--  1 root root  897 Dec  2 20:28 pg_config.h
-rw-r--r--  1 root root 1539 Dec  2 20:28 Makefile.regress
-rwxr-xr-x  1 root root   56 Dec  2 20:28 filter-requires-perl-Pg.sh
-rw-r--r--  1 root root 1631 Dec  2 20:28 postgresql-logging.patch
-rw-r--r--  1 root root 7529 Dec  2 20:28 postgresql.init
-rw-r--r--  1 root root   85 Dec  2 20:28 postgresql-bashprofile
-rw-r--r--  1 root root 1757 Dec  2 20:28 rpm-pgsql.patch
-rw-r--r--  1 root root15598 Dec  2 20:28 README.rpm-dist
-rw-r--r--  1 root root 2563 Dec  2 20:28 postgresql-test.patch
-rw-r--r--  1 root root  919 Dec  2 20:28 
postgresql-perl-rpath.patch

-rw-r--r--  1 root root  141 Dec  2 20:28 postgresql.pam
-rw-r--r--  1 root root 12198114 Dec  6 17:18 
postgresql-8.2.0-2PGDG.src.rpm


Then from the SPECS directory, with the spec file that you can find 
attached, I launched as root :

rpmbuild -ba postgresql-8.2.spec

Then, as root, I changed the access to these directories :
root# chmod -R a+w src/test/regress
root# chmod -R a+w contrib/spi

And as postgres, I launched the regression tests.
root# su - postgres
-bash-3.00$ gmake check
The tests for create_function_1 and triggers fail...
test create_function_1... FAILED
... ... ...
triggers ... FAILED

I see at 
http://archives.postgresql.org/pgsql-ports/2006-11/msg00011.php that 
this problem already appear on 64 bits but I am note sure that it is 
the same problem...



You can find attach the files "regression.diff" and "regression.out"
In the file "regression.diff", my first problem seems to be linked 
with the function "autoinc()" :

*** ./expected/create_function_1.outThu Dec  7 14:37:28 2006
--- ./results/create_function_1.outThu Dec  7 14:41:21 2006
***
*** 25,40 
NOTICE:  argument type city_budget is only a shell
CREATE FUNCTION check_primary_key ()
  RETURNS trigger
! AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so 


  LANGUAGE C;
CREATE FUNCTION check_foreign_key ()
  RETURNS trigger
! AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so 


  LANGUAGE C;
CREATE FUNCTION autoinc ()
  RETURNS trigger
! AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so 


  LANGUAGE C;
CREATE FUNCTION funny_dup17 ()
  RETURNS trigger
  AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8

[HACKERS] PostgreSQL 8.2 : regression failures on IA-64

2006-12-12 Thread DANTE Alexandra

Hello List,

I have already posted an e-mail on the general mailing list but on the 
advice of Devrim Gunduz ;-) , I try on this mailing list.
I try to generate the RPM from the src.rpm downloaded on the 
postgresql.org web site. I work on an IA-64 server with Red Hat 
Enterprise Linux 4 AS update 2.

As root, the first command I launched was :
[EMAIL PROTECTED] SOURCES]# rpm -i postgresql-8.2.0-2PGDG.src.rpm
[EMAIL PROTECTED] SOURCES]# ls -ltr ../SPECS
total 28
-rw-r--r--  1 root root 24840 Dec  5 06:04 postgresql-8.2.spec
[EMAIL PROTECTED] SOURCES]# ls -ltr
total 24176
-rw-r--r--  1 root root 12459207 Dec  2 20:25 postgresql-8.2.0.tar.bz2
-rw-r--r--  1 root root  897 Dec  2 20:28 pg_config.h
-rw-r--r--  1 root root 1539 Dec  2 20:28 Makefile.regress
-rwxr-xr-x  1 root root   56 Dec  2 20:28 filter-requires-perl-Pg.sh
-rw-r--r--  1 root root 1631 Dec  2 20:28 postgresql-logging.patch
-rw-r--r--  1 root root 7529 Dec  2 20:28 postgresql.init
-rw-r--r--  1 root root   85 Dec  2 20:28 postgresql-bashprofile
-rw-r--r--  1 root root 1757 Dec  2 20:28 rpm-pgsql.patch
-rw-r--r--  1 root root15598 Dec  2 20:28 README.rpm-dist
-rw-r--r--  1 root root 2563 Dec  2 20:28 postgresql-test.patch
-rw-r--r--  1 root root  919 Dec  2 20:28 postgresql-perl-rpath.patch
-rw-r--r--  1 root root  141 Dec  2 20:28 postgresql.pam
-rw-r--r--  1 root root 12198114 Dec  6 17:18 
postgresql-8.2.0-2PGDG.src.rpm


Then from the SPECS directory, with the spec file that you can find 
attached, I launched as root :

rpmbuild -ba postgresql-8.2.spec

Then, as root, I changed the access to these directories :
root# chmod -R a+w src/test/regress
root# chmod -R a+w contrib/spi

And as postgres, I launched the regression tests.
root# su - postgres
-bash-3.00$ gmake check
The tests for create_function_1 and triggers fail...
test create_function_1... FAILED
... ... ...
triggers ... FAILED

I see at http://archives.postgresql.org/pgsql-ports/2006-11/msg00011.php 
that this problem already appear on 64 bits but I am note sure that it 
is the same problem...



You can find attach the files "regression.diff" and "regression.out"
In the file "regression.diff", my first problem seems to be linked with 
the function "autoinc()" :

*** ./expected/create_function_1.outThu Dec  7 14:37:28 2006
--- ./results/create_function_1.outThu Dec  7 14:41:21 2006
***
*** 25,40 
NOTICE:  argument type city_budget is only a shell
CREATE FUNCTION check_primary_key ()
  RETURNS trigger
! AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so 


  LANGUAGE C;
CREATE FUNCTION check_foreign_key ()
  RETURNS trigger
! AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so 


  LANGUAGE C;
CREATE FUNCTION autoinc ()
  RETURNS trigger
! AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so 


  LANGUAGE C;
CREATE FUNCTION funny_dup17 ()
  RETURNS trigger
  AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regress/regress.so' 


--- 25,41 
NOTICE:  argument type city_budget is only a shell
CREATE FUNCTION check_primary_key ()
  RETURNS trigger
! AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so' 


  LANGUAGE C;
CREATE FUNCTION check_foreign_key ()
  RETURNS trigger
! AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so' 


  LANGUAGE C;
CREATE FUNCTION autoinc ()
  RETURNS trigger
! AS 
'/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so' 


  LANGUAGE C;
*+ ERROR:  could not find function "autoinc" in file 
"/SLONY_PGS/PostgreSQL_8.2.0/BUILD/postgresql-8.2.0/src/test/regres/../../../contrib/spi/refint.so"* 



I checked the file "contrib/spi/refint.c" : it does not contain a 
function called autoinc...


The two others errors reported in "regression.diff" are :
delete from tttest where price_id = 2;
select * from tttest;
price_id | price_val | price_on | price_off
--+---+--+---
! 1 | 1 |   10 |99
! 3 | 3 |   30 |99
! 2 | 2 |   20 |40
(3 rows)

-- what do we see ?
--- 150,175 
  for each row
  execute procedure
  autoinc (price_on, ttdummy_seq);
*+ ERROR:  function autoinc() does not exist*
insert into tttest values (1, 1, null);
insert into tttest values (2, 2, null);
insert into tttest values (3, 3, 0);
select * from tttest;
price_id | price_val | price_on | price_off
--+---+--+---
! 1 | 1 |  |99
! 2 | 2 |  |99
! 3 | 3 |0 |99
(3 rows)

delete from tttest where price_id = 2;
*+ ERROR:  ttdummy (tttest): pric