Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dNhgH-0002PR-LN for pgsql-bugs@arkaria.postgresql.org; Wed, 21 Jun 2017 15:36:34 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dNhgG-0004P7-4i for pgsql-bugs@arkaria.postgresql.org; Wed, 21 Jun 2017 15:36:32 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dNhXD-0001da-EV for pgsql-bugs@postgresql.org; Wed, 21 Jun 2017 15:27:12 +0000 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dNhX9-0001RH-W7 for pgsql-bugs@postgresql.org; Wed, 21 Jun 2017 15:27:10 +0000 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id C236320A69; Wed, 21 Jun 2017 11:27:06 -0400 (EDT) Received: from frontend1 ([10.202.2.160]) by compute5.internal (MEProxy); Wed, 21 Jun 2017 11:27:06 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=turelinckx.be; h=content-transfer-encoding:content-type:date:from:message-id :mime-version:subject:to:x-me-sender:x-me-sender:x-sasl-enc :x-sasl-enc; s=mesmtp; bh=3S7/DjpW+qBD0NK6FbkAFhdyxqoRNoI/VmrgQ2 qCCSU=; b=DQUtrm1UqOQ6ujkdK8rmQMlR/SIaFJuMrJD3dHESz0wsYiknTjHwUG Jn1fTh9Iz/QECfwxpfdTqiqNWAdS61FcuCjmFpDLNmHEPrCBNGCFJ4LnFPkuZvo8 7GJo3jBOxgPnCJGoJc0GxUgE1EcZA260gPTp5CDTN9iWdJ1IZbrBM= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:message-id:mime-version:subject:to:x-me-sender :x-me-sender:x-sasl-enc:x-sasl-enc; s=fm1; bh=3S7/DjpW+qBD0NK6Fb kAFhdyxqoRNoI/VmrgQ2qCCSU=; b=nzOpU2HM++xwZwSA/eVShY5PBI9brPSA1u MIznM5/lTE7uL/tXX+dSM3bR2LHt2swlXga8IjkjQ+2bwnhW2ObCh9r2TZHdCWJB YzKIGXFNHhZtJpbwAGm92QAi6P6wnqCcm4/qlwRRChIM3b7YoPakP86+feU+IHpj gaSq+kd5pGk94UJ0dSyEVR9vupZSwb1ZhqM5jLbXHnfo9aj/XHXO0PasgTWD0+dx NmxhDebGN05cFGVafFK8Z0v+IOvhPcGkJODY4YOOAxBE7J0//jcEEt0X5yHvczxn pyOl/pz5ZQNKxPMhozgttgnGGmTxp0/YRszEs+BggzlkvqOcoyow== X-ME-Sender: X-Sasl-enc: uqq8e4KRr+QYfg2Mvi2D48EgVCxMavp3YvWIyxNcwiuU 1498058825 Received: from tureltolaptop (213.219.188.53.adsl.dyn.edpnet.net [213.219.188.53]) by mail.messagingengine.com (Postfix) with ESMTPA id C0DB47E74F for ; Wed, 21 Jun 2017 11:27:05 -0400 (EDT) From: "Tom Turelinckx" To: Subject: Bus error in formatting.c NUM_numpart_to_char (9.4.12, 9.6.3, sparc) Date: Wed, 21 Jun 2017 17:26:59 +0200 Message-ID: <006b01d2eaa2$d4317be0$7c9473a0$@turelinckx.be> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 14.0 Thread-Index: AdLqojEcXNlV9ktvRGi9JADYAz2+tw== Content-Language: en-us List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org Hi, I was trying to compile 9.4.12 on sparc from the debian source package in t= he pgdg repo, but it's failing multiple regression tests. One numeric test = crashes the backend: LOG: server process (PID 20659) was terminated by signal 10: Bus error DETAIL: Failed process was running: SELECT '' AS to_char_6, to_char(val, = 'FMS9999999999999999.999999999999999') FROM num_data; Reading symbols from /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/src/= backend/postgres...done. [New LWP 20659] [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/sparc-linux-gnu/libthread_db.so.1". Core was generated by `postgres: turelto regression [local] SELECT = '. Program terminated with signal 10, Bus error. #0 NUM_numpart_to_char (id=3D3, Np=3D0xffa04a54) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/uti= ls/adt/formatting.c:4419 4419 if (Np->Num->lsign =3D=3D NUM_LSIGN_PRE) (gdb) l 4414 (Np->num_curr >=3D Np->out_pre_spaces || (IS_ZERO(N= p->Num) && Np->Num->zero_start =3D=3D Np->num_curr)) && 4415 (IS_PREDEC_SPACE(Np) =3D=3D FALSE || (Np->last_rele= vant && *Np->last_relevant =3D=3D '.'))) 4416 { 4417 if (IS_LSIGN(Np->Num)) 4418 { 4419 if (Np->Num->lsign =3D=3D NUM_LSIGN_PRE) 4420 { 4421 if (Np->sign =3D=3D '-') 4422 strcpy(Np->inout_p, Np->L_n= egative_sign); 4423 else (gdb) bt full #0 NUM_numpart_to_char (id=3D3, Np=3D0xffa04a54) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/uti= ls/adt/formatting.c:4419 end =3D #1 NUM_processor (node=3D, Num=3D, inout=3D<= optimized out>, number=3D,=20 from_char_input_len=3D0, to_char_out_pre_spaces=3D, sign= =3D43, is_to_char=3D1 '\001',=20 collid=3D) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/uti= ls/adt/formatting.c:4773 n =3D _Np =3D {is_to_char =3D 1 '\001', Num =3D 0xffa04b18, sign =3D 43, = sign_wrote =3D 0, num_count =3D 30, num_in =3D 0,=20 num_curr =3D 15, out_pre_spaces =3D 15, read_dec =3D 0, read_post= =3D 0, read_pre =3D 0,=20 number =3D 0x61b440 "0.", '0' , number_p =3D 0x= 61b440 "0.", '0' ,=20 inout =3D 0x61b1d4 "", inout_p =3D 0x61b1d4 "", last_relevant =3D= 0x61b441 ".", '0' ,=20 L_negative_sign =3D 0x4c1438 "-", L_positive_sign =3D 0x3f5638 "+= ", decimal =3D 0x4cd530 ".",=20 L_thousands_sep =3D 0x49dd78 ",", L_currency_symbol =3D 0x4edd08 = " "} #2 0x002f2920 in numeric_to_char (fcinfo=3D0x618bd4) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/uti= ls/adt/formatting.c:5181 len =3D value =3D fmt =3D Num =3D {pre =3D 16, post =3D 15, lsign =3D -1, flag =3D 98, pre_ls= ign_num =3D 0, multi =3D 0, zero_start =3D 0, zero_end =3D 0,=20 need_locale =3D 1} format =3D 0x540d30 result =3D 0x61b1d0 shouldFree =3D out_pre_spaces =3D sign =3D 43 numstr =3D 0x61b440 "0.", '0' orgnum =3D p =3D x =3D #3 0x001aa0f0 in ExecMakeFunctionResultNoSets (fcache=3D0x618b98, econtext= =3D0x618ab8, isNull=3D0x619721 "",=20 isDone=3D) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/exe= cutor/execQual.c:2026 arg =3D result =3D fcinfo =3D 0x618bd4 fcusage =3D {fs =3D 0x0, save_f_total_time =3D {tv_sec =3D 0, tv_us= ec =3D 0}, save_total =3D {tv_sec =3D 0, tv_usec =3D 0},=20 f_start =3D {tv_sec =3D 0, tv_usec =3D 0}} i =3D #4 0x001ae258 in ExecTargetList (isDone=3D0xffa04c84, itemIsDone=3D0x6197d= 8, isnull=3D0x619720 "", values=3D0x619710,=20 econtext=3D0x618ab8, targetlist=3D0x6197b0) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/exe= cutor/execQual.c:5334 gstate =3D tle =3D resind =3D oldContext =3D 0x5f6640 tl =3D 0x6197c8 haveDoneSets =3D #5 ExecProject (projInfo=3D, isDone=3D0xffa04c84) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/exe= cutor/execQual.c:5549 slot =3D 0x619018 econtext =3D 0x618ab8 numSimpleVars =3D #6 0x001ae650 in ExecScan (node=3D0x618a30, accessMtd=3D0x1bfc80 = , recheckMtd=3D0x1bfc60 ) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/exe= cutor/execScan.c:207 slot =3D 0x619088 econtext =3D 0x618ab8 qual =3D 0x0 projInfo =3D 0x619730 isDone =3D ExprSingleResult resultSlot =3D #7 0x001a7650 in ExecProcNode (node=3D0x618a30) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/exe= cutor/execProcnode.c:400 result =3D __func__ =3D "ExecProcNode" #8 0x001a443c in ExecutePlan (dest=3D0x5d11f8, direction=3D= , numberTuples=3D0, sendTuples=3D,=20 operation=3DCMD_SELECT, planstate=3D0x618a30, estate=3D0x6189a8) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/exe= cutor/execMain.c:1490 slot =3D current_tuple_count =3D 0 #9 standard_ExecutorRun (queryDesc=3D0x605f88, direction=3D= , count=3D0) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/exe= cutor/execMain.c:319 estate =3D 0x6189a8 operation =3D CMD_SELECT dest =3D 0x5d11f8 sendTuples =3D oldcontext =3D 0x5f66f0 #10 0x002ac734 in PortalRunSelect (portal=3D0x5fb768, forward=3D1 '\001', c= ount=3D0, dest=3D0x5d11f8) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/tco= p/pquery.c:942 queryDesc =3D 0x605f88 direction =3D ForwardScanDirection nprocessed =3D __func__ =3D "PortalRunSelect" #11 0x002adabc in PortalRun (portal=3D0x5fb768, count=3D2147483647, isTopLe= vel=3D1 '\001', dest=3D0x5d11f8, altdest=3D0x5d11f8,=20 completionTag=3D0xffa05040 "") at /home/turelto/src/tmp/postgresql-9.4-= 9.4.12/build/../src/backend/tcop/pquery.c:786 save_exception_stack =3D 0xffa04f84 save_context_stack =3D 0x0 local_sigjmp_buf =3D {{__jmpbuf =3D {-285518332, -285518572, 292667= 848}, __mask_was_saved =3D 0, __saved_mask =3D { __val =3D {4288696024, 5679664, 16777218, 0, 13, 1076, 0, 0, = 5611552, 5614592, 5459968, 5611520, 5397504,=20 120, 5681576, 1886539776, 6097184, 0, 0, 0, 0, 6097168, 428= 8696024, 2792652, 90, 6247456, 2, 1, 0, 1,=20 1024, 0}}}} result =3D nprocessed =3D saveTopTransactionResourceOwner =3D 0x56aa30 ---Type to continue, or q to quit--- saveTopTransactionContext =3D 0x56ab38 saveActivePortal =3D 0x0 saveResourceOwner =3D 0x56aa30 savePortalContext =3D 0x0 saveMemoryContext =3D 0x56ab38 __func__ =3D "PortalRun" #12 0x002a9ba4 in exec_simple_query ( query_string=3D0x5cf4d8 "SELECT '' AS to_char_6, to_char(val, 'FMS", '= 9' , ".", '9' , "') FROM num_data;")= at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/tcop/p= ostgres.c:1072 parsetree =3D 0x5d00e8 portal =3D 0x5fb768 snapshot_set =3D commandTag =3D completionTag =3D "\000ELECT 10\000\000E", '\000' , "\024\000\000\000\024\377\377\377\377\000R\\\304\000R\\P" plantree_list =3D 0x5d11e0 receiver =3D 0x5d11f8 format =3D 0 dest =3D DestRemote parsetree_list =3D 0x5d0180 save_log_statement_stats =3D 0 '\000' was_logged =3D 0 '\000' msec_str =3D "\000\240P\250\000\006\004\320\000\000\000\000\000X\32= 4d0\n\000\034", '\000' , "\002" parsetree_item =3D 0x5d0170 isTopLevel =3D #13 PostgresMain (argc=3D, argv=3D, dbname=3D= 0x5694a0 "regression", username=3D) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/tco= p/postgres.c:4100 query_string =3D 0x5cf4d8 "SELECT '' AS to_char_6, to_char(val, 'F= MS", '9' , ".", '9' , "') FROM num_d= ata;" firstchar =3D 6095080 input_message =3D { data =3D 0x5cf4d8 "SELECT '' AS to_char_6, to_char(val, 'FMS", '= 9' , ".", '9' , "') FROM num_data;",= len =3D 95, maxlen =3D 1024, cursor =3D 95} local_sigjmp_buf =3D {{__jmpbuf =3D {-285518572, -285521052, 292654= 784}, __mask_was_saved =3D 1, __saved_mask =3D { __val =3D {0, 0, 0, 0, 1882663060, 1879054856, 1881810088, 0,= 1, 0, 0, 0, 1881097612, 4, 0, 0, 0, 0, 0, 0,=20 1886539776, 1886551248, 1886551248, 5821840, 0, 0, 0, 42886= 96392, 1885505112, 4288696368, 2364184,=20 0}}}} send_ready_for_query =3D 0 '\000' __func__ =3D "PostgresMain" #14 0x000606b0 in BackendRun (port=3D0x58d3d8) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/pos= tmaster/postmaster.c:4301 ac =3D 1 secs =3D 551365461 usecs =3D 297758 i =3D 1 av =3D 0x569610 maxac =3D #15 BackendStartup (port=3D0x58d3d8) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/pos= tmaster/postmaster.c:3964 bn =3D 0x10c3 pid =3D 0 #16 ServerLoop () at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../s= rc/backend/postmaster/postmaster.c:1694 port =3D 0x58d3d8 rmask =3D {fds_bits =3D {16, 0 }} selres =3D now =3D readmask =3D {fds_bits =3D {16, 0 }} nSockets =3D 5 last_lockfile_recheck_time =3D 1498050259 last_touch_time =3D 1498050259 __func__ =3D "ServerLoop" #17 0x0024d334 in PostmasterMain (argc=3D8, argv=3D) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/pos= tmaster/postmaster.c:1302 opt =3D status =3D userDoption =3D listen_addr_saved =3D i =3D output_config_variable =3D __func__ =3D "PostmasterMain" #18 0x000616f0 in main (argc=3D8, argv=3D0x568b88) at /home/turelto/src/tmp/postgresql-9.4-9.4.12/build/../src/backend/mai= n/main.c:233 No locals. It seems this issue was introduced in 9.4.9: 9.4.9, 9.4.10, 9.4.11 and 9.4.= 12 all crash at the same test at the same line in formatting.c, but 9.4.8 b= uilds successfully and passes all tests. It also seems that both NUM_numpar= t_to_char and the failing test have not been touched for, eh, decades, so t= he root cause must be somewhere else. The same issue is present in 9.6.3: LOG: server process (PID 10632) was terminated by signal 10: Bus error DETAIL: Failed process was running: SELECT '' AS to_char_6, to_char(val, = 'FMS9999999999999999.999999999999999') FROM num_data; Reading symbols from /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/src/b= ackend/postgres...done. [New LWP 10632] [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/sparc-linux-gnu/libthread_db.so.1". Core was generated by `postgres: turelto regression [local] SELECT = '. Program terminated with signal 10, Bus error. #0 NUM_numpart_to_char (id=3D3, Np=3D0xff924b5c) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/util= s/adt/formatting.c:4434 4434 if (Np->Num->lsign =3D=3D NUM_LSIGN_PRE) (gdb) l 4429 (Np->num_curr >=3D Np->out_pre_spaces || (IS_ZERO(N= p->Num) && Np->Num->zero_start =3D=3D Np->num_curr)) && 4430 (IS_PREDEC_SPACE(Np) =3D=3D FALSE || (Np->last_rele= vant && *Np->last_relevant =3D=3D '.'))) 4431 { 4432 if (IS_LSIGN(Np->Num)) 4433 { 4434 if (Np->Num->lsign =3D=3D NUM_LSIGN_PRE) 4435 { 4436 if (Np->sign =3D=3D '-') 4437 strcpy(Np->inout_p, Np->L_n= egative_sign); 4438 else (gdb) bt full #0 NUM_numpart_to_char (id=3D3, Np=3D0xff924b5c) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/util= s/adt/formatting.c:4434 end =3D #1 NUM_processor (node=3D, Num=3D, inout=3D<= optimized out>, number=3D,=20 from_char_input_len=3D0, to_char_out_pre_spaces=3D, sign= =3D43, is_to_char=3D1 '\001',=20 collid=3D) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/util= s/adt/formatting.c:4788 n =3D _Np =3D {is_to_char =3D 1 '\001', Num =3D 0xff924c20, sign =3D 43, = sign_wrote =3D 0, num_count =3D 30, num_in =3D 0,=20 num_curr =3D 15, out_pre_spaces =3D 15, read_dec =3D 0, read_post= =3D 0, read_pre =3D 0,=20 number =3D 0x6bdac0 "0.", '0' , number_p =3D 0x= 6bdac0 "0.", '0' ,=20 inout =3D 0x6bd854 "", inout_p =3D 0x6bd854 "", last_relevant =3D= 0x6bdac1 ".", '0' ,=20 L_negative_sign =3D 0x555908 "-", L_positive_sign =3D 0x4789d8 "+= ", decimal =3D 0x565d10 ".",=20 L_thousands_sep =3D 0x52ed18 ",", L_currency_symbol =3D 0x588920 = " "} #2 0x00354920 in numeric_to_char (fcinfo=3D0x6bbae4) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/util= s/adt/formatting.c:5213 len =3D value =3D fmt =3D Num =3D {pre =3D 16, post =3D 15, lsign =3D -1, flag =3D 98, pre_ls= ign_num =3D 0, multi =3D 0, zero_start =3D 0, zero_end =3D 0,=20 need_locale =3D 1} format =3D 0x5dc09c result =3D 0x6bd850 shouldFree =3D out_pre_spaces =3D sign =3D 43 numstr =3D 0x6bdac0 "0.", '0' orgnum =3D p =3D x =3D #3 0x001e16b0 in ExecMakeFunctionResultNoSets (fcache=3D0x6bbaa8, econtext= =3D0x6bb9c8, isNull=3D0x6bc229 "",=20 isDone=3D) at /home/turelto/src/tmp/postgresql-9.6-9.6.3= /build/../src/backend/executor/execQual.c:2041 arg =3D result =3D fcinfo =3D 0x6bbae4 fcusage =3D {fs =3D 0x0, save_f_total_time =3D {tv_sec =3D 1, tv_us= ec =3D 0}, save_total =3D {tv_sec =3D 0, tv_usec =3D 0},=20 f_start =3D {tv_sec =3D 0, tv_usec =3D 0}} i =3D #4 0x001e5840 in ExecTargetList (isDone=3D0xff924d8c, itemIsDone=3D0x6bc2e= 0, isnull=3D0x6bc228 "", values=3D0x6bc218,=20 econtext=3D0x6bb9c8, tupdesc=3D, targetlist=3D0x6bc2b8) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/exec= utor/execQual.c:5423 gstate =3D tle =3D resind =3D att =3D 0x6bc02c oldContext =3D 0x655430 tl =3D 0x6bc2d0 haveDoneSets =3D #5 ExecProject (projInfo=3D, isDone=3D0xff924d8c) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/exec= utor/execQual.c:5647 slot =3D 0x6bbf28 econtext =3D 0x6bb9c8 numSimpleVars =3D #6 0x001e5c84 in ExecScan (node=3D0x6bb940, accessMtd=3D0x1faec0 = , recheckMtd=3D0x1faea0 ) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/exec= utor/execScan.c:220 slot =3D 0x6bbf98 econtext =3D 0x6bb9c8 qual =3D 0x0 projInfo =3D 0x6bc238 isDone =3D ExprSingleResult resultSlot =3D #7 0x001de620 in ExecProcNode (node=3D0x6bb940) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/exec= utor/execProcnode.c:419 result =3D __func__ =3D "ExecProcNode" #8 0x001da304 in ExecutePlan (dest=3D0x69c620, direction=3D= , numberTuples=3D0, sendTuples=3D,=20 operation=3DCMD_SELECT, use_parallel_mode=3D, planstate= =3D0x6bb940, estate=3D0x6bb838) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/exec= utor/execMain.c:1569 slot =3D current_tuple_count =3D 0 #9 standard_ExecutorRun (queryDesc=3D0x6a61f8, direction=3D= , count=3D) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/exec= utor/execMain.c:338 estate =3D 0x6bb838 operation =3D CMD_SELECT dest =3D 0x69c620 sendTuples =3D oldcontext =3D 0x6549b0 #10 0x0030606c in PortalRunSelect (portal=3D0x6233a0, forward=3D, count=3D0, dest=3D0x69c620) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/tcop= /pquery.c:948 queryDesc =3D 0x6a61f8 direction =3D nprocessed =3D __func__ =3D "PortalRunSelect" #11 0x0030747c in PortalRun (portal=3D0x6233a0, count=3D2147483647, isTopLe= vel=3D1 '\001', dest=3D0x69c620, altdest=3D0x69c620,=20 completionTag=3D0xff925160 "") at /home/turelto/src/tmp/postgresql-9.6-= 9.6.3/build/../src/backend/tcop/pquery.c:789 save_exception_stack =3D 0xff9250a4 save_context_stack =3D 0x0 local_sigjmp_buf =3D {{__jmpbuf =3D {-488613709, -488613485, 490890= 671}, __mask_was_saved =3D 0, __saved_mask =3D { __val =3D {16797688, 6621224, 2, 0, 6165432, 931, 0, 0, 61654= 32, 6168576, 6094848, 6165504, 6053888, 120,=20 6320304, 1886343168, 6812424, 256, 0, 0, 0, 6812408, 428777= 8808, 3159308, 97, 1130710192, 2, 1, 0, 1,=20 1024, 0}}}} result =3D nprocessed =3D saveTopTransactionResourceOwner =3D 0x650828 saveTopTransactionContext =3D 0x655298 saveActivePortal =3D 0x0 saveResourceOwner =3D 0x650828 savePortalContext =3D 0x0 saveMemoryContext =3D 0x655298 __func__ =3D "PortalRun" #12 0x003033e4 in exec_simple_query ( query_string=3D0x67dec0 "SELECT '' AS to_char_6, to_char(val, 'FMS", '= 9' , ".", '9' , "') FROM num_data;")= at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/tcop/po= stgres.c:1094 parsetree =3D 0x67ead0 portal =3D 0x6233a0 snapshot_set =3D commandTag =3D completionTag =3D "\000ELECT 10\000\000E", '\000' , "\024\000\000\000\024\377\377\377\377\000]\000\364\000\\\377", plantree_list =3D 0x69c608 receiver =3D 0x69c620 format =3D 0 dest =3D DestRemote parsetree_list =3D 0x67eb68 save_log_statement_stats =3D 0 '\000' was_logged =3D 0 '\000' msec_str =3D "\000\222Q\310\000\006\324\344\000bs\244\000bt$\000\00= 0\000\034\000\000\000 \000bG0\000\000\000" parsetree_item =3D 0x67eb58 isTopLevel =3D #13 PostgresMain (argc=3D, argv=3D, dbname=3D= 0x606c70 "regression", username=3D) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/tcop= /postgres.c:4076 query_string =3D 0x67dec0 "SELECT '' AS to_char_6, to_char(val, 'F= MS", '9' , ".", '9' , "') FROM num_d= ata;" firstchar =3D 6810320 input_message =3D { data =3D 0x67dec0 "SELECT '' AS to_char_6, to_char(val, 'FMS", '= 9' , ".", '9' , "') FROM num_data;",= len =3D 95, maxlen =3D 1024, cursor =3D 95} local_sigjmp_buf =3D {{__jmpbuf =3D {-488613485, -488618077, 490879= 835}, __mask_was_saved =3D 1, __saved_mask =3D { __val =3D {0, 0, 0, 0, 1882908820, 4287779072, 1879209388, 0,= 0, 0, 1882908820, 1879054832, 1882055848, 4,=20 0, 0, 0, 0, 4287779152, 0, 0, 0, 0, 0, 0, 0, 0, 1498055587,= 0, 0, 4294967295, 6052864}}}} send_ready_for_query =3D 0 '\000' disable_idle_in_transaction_timeout =3D 0 '\000' __func__ =3D "PostgresMain" #14 0x0006d6c8 in BackendRun (port=3D0x627398) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/post= master/postmaster.c:4285 ac =3D 1 secs =3D 551370787 usecs =3D 396920 i =3D 1 av =3D 0x62da48 maxac =3D #15 BackendStartup (port=3D0x627398) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/post= master/postmaster.c:3959 bn =3D 0x10b3 pid =3D 0 #16 ServerLoop () at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../sr= c/backend/postmaster/postmaster.c:1715 port =3D 0x627398 rmask =3D {fds_bits =3D {16, 0 }} selres =3D now =3D readmask =3D {fds_bits =3D {16, 0 }} nSockets =3D 5 last_lockfile_recheck_time =3D 1498055585 last_touch_time =3D 1498055585 __func__ =3D "ServerLoop" #17 0x0029ba3c in PostmasterMain (argc=3D8, argv=3D) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/post= master/postmaster.c:1323 opt =3D status =3D userDoption =3D listen_addr_saved =3D i =3D output_config_variable =3D __func__ =3D "PostmasterMain" #18 0x0006e6d8 in main (argc=3D8, argv=3D0x604af8) at /home/turelto/src/tmp/postgresql-9.6-9.6.3/build/../src/backend/main= /main.c:228 No locals. A potentially similar issue was introduced in 9.4.7 and resolved in 9.4.8: https://www.postgresql.org/message-id/20160413094117.GC21485@msg.credativ.de I can test patches or provide more information. Best regards, Tom Turelinckx --=20 Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs