This is the mail archive of the gcc-bugs@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: fast-fixinc losing badly on alpha-dec-osf4.0a



  In message <19990603142433.21538.qmail@egcs.cygnus.com>you write:
  > > They fall into two basic categories.
  > > 
  > >   1. Failure to fix the _IO macros in many files.
  > 
  > I will work on this today:
  > 
  > Applying No_Double_Slash          to ./bktest/fix.h  
  > Applying Io_Def_Quotes            to ./bktest/fix.h
  > Fixed:  ./bktest/fix.h
  > 
  > Io_Def_Quotes did not do anything :-(
Looks like your fix did the trick on these.  Thanks!

  > >   2. Failure to turn C++ comments into a C comment.
  > 
  > Very odd.  What is the name of the file?  My fixincl program
  > stripped out the '//' comment from your sample.
  > 
  > The no_double_slash fix omits all files containing any of
  > 
  >     CC/
  >     cxx/
  >     ++/
  > 
  > in their names.  Also, the fix is only applied if either:
OK.  One of them has a ++.  It appears inside a macro like this:

#define PROBE_START(PD,a,b,c,d,e)                       \
MACRO_BEGIN                                             \
if (probe_smp) {                                        \
   probe_config_t *PT = (PD)->pb_table;                 \
   int np;                                              \
   np = (PT) ? PT->type : 0;                            \
   lock_read(&(PD)->pb_lock);                           \
   if (np > 1) {                                        \
      unsigned int flag;                                \
      int j;                                            \
      for (flag=0, j=0; j<np; j++)                      \
        if (lock_islocked((PT)->probe[j]))              \
          flag |= (unsigned int)1<<(np-1-j);            \
      PT->count[flag]++;                                \
   }                                                    \
}                                                       \
MACRO_END

In another one of the files CC appears like this:

#define K2_MSTR_INTR_MODE_ACCEL 1       /* Accelerator Mode     */

I suspect we need to be a little more selective about when the fix does
not apply.  What a mess :(

  >  *  traditional hacks like irix_bogus_cxx_cmnt, no longer work (which
  >  *  strangely enough was also used on alpha-dec-osf4.0d).  If we skip the
  >  *  hack whenever we see ``"//"'', then the need for the secondary hack
  >  *  disappears.  Note: it is painful to ensure that the first quote
  >  *  exists, so we just check for the trailing quote directly abutting
  >  *  the //.  Note: We should never touch a line that has // completely

Note the reference to osf4.0d.  I wonder if it's related to the problem
we're seeing.


  > BTW, what is your intent vis-a-vis
  > "fixinc patch:  eliminate need for setenv/putenv"?
I installed it last night.

I'm going to go ahead and install the fixes you sent today :-)

Note, we're also not fixing sys/limits.h, but I already know what the problem
is with that one and will fix it shortly.

jeff



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