[gnu.gcc.bug] Gcc 1.29

pardo@june.cs.washington.edu (David Keppel) (10/11/88)

I first reported this in version 1.23 or so, it hasn't been fixed.
The idea in the program is to insert inline code to do a fast bcopy if
we happen to be compiling on the vax.

CONFIGURATION:
    Machine: VAX 8550
    OS: Ultrix V2.3
    Gcc configuration files: vax.md, tm-ultrix, config-vax.h,
	output-vax.h

WHAT I DID::

Script started on Mon Oct 10 11:49:02 1988
june 1 % make
gcc -g -O -S -v -c foo.c
gcc version 1.29
 /uns/src/GNU/g++/lib/gcc-cpp -v -undef -D__GNU__ -D__GNUC__ -Dvax -Dunix -D__OPTIMIZE__ foo.c /tmp/cc014183.cpp
GNU CPP version 1.29
 /uns/src/GNU/g++/lib/gcc-cc1 /tmp/cc014183.cpp -quiet -dumpbase foo.c -g -O -version -o foo.s
GNU C version 1.29 (vax) compiled by GNU C version 1.29.
gcc: Program cc1 got fatal signal 4.
*** Error code 1

Stop.
june 2 % more foo.c
#ifdef vax
#ifdef __GNUC__
#   define bcopy(src,dest,count) {\
        register void *__m_src = (src), *__m_dest = (dest); \
        register unsigned int __m_count = (count); \
        asm volatile \
            ("bcopy %0,%l,%2" \
	    : "=g"(__m_src) \
	    , "g"(__m_count) \
	    : "g"(__m_dest) \
	    ); \
    }
#endif
#endif


main()
{
    char *src = "Hello world\n";
    char dest[80];
    int len;

    len = strlen(src)+sizeof(char) ;
    bcopy( src, dest, len );
    printf( "%s", dest );
    exit(0);
}
june 3 % exit
june 4 % 
script done on Mon Oct 10 11:49:17 1988

	;-D on  ( The Deprogrammer )  Pardo
-- 
		    pardo@cs.washington.edu
    {rutgers,cornell,ucsd,ubc-cs,tektronix}!uw-beaver!june!pardo