Bug 19326

Summary: Fix GCC Target Macro 'i386/freebsd.h'.
Product: Base System Reporter: yakisoba <yakisoba>
Component: gnuAssignee: David E. O'Brien <obrien>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: 4.0-STABLE   
Hardware: Any   
OS: Any   

Description yakisoba 2000-06-16 04:30:01 UTC
  GCC 2.95 or later, document 'description' field added to
'TARGET_SWITCHES' and 'TARGET_OPTIONS' structure.
But 'i386/freebsd.h' is not added the field.

=== i386/i386.h with GCC 2.95.2 ===
...
#define TARGET_SWITCHES                                                 \
{ { "80387",                     MASK_80387, "Use hardware fp" },       \
                                           ^^^^^^^^^^^^^^^^^^^
  { "no-80387",                 -MASK_80387, "Do not use hardware fp" },\
...
  SUBTARGET_SWITCHES                                                    \
  { "", MASK_SCHEDULE_PROLOGUE | TARGET_DEFAULT, 0 }}
...

=== i386/freebsd.h rev 1.34 ===
...
#undef        SUBTARGET_SWITCHES
#define SUBTARGET_SWITCHES                                              \
     { "profiler-epilogue",      MASK_PROFILER_EPILOGUE},               \
     { "no-profiler-epilogue",  -MASK_PROFILER_EPILOGUE},               \
     { "aout",                   MASK_AOUT},                            \
     { "no-aout",               -MASK_AOUT},                            \
     { "underscores",            MASK_UNDERSCORES},                     \
     { "no-underscores",        -MASK_UNDERSCORES},
...

Fix: 

Add Null field.

=== i386/freebsd.h ===
...
#undef  SUBTARGET_SWITCHES
#define SUBTARGET_SWITCHES                                              \
     { "profiler-epilogue",      MASK_PROFILER_EPILOGUE, "" },          \
...                                                    ^^^^ 

  Or add pretty good 'description'.

=== i386/freebsd.h ===
...
#undef  SUBTARGET_SWITCHES
#define SUBTARGET_SWITCHES                                              \
     { "profiler-epilogue",      MASK_PROFILER_EPILOGUE, "Function profiler epilogue" },\
...

  So print it like below.

yakisoba % gcc -v --help
...
Target specific options:
...
  -mno-80387           Do not use hardware fp
  -m80387              Use hardware fp
...
  -mprofiler-epilogue  Function profiler epilogue
...
Comment 1 Johan Karlsson freebsd_committer freebsd_triage 2000-08-11 23:08:53 UTC
Responsible Changed
From-To: freebsd-bugs->obrien

David is our gcc maintainer.
Comment 2 David E. O'Brien freebsd_committer freebsd_triage 2000-11-11 04:50:58 UTC
State Changed
From-To: open->closed

Committed.  Thanks!