* [ECOS] MPC555 platforms cause gcc segmentation fault @ 2006-08-16 14:50 Steven Clugston 2006-09-12 15:36 ` Wendell Liu 0 siblings, 1 reply; 5+ messages in thread From: Steven Clugston @ 2006-08-16 14:50 UTC (permalink / raw) To: ecos-discuss Hi All I've been trying to bring a PowerPC MPC555 platform port I've been working on up-to-date from ecos2.0. I started by downloading a recent trunk snapshot and building (unmodified from the cvs snapshot) cme555 and ec555 platforms using the default package template. With either platform, part way through the build it fails with a compiler crash. It gives the following output: powerpc-eabi-gcc -c -I/ecos-d/cygwin/.../ecos/cme555ECOS_install/include -I/opt/ecos/.../packages/language/c/libc/stdio/current -I/opt/ecos/.../packages/language/c/libc/stdio/current/src -I/opt/ecos/.../packages/language/c/libc/stdio/current/tests -I. -I/opt/ecos/.../packages/language/c/libc/stdio/current/src/input/ -finline-limit=7000 -mcpu=505 -Wall -Wpointer-arith -Winline -Wundef -Woverloaded-virtual -g -O2 -ffunction-sections -fdata-sections -mmultiple -fno-rtti -fno-exceptions -Wp,-MD,src/input/vfscanf.tmp -o src/input/language_c_libc_stdio_vfscanf.o /opt/ecos/.../packages/language/c/libc/stdio/current/src/input/vfscanf.c xx make[1]: Leaving directory `/ecos-d/cygwin/.../ecos/cme555ECOS_build/language/c/libc/stdio/current' /opt/ecos/ecoscvs/packages/language/c/libc/stdio/current/src/input/vfsca nf.cxx: In make: Leaving directory `/ecos-d/cygwin/.../ecos/cme555ECOS_build' function `int vfscanf(CYG_ADDRESS (*)[9999], const char*, __va_list_tag*)': /opt/ecos/ecoscvs/packages/language/c/libc/stdio/current/src/input/vfsca nf.cxx:952: internal error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions. make[1]: *** [src/input/vfscanf.o.d] Error 1 make: *** [build] Error 2 I'm using recent cygwin build as a host and the following tool versions: $ powerpc-eabi-gcc --version powerpc-eabi-gcc (GCC) 3.2.1 (eCosCentric) $ make --version GNU Make 3.80 I've tried substituting 'vfscanf.cxx' with the one from ecos2.0 but it fails in the same way at the same point in the code: input_failure: return nassigned ? nassigned : -1; match_failure: return nassigned; } // vfscanf() <---- fails here. (I was surprised to see 'goto' statements as I thought these were depeciated/frowned upon in C) The same code compiles under ecos2.0 alright using the same compiler. I presume that the complier should not cause a segmentation fault at any time, but something has changed somewhere in the source which triggers this. Should I be using a more recent version of the gnutools? Thanks for any help. Steven. -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss ^ permalink raw reply [flat|nested] 5+ messages in thread
* RE: [ECOS] MPC555 platforms cause gcc segmentation fault 2006-08-16 14:50 [ECOS] MPC555 platforms cause gcc segmentation fault Steven Clugston @ 2006-09-12 15:36 ` Wendell Liu 2006-09-12 15:51 ` Wendell Liu 0 siblings, 1 reply; 5+ messages in thread From: Wendell Liu @ 2006-09-12 15:36 UTC (permalink / raw) To: 'Steven Clugston', ecos-discuss Hello Steven and other eCos experts, Did you fix the "segmentation fault" problem yet? If so, could you please tell me how to do it? I basically took the latest cygWin and latest eCos from CVS, and use the latest ecosconfig (2006-07-10) to do: ecosconfig new sh4_202_md default ecosconfig tree make I got the exactly the same problem as you submitted on Aug. 16, 2006. Anyone please help us to figure this out? Thank you very much, Wendell -----Original Message----- From: ecos-discuss-owner@ecos.sourceware.org [mailto:ecos-discuss-owner@ecos.sourceware.org] On Behalf Of Steven Clugston Sent: August 16, 2006 10:50 AM To: ecos-discuss@ecos.sourceware.org Subject: [ECOS] MPC555 platforms cause gcc segmentation fault Hi All I've been trying to bring a PowerPC MPC555 platform port I've been working on up-to-date from ecos2.0. I started by downloading a recent trunk snapshot and building (unmodified from the cvs snapshot) cme555 and ec555 platforms using the default package template. With either platform, part way through the build it fails with a compiler crash. It gives the following output: powerpc-eabi-gcc -c -I/ecos-d/cygwin/.../ecos/cme555ECOS_install/include -I/opt/ecos/.../packages/language/c/libc/stdio/current -I/opt/ecos/.../packages/language/c/libc/stdio/current/src -I/opt/ecos/.../packages/language/c/libc/stdio/current/tests -I. -I/opt/ecos/.../packages/language/c/libc/stdio/current/src/input/ -finline-limit=7000 -mcpu=505 -Wall -Wpointer-arith -Winline -Wundef -Woverloaded-virtual -g -O2 -ffunction-sections -fdata-sections -mmultiple -fno-rtti -fno-exceptions -Wp,-MD,src/input/vfscanf.tmp -o src/input/language_c_libc_stdio_vfscanf.o /opt/ecos/.../packages/language/c/libc/stdio/current/src/input/vfscanf.c xx make[1]: Leaving directory `/ecos-d/cygwin/.../ecos/cme555ECOS_build/language/c/libc/stdio/current' /opt/ecos/ecoscvs/packages/language/c/libc/stdio/current/src/input/vfsca nf.cxx: In make: Leaving directory `/ecos-d/cygwin/.../ecos/cme555ECOS_build' function `int vfscanf(CYG_ADDRESS (*)[9999], const char*, __va_list_tag*)': /opt/ecos/ecoscvs/packages/language/c/libc/stdio/current/src/input/vfsca nf.cxx:952: internal error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions. make[1]: *** [src/input/vfscanf.o.d] Error 1 make: *** [build] Error 2 I'm using recent cygwin build as a host and the following tool versions: $ powerpc-eabi-gcc --version powerpc-eabi-gcc (GCC) 3.2.1 (eCosCentric) $ make --version GNU Make 3.80 I've tried substituting 'vfscanf.cxx' with the one from ecos2.0 but it fails in the same way at the same point in the code: input_failure: return nassigned ? nassigned : -1; match_failure: return nassigned; } // vfscanf() <---- fails here. (I was surprised to see 'goto' statements as I thought these were depeciated/frowned upon in C) The same code compiles under ecos2.0 alright using the same compiler. I presume that the complier should not cause a segmentation fault at any time, but something has changed somewhere in the source which triggers this. Should I be using a more recent version of the gnutools? Thanks for any help. Steven. -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss ^ permalink raw reply [flat|nested] 5+ messages in thread
* RE: [ECOS] MPC555 platforms cause gcc segmentation fault 2006-09-12 15:36 ` Wendell Liu @ 2006-09-12 15:51 ` Wendell Liu 2006-09-12 17:13 ` Andrew Lunn 0 siblings, 1 reply; 5+ messages in thread From: Wendell Liu @ 2006-09-12 15:51 UTC (permalink / raw) To: 'Wendell Liu', 'Steven Clugston', ecos-discuss Ok, I found the solution from Peter Hou on Feb. 16, 2006 as below email. My question is: is this a permanent way to solve this problem. Is so, could someone in charge of the source code to fix it in CVS? Thanks, Wendell ---------------------------------------------------------------------------- ---- ---------------------------------------------------------------------------- ---- RE: Using SNMP in ecos From: "Hou, Chien-Long" <phou at ti dot com> To: <ecos-discuss at ecos dot sourceware dot org> Date: Thu, 16 Feb 2006 23:11:42 -0600 Subject: RE: [ECOS] Using SNMP in ecos ---------------------------------------------------------------------------- ---- Hello: I finally figured out the cause of 'segmentation fault'. Apparently when compile vfscanf(), if -O2 is used, GCC sometimes get 'segmentation fault' (doesn't matter what the cross compiled target is). The solution is use -O instead. In my case, modify \home\<you>\<ecos-work>\language\c\libc\stdio\current\makefile Replace -O2 by -O Problem resolved, Thanks you -Peter Hou ---------------------------------------------------------------------------- ---- ---------------------------------------------------------------------------- ---- -----Original Message----- From: ecos-discuss-owner@ecos.sourceware.org [mailto:ecos-discuss-owner@ecos.sourceware.org] On Behalf Of Wendell Liu Sent: September 12, 2006 11:36 AM To: 'Steven Clugston'; ecos-discuss@ecos.sourceware.org Subject: RE: [ECOS] MPC555 platforms cause gcc segmentation fault Hello Steven and other eCos experts, Did you fix the "segmentation fault" problem yet? If so, could you please tell me how to do it? I basically took the latest cygWin and latest eCos from CVS, and use the latest ecosconfig (2006-07-10) to do: ecosconfig new sh4_202_md default ecosconfig tree make I got the exactly the same problem as you submitted on Aug. 16, 2006. Anyone please help us to figure this out? Thank you very much, Wendell -----Original Message----- From: ecos-discuss-owner@ecos.sourceware.org [mailto:ecos-discuss-owner@ecos.sourceware.org] On Behalf Of Steven Clugston Sent: August 16, 2006 10:50 AM To: ecos-discuss@ecos.sourceware.org Subject: [ECOS] MPC555 platforms cause gcc segmentation fault Hi All I've been trying to bring a PowerPC MPC555 platform port I've been working on up-to-date from ecos2.0. I started by downloading a recent trunk snapshot and building (unmodified from the cvs snapshot) cme555 and ec555 platforms using the default package template. With either platform, part way through the build it fails with a compiler crash. It gives the following output: powerpc-eabi-gcc -c -I/ecos-d/cygwin/.../ecos/cme555ECOS_install/include -I/opt/ecos/.../packages/language/c/libc/stdio/current -I/opt/ecos/.../packages/language/c/libc/stdio/current/src -I/opt/ecos/.../packages/language/c/libc/stdio/current/tests -I. -I/opt/ecos/.../packages/language/c/libc/stdio/current/src/input/ -finline-limit=7000 -mcpu=505 -Wall -Wpointer-arith -Winline -Wundef -Woverloaded-virtual -g -O2 -ffunction-sections -fdata-sections -mmultiple -fno-rtti -fno-exceptions -Wp,-MD,src/input/vfscanf.tmp -o src/input/language_c_libc_stdio_vfscanf.o /opt/ecos/.../packages/language/c/libc/stdio/current/src/input/vfscanf.c xx make[1]: Leaving directory `/ecos-d/cygwin/.../ecos/cme555ECOS_build/language/c/libc/stdio/current' /opt/ecos/ecoscvs/packages/language/c/libc/stdio/current/src/input/vfsca nf.cxx: In make: Leaving directory `/ecos-d/cygwin/.../ecos/cme555ECOS_build' function `int vfscanf(CYG_ADDRESS (*)[9999], const char*, __va_list_tag*)': /opt/ecos/ecoscvs/packages/language/c/libc/stdio/current/src/input/vfsca nf.cxx:952: internal error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions. make[1]: *** [src/input/vfscanf.o.d] Error 1 make: *** [build] Error 2 I'm using recent cygwin build as a host and the following tool versions: $ powerpc-eabi-gcc --version powerpc-eabi-gcc (GCC) 3.2.1 (eCosCentric) $ make --version GNU Make 3.80 I've tried substituting 'vfscanf.cxx' with the one from ecos2.0 but it fails in the same way at the same point in the code: input_failure: return nassigned ? nassigned : -1; match_failure: return nassigned; } // vfscanf() <---- fails here. (I was surprised to see 'goto' statements as I thought these were depeciated/frowned upon in C) The same code compiles under ecos2.0 alright using the same compiler. I presume that the complier should not cause a segmentation fault at any time, but something has changed somewhere in the source which triggers this. Should I be using a more recent version of the gnutools? Thanks for any help. Steven. -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [ECOS] MPC555 platforms cause gcc segmentation fault 2006-09-12 15:51 ` Wendell Liu @ 2006-09-12 17:13 ` Andrew Lunn 2006-09-28 2:43 ` Wendell Liu 0 siblings, 1 reply; 5+ messages in thread From: Andrew Lunn @ 2006-09-12 17:13 UTC (permalink / raw) To: Wendell Liu; +Cc: 'Steven Clugston', ecos-discuss On Tue, Sep 12, 2006 at 11:51:24AM -0400, Wendell Liu wrote: > Ok, I found the solution from Peter Hou on Feb. 16, 2006 as below email. > > My question is: is this a permanent way to solve this problem. Is so, could > someone in charge of the source code to fix it in CVS? No, this is not a permanent way to fix the problem. Gcc should not segfault when optimizing! You need to get gcc/cygwin fixed. Andrew -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss ^ permalink raw reply [flat|nested] 5+ messages in thread
* RE: [ECOS] MPC555 platforms cause gcc segmentation fault 2006-09-12 17:13 ` Andrew Lunn @ 2006-09-28 2:43 ` Wendell Liu 0 siblings, 0 replies; 5+ messages in thread From: Wendell Liu @ 2006-09-28 2:43 UTC (permalink / raw) To: 'Andrew Lunn'; +Cc: ecos-discuss Hi Andrew, Please excuse me if this question is too simple. I got gcc version 4.1, but I couldn't compile the eCos because the sh-elf-gcc can't find the relative path: /opt/ecos/ecos/packages/language/c/libc/stdio/current/src/output/vfnprintf.c xx If changing to the absolute path: c:/cygwin/opt/ecos/ecos/packages/language/c/libc/stdio/current/src/output/vf nprintf.cxx The sh-elf-gcc can find the file. So what's the reason for this, and how to solve this issue? Thanks a lot, Wendell -----Original Message----- From: ecos-discuss-owner@ecos.sourceware.org [mailto:ecos-discuss-owner@ecos.sourceware.org] On Behalf Of Andrew Lunn Sent: September 12, 2006 1:13 PM To: Wendell Liu Cc: 'Steven Clugston'; ecos-discuss@ecos.sourceware.org Subject: Re: [ECOS] MPC555 platforms cause gcc segmentation fault On Tue, Sep 12, 2006 at 11:51:24AM -0400, Wendell Liu wrote: > Ok, I found the solution from Peter Hou on Feb. 16, 2006 as below email. > > My question is: is this a permanent way to solve this problem. Is so, > could someone in charge of the source code to fix it in CVS? No, this is not a permanent way to fix the problem. Gcc should not segfault when optimizing! You need to get gcc/cygwin fixed. Andrew -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2006-09-28 2:43 UTC | newest] Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2006-08-16 14:50 [ECOS] MPC555 platforms cause gcc segmentation fault Steven Clugston 2006-09-12 15:36 ` Wendell Liu 2006-09-12 15:51 ` Wendell Liu 2006-09-12 17:13 ` Andrew Lunn 2006-09-28 2:43 ` Wendell Liu
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).