[comp.unix.ultrix] Ultrix 4.1 cc2.0 and cc2.1 uopt/ugen core dump; also cc1.31 dump

D. Allen [CGL]" <idallen@watcgl.waterloo.edu> (03/12/91)

If I had a typewriter, this would be a DEC SPR.

ULTRIX V4.1 (Rev. 52) on a DS5400

    % cc2.0 -c i.c
    Fatal error in: /usr/lib/cmplrs/cc2.0/ugen Trace/BPT trap - core dumped
    % cc2.0 -O -c i.c
    Fatal error in: /usr/lib/cmplrs/cc2.0/uopt Segmentation fault - core dumped

    % cc2.1 -c i.c
    Fatal error in: /usr/lib/cmplrs/cc2.1/ugen Trace/BPT trap - core dumped
    % cc2.1 -O -c i.c
    Fatal error in: /usr/lib/cmplrs/cc2.1/uopt Segmentation fault - core dumped

Ultrix V3.1C (Rev. 41) on a DS5400

    Same core dumps for cc1.31 and cc2.1 on Ultrix 3.1C.

Source (smallest example producing the problem):

    /* Code courtesy of AHVermen@watcgl.waterloo.edu */
    struct foo {
	int x;
    };

    static struct foo vec[2];
    static struct foo y;
    static struct foo x;
    static int flag;

    main()
    {
	x = flag ? (vec[0]=y) : (vec[1]=y) ;
    }
-- 
-IAN! (Ian! D. Allen) idallen@watcgl.uwaterloo.ca idallen@watcgl.waterloo.edu
 [129.97.128.64]  Computer Graphics Lab/University of Waterloo/Ontario/Canada

vlr@litwin.com (Vic Rice) (03/12/91)

In <1991Mar11.164902.6021@watcgl.waterloo.edu> idallen@watcgl.waterloo.edu (Ian! D. Allen [CGL]) writes:

>If I had a typewriter, this would be a DEC SPR.

>ULTRIX V4.1 (Rev. 52) on a DS5400

>    % cc2.0 -c i.c
>    Fatal error in: /usr/lib/cmplrs/cc2.0/ugen Trace/BPT trap - core dumped
>    % cc2.0 -O -c i.c
>    Fatal error in: /usr/lib/cmplrs/cc2.0/uopt Segmentation fault - core dumped

>    % cc2.1 -c i.c
>    Fatal error in: /usr/lib/cmplrs/cc2.1/ugen Trace/BPT trap - core dumped
>    % cc2.1 -O -c i.c
>    Fatal error in: /usr/lib/cmplrs/cc2.1/uopt Segmentation fault - core dumped

Yup, I get this error also (DECStation 5000, Ultrix 4.0). However, with
the GNU gcc compiler, gcc version 1.39 OSF release #2 last modified 91/03/03, 
no problems. I highly recommend this compiler for DECStation's. It is vastly
superior to the supplied Mips compiler.