[gnu.g++.bug] GNU C++ test 1.36.2

tiemann@arkesden.eng.sun.com (Michael Tiemann) (11/30/89)

I have a cleaned version of GNU C++ 1.36.2- on
	interviews.stanford.edu:~ftp/pub/g++.ytar.Z

It compiles the InterViews 2.6 snapshot, a hacked ET++, and libg++.
With the following patch, it also compiles other codes.  I am still
plugging away at problems, but I consider this version the "latest and
greatest" so far.  Here's the patch.  Remember that if you use this
compiler on a Sun4, you still need the Sparc patch I sent out with the
first announcement.  It is included here for reference.

Michael

arkesden% diff -c2 cplus-class.c~ cplus-class.c
*** cplus-class.c~	Tue Nov 28 17:48:45 1989
--- cplus-class.c	Wed Nov 29 17:46:08 1989
***************
*** 4402,4406 ****
      found_and_maybe_warn:
        if (cp->harshness[0] & 128)
! 	error ("non-const member function called from const member function");
        goto found_and_ok;
      }
--- 4402,4414 ----
      found_and_maybe_warn:
        if (cp->harshness[0] & 128)
! 	{
! 	  if (flags & LOOKUP_COMPLAIN)
! 	    {
! 	      error_with_decl (cp->function, "non-const member function `%s'");
! 	      error ("called from const member function at this point in file");
! 	    }
! 	  /* Not good enough for a match.  */
! 	  else return error_mark_node;
! 	}
        goto found_and_ok;
      }
arkesden% diff -c2 config/sparc.md~ config/sparc.md
*** config/sparc.md~	Fri Sep  1 17:46:40 1989
--- config/sparc.md	Sat Nov 18 09:04:10 1989
***************
*** 1011,1015 ****
      return \"sll %1,0x10,%0\;srl %0,0x10,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     abort ();
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
--- 1011,1020 ----
      return \"sll %1,0x10,%0\;srl %0,0x10,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     {
!       operands[1] = gen_rtx (CONST_INT, VOIDmode,
! 			     INTVAL (operands[1]) & 0xffff);
!       output_asm_insn (\"set %1,%0\", operands);
!       return \"\";
!     }
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
***************
*** 1032,1036 ****
      return \"and %1,0xff,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     abort ();
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
--- 1037,1046 ----
      return \"and %1,0xff,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     {
!       operands[1] = gen_rtx (CONST_INT, VOIDmode,
! 			     INTVAL (operands[1]) & 0xff);
!       output_asm_insn (\"set %1,%0\", operands);
!       return \"\";
!     }
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
***************
*** 1053,1057 ****
      return \"and %1,0xff,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     abort ();
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
--- 1063,1072 ----
      return \"and %1,0xff,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     {
!       operands[1] = gen_rtx (CONST_INT, VOIDmode,
! 			     INTVAL (operands[1]) & 0xff);
!       output_asm_insn (\"set %1,%0\", operands);
!       return \"\";
!     }
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
***************
*** 1078,1082 ****
      return \"sll %1,0x10,%0\;sra %0,0x10,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     abort ();
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
--- 1093,1102 ----
      return \"sll %1,0x10,%0\;sra %0,0x10,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     {
!       int i = (short)INTVAL (operands[1]);
!       operands[1] = gen_rtx (CONST_INT, VOIDmode, i);
!       output_asm_insn (\"set %1,%0\", operands);
!       return \"\";
!     }
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
***************
*** 1099,1103 ****
      return \"sll %1,0x18,%0\;sra %0,0x18,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     abort ();
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
--- 1119,1128 ----
      return \"sll %1,0x18,%0\;sra %0,0x18,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     {
!       int i = (char)INTVAL (operands[1]);
!       operands[1] = gen_rtx (CONST_INT, VOIDmode, i);
!       output_asm_insn (\"set %1,%0\", operands);
!       return \"\";
!     }
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
***************
*** 1120,1124 ****
      return \"sll %1,0x18,%0\;sra %0,0x18,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     abort ();
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
--- 1145,1154 ----
      return \"sll %1,0x18,%0\;sra %0,0x18,%0\";
    if (GET_CODE (operands[1]) == CONST_INT)
!     {
!       int i = (char)INTVAL (operands[1]);
!       operands[1] = gen_rtx (CONST_INT, VOIDmode, i);
!       output_asm_insn (\"set %1,%0\", operands);
!       return \"\";
!     }
    if (CONSTANT_ADDRESS_P (XEXP (operands[1], 0)))
      {
arkesden% 

Michael

dle@CISCO.COM (David Edwards) (12/01/89)

Trouble compiling nihcl.  I have been trying to compile nihcl v2.204 which
reportedly compiles successfully using cfront 2.0.  I have found different
problems depending on the version of compiler used.

	1.36.0 - Module Date.c encounters multiple syntax errors
	1.36.1 - Assert error detected - cplus-decl TREE_CODE(type)!=METHOD_TYPE
	1.36.2- - Segementation violation in Collection.h - any module
	1.36.2-(w/Patch) - Same as 1.36.2-

nihcl is a cfront 2.0 version of oops(v2.2) with enhancements by the same
author.  It is available on ALW.NIH.GOV.

Any suggestions?  Would you like the core dump?

-dle

tiemann@SUN.COM (Michael Tiemann) (12/01/89)

There is no need to send me core dumps, since they would be invalid on
any machine other than yours.  Preprocessor output is all that is
usually required.  I have not been trying to compile 2.204 OOPS
because of its lack of support for Sun4, but I will compile agaist it
to find the new core dumpers.

Michael