This is the mail archive of the gcc-regression@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: builtin-complex-1.c failures


> Date: Mon, 11 Jun 2001 17:22:32 -0700
> From: Mark Mitchell <mark@codesourcery.com>
> Content-Disposition: inline
> 
> 
> 
> --On Monday, June 11, 2001 02:51:34 PM -0700 Geoff Keating 
> <geoffk@geoffk.org> wrote:
> 
> >
> > Hi Mark,
> >
> > I tracked down the builtin-complex-1 failures to this patch:
> >
> > +2001-06-08  Mark Mitchell  <mark@codesourcery.com>
> > +
> > +       * c-decl.c (grokdeclarator): Make the TREE_TYPE for declarations
> > +       accurately reflect its cv-qualification.
> > +       * c-typeck.c (type_lists_compatible_p): Ignore the top-levl
> > +       cv-qualifiers on function types.
> >
> > Could you look at it?  I can't see what the problem is.
> >
> > --
> > - Geoffrey Keating <geoffk@geoffk.org>
> 
> Are you sure?  I just tried reverting the patch, and I still seemed
> to get the failure.  We're falling over in SUBREG-land, and I know
> Jan has been messing with that a lot lately.  Could it be something
> in there?

I haven't tried to really investigate it, but as of right now, if I
build GCC then builtin-complex-1 fails, but if I do

cvs update -j 1.229 -j 1.228 c-decl.c

and then rebuild GCC, it succeeds, and it's

revision 1.229
date: 2001/06/08 22:33:44;  author: mmitchel;  state: Exp;  lines: +8 -2
        * c-decl.c (grokdeclarator): Make the TREE_TYPE for declarations
        accurately reflect its cv-qualification.
        * c-typeck.c (type_lists_compatible_p): Ignore the top-levl
        cv-qualifiers on function types.

I find this chunk suspicious:

*** c-decl.c    2001/06/06 03:08:19     1.228
--- c-decl.c    2001/06/08 22:33:44     1.229
*************** grokdeclarator (declarator, declspecs, d
*** 4719,4725 ****
  
      if (decl_context == PARM)
        {
!       tree type_as_written = type;
        tree promoted_type;
  
        /* A parameter declared as an array of T is really a pointer to T.
--- 4719,4725 ----
  
      if (decl_context == PARM)
        {
!       tree type_as_written;
        tree promoted_type;
  
        /* A parameter declared as an array of T is really a pointer to T.

since below it is

*************** grokdeclarator (declarator, declspecs, d
*** 4782,4787 ****
--- 4782,4791 ----
            type = build_pointer_type (type);
            type_quals = TYPE_UNQUALIFIED;
          }
+       else if (type_quals)
+         type = c_build_qualified_type (type, type_quals);
+         
+       type_as_written = type;
  
        decl = build_decl (PARM_DECL, declarator, type);
        if (size_varies)

and I see 'type' being changed right at the top of the context.

Or, of course, it could be something completely different.

-- 
- Geoffrey Keating <geoffk@geoffk.org>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]