PostgreSLQ v10.1 and xlC compiler on AIX
Hi,
We are porting PostgreSQL v10.1 on AIX (7.2 for now).
And we have several tests failures, in 32bit and 64bit.
We are using xlc 13.01.0003.0003 with -O2.
Tests were 100% OK with version 9.6.2 .
About 32 bit failures within v10.1, we have 3 failures including:
create_aggregate ... FAILED
aggregates ... FAILED
I've found that these 2 failures disappear when building :
./src/backend/parser/gram.c
without -O2 !
However, this is a 44,498 lines file and it may take a while for finding the root issue.
I invite anyone involved in porting/using PostgreSQL 10.1 on AIX to take part of a discussion about how to make v10.1 work perfectly on AIX.
Regards,
Cordialement,
Tony Reix
Bull - ATOS
IBM Coop Architect & Technical Leader
Office : +33 (0) 4 76 29 72 67
1 rue de Provence - 38432 Échirolles - France
www.atos.net<http://www.atos.net/>
On Thu, Nov 23, 2017 at 7:57 PM, REIX, Tony <tony.reix@atos.net> wrote:
We are porting PostgreSQL v10.1 on AIX (7.2 for now).
And we have several tests failures, in 32bit and 64bit.
We are using xlc 13.01.0003.0003 with -O2.
Tests were 100% OK with version 9.6.2 .About 32 bit failures within v10.1, we have 3 failures including:
create_aggregate ... FAILED
aggregates ... FAILEDI've found that these 2 failures disappear when building :
./src/backend/parser/gram.c
without -O2 !
However, this is a 44,498 lines file and it may take a while for finding the
root issue.
When running regression tests and those fail, there is a file called
regressions.diff which gets generated in src/test/regress showing the
difference between the results generated and the results expected when
running the SQL queries which are part of the regression tests.
Attaching this file to this thread would help in determining what's
wrong with the regression tests.
I invite anyone involved in porting/using PostgreSQL 10.1 on AIX to take
part of a discussion about how to make v10.1 work perfectly on AIX.
Note that xlc 12.1 is tested with AIX machines on the buildfarms, but
there is no coverage for 13.1 visibly. It would be nice if you could
set up a buildfarm machine to catch problems way earlier.
--
Michael
Michael Paquier wrote:
On Thu, Nov 23, 2017 at 7:57 PM, REIX, Tony <tony.reix@atos.net> wrote:
I invite anyone involved in porting/using PostgreSQL 10.1 on AIX to take
part of a discussion about how to make v10.1 work perfectly on AIX.Note that xlc 12.1 is tested with AIX machines on the buildfarms, but
there is no coverage for 13.1 visibly. It would be nice if you could
set up a buildfarm machine to catch problems way earlier.
Other problems have been reported, too; see
/messages/by-id/2fc764c7-2222-83e3-45c2-33c17853e13f@atos.net
and others in the thread.
The fact that a problem goes away when the compile doesn't have -O2
suggests a compiler bug.
--
�lvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Hi Michael,
Thanks for the information ! I'm not a PostgreSQL expert.
I've found the file: ./32bit/src/test/regress/regression.diffs
Since I'm rebuilding right now, I do not have just now the file for v10.1 with the issue.
However, I have it for 10.0 and 9.6.6 which show the same issues. I've attached them to this email.
About the suggestion of adding a AIX machine with xlc v13.1 to the buildfarm, I'll see how this could be done.
Also, I'll try to get a more recent version of xlC v13 .
Cordialement,
Tony Reix
Bull - ATOS
IBM Coop Architect & Technical Leader
Office : +33 (0) 4 76 29 72 67
1 rue de Provence - 38432 Échirolles - France
www.atos.net
________________________________________
De : Michael Paquier [michael.paquier@gmail.com]
Envoyé : jeudi 23 novembre 2017 14:08
À : REIX, Tony
Cc : PostgreSQL Hackers; OLIVA, PASCAL
Objet : Re: PostgreSLQ v10.1 and xlC compiler on AIX
On Thu, Nov 23, 2017 at 7:57 PM, REIX, Tony <tony.reix@atos.net> wrote:
We are porting PostgreSQL v10.1 on AIX (7.2 for now).
And we have several tests failures, in 32bit and 64bit.
We are using xlc 13.01.0003.0003 with -O2.
Tests were 100% OK with version 9.6.2 .About 32 bit failures within v10.1, we have 3 failures including:
create_aggregate ... FAILED
aggregates ... FAILEDI've found that these 2 failures disappear when building :
./src/backend/parser/gram.c
without -O2 !
However, this is a 44,498 lines file and it may take a while for finding the
root issue.
When running regression tests and those fail, there is a file called
regressions.diff which gets generated in src/test/regress showing the
difference between the results generated and the results expected when
running the SQL queries which are part of the regression tests.
Attaching this file to this thread would help in determining what's
wrong with the regression tests.
I invite anyone involved in porting/using PostgreSQL 10.1 on AIX to take
part of a discussion about how to make v10.1 work perfectly on AIX.
Note that xlc 12.1 is tested with AIX machines on the buildfarms, but
there is no coverage for 13.1 visibly. It would be nice if you could
set up a buildfarm machine to catch problems way earlier.
--
Michael
Attachments:
regression.diffs-10.0.xlcV13application/octet-stream; name=regression.diffs-10.0.xlcV13Download
*** /home2/freeware/src/packages/BUILD/postgresql-10.0/32bit/src/test/regress/expected/create_aggregate.out Mon Oct 2 16:09:15 2017
--- /home2/freeware/src/packages/BUILD/postgresql-10.0/32bit/src/test/regress/results/create_aggregate.out Thu Nov 9 15:43:52 2017
***************
*** 85,95 ****
alter aggregate my_rank(VARIADIC "any" ORDER BY VARIADIC "any")
rename to test_rank;
\da test_*
! List of aggregate functions
! Schema | Name | Result data type | Argument data types | Description
! --------+----------------------+------------------+----------------------------------------+-------------
! public | test_percentile_disc | anyelement | double precision ORDER BY anyelement |
! public | test_rank | bigint | VARIADIC "any" ORDER BY VARIADIC "any" |
(2 rows)
-- moving-aggregate options
--- 85,95 ----
alter aggregate my_rank(VARIADIC "any" ORDER BY VARIADIC "any")
rename to test_rank;
\da test_*
! List of aggregate functions
! Schema | Name | Result data type | Argument data types | Description
! --------+----------------------+------------------+--------------------------------------------------+-------------
! public | test_percentile_disc | anyelement | double precision, anyelement ORDER BY anyelement |
! public | test_rank | bigint | VARIADIC "any" ORDER BY VARIADIC "any" |
(2 rows)
-- moving-aggregate options
======================================================================
*** /home2/freeware/src/packages/BUILD/postgresql-10.0/32bit/src/test/regress/expected/aggregates.out Mon Oct 2 16:09:15 2017
--- /home2/freeware/src/packages/BUILD/postgresql-10.0/32bit/src/test/regress/results/aggregates.out Thu Nov 9 15:43:55 2017
***************
*** 1634,1644 ****
(1 row)
select test_percentile_disc(0.5) within group (order by thousand) from tenk1;
! test_percentile_disc
! ----------------------
! 499
! (1 row)
!
-- ordered-set aggs can't use ungrouped vars in direct args:
select rank(x) within group (order by x) from generate_series(1,5) x;
ERROR: column "x.x" must appear in the GROUP BY clause or be used in an aggregate function
--- 1634,1643 ----
(1 row)
select test_percentile_disc(0.5) within group (order by thousand) from tenk1;
! ERROR: function test_percentile_disc(numeric, integer) does not exist
! LINE 1: select test_percentile_disc(0.5) within group (order by thou...
! ^
! HINT: There is an ordered-set aggregate test_percentile_disc, but it requires 2 direct arguments, not 1.
-- ordered-set aggs can't use ungrouped vars in direct args:
select rank(x) within group (order by x) from generate_series(1,5) x;
ERROR: column "x.x" must appear in the GROUP BY clause or be used in an aggregate function
======================================================================
regression.diffs-9.6.6.xlcV13application/octet-stream; name=regression.diffs-9.6.6.xlcV13Download
*** /home2/freeware/src/packages/BUILD/postgresql-9.6.6/32bit/src/test/regress/expected/create_aggregate.out Mon Nov 6 16:08:55 2017
--- /home2/freeware/src/packages/BUILD/postgresql-9.6.6/32bit/src/test/regress/results/create_aggregate.out Thu Nov 23 13:28:04 2017
***************
*** 85,95 ****
alter aggregate my_rank(VARIADIC "any" ORDER BY VARIADIC "any")
rename to test_rank;
\da test_*
! List of aggregate functions
! Schema | Name | Result data type | Argument data types | Description
! --------+----------------------+------------------+----------------------------------------+-------------
! public | test_percentile_disc | anyelement | double precision ORDER BY anyelement |
! public | test_rank | bigint | VARIADIC "any" ORDER BY VARIADIC "any" |
(2 rows)
-- moving-aggregate options
--- 85,95 ----
alter aggregate my_rank(VARIADIC "any" ORDER BY VARIADIC "any")
rename to test_rank;
\da test_*
! List of aggregate functions
! Schema | Name | Result data type | Argument data types | Description
! --------+----------------------+------------------+--------------------------------------------------+-------------
! public | test_percentile_disc | anyelement | double precision, anyelement ORDER BY anyelement |
! public | test_rank | bigint | VARIADIC "any" ORDER BY VARIADIC "any" |
(2 rows)
-- moving-aggregate options
======================================================================
*** /home2/freeware/src/packages/BUILD/postgresql-9.6.6/32bit/src/test/regress/expected/aggregates.out Mon Nov 6 16:08:55 2017
--- /home2/freeware/src/packages/BUILD/postgresql-9.6.6/32bit/src/test/regress/results/aggregates.out Thu Nov 23 13:28:07 2017
***************
*** 1631,1641 ****
(1 row)
select test_percentile_disc(0.5) within group (order by thousand) from tenk1;
! test_percentile_disc
! ----------------------
! 499
! (1 row)
!
-- ordered-set aggs can't use ungrouped vars in direct args:
select rank(x) within group (order by x) from generate_series(1,5) x;
ERROR: column "x.x" must appear in the GROUP BY clause or be used in an aggregate function
--- 1631,1640 ----
(1 row)
select test_percentile_disc(0.5) within group (order by thousand) from tenk1;
! ERROR: function test_percentile_disc(numeric, integer) does not exist
! LINE 1: select test_percentile_disc(0.5) within group (order by thou...
! ^
! HINT: There is an ordered-set aggregate test_percentile_disc, but it requires 2 direct arguments, not 1.
-- ordered-set aggs can't use ungrouped vars in direct args:
select rank(x) within group (order by x) from generate_series(1,5) x;
ERROR: column "x.x" must appear in the GROUP BY clause or be used in an aggregate function
======================================================================