OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [config/] [mips/] [sdb.h] - Diff between revs 38 and 154

Go to most recent revision | Only display areas with differences | Details | Blame | View Log

Rev 38 Rev 154
/* Generate SDB debugging info.
/* Generate SDB debugging info.
   Copyright (C) 2003, 2004, 2007 Free Software Foundation, Inc.
   Copyright (C) 2003, 2004, 2007 Free Software Foundation, Inc.
 
 
This file is part of GCC.
This file is part of GCC.
 
 
GCC is free software; you can redistribute it and/or modify it under
GCC is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free
the terms of the GNU General Public License as published by the Free
Software Foundation; either version 3, or (at your option) any later
Software Foundation; either version 3, or (at your option) any later
version.
version.
 
 
GCC is distributed in the hope that it will be useful, but WITHOUT ANY
GCC is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or
WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
for more details.
for more details.
 
 
You should have received a copy of the GNU General Public License
You should have received a copy of the GNU General Public License
along with GCC; see the file COPYING3.  If not see
along with GCC; see the file COPYING3.  If not see
<http://www.gnu.org/licenses/>.  */
<http://www.gnu.org/licenses/>.  */
 
 
/* Note that no configuration uses sdb as its preferred format.  */
/* Note that no configuration uses sdb as its preferred format.  */
 
 
#define SDB_DEBUGGING_INFO 1
#define SDB_DEBUGGING_INFO 1
 
 
/* Forward references to tags are allowed.  */
/* Forward references to tags are allowed.  */
#define SDB_ALLOW_FORWARD_REFERENCES
#define SDB_ALLOW_FORWARD_REFERENCES
 
 
/* Unknown tags are also allowed.  */
/* Unknown tags are also allowed.  */
#define SDB_ALLOW_UNKNOWN_REFERENCES
#define SDB_ALLOW_UNKNOWN_REFERENCES
 
 
/* Block start/end next label #.  */
/* Block start/end next label #.  */
extern int sdb_label_count;
extern int sdb_label_count;
 
 
/* Starting line of current function.  */
/* Starting line of current function.  */
extern int sdb_begin_function_line;
extern int sdb_begin_function_line;
 
 
/* For block start and end, we create labels, so that
/* For block start and end, we create labels, so that
   later we can figure out where the correct offset is.
   later we can figure out where the correct offset is.
   The normal .ent/.end serve well enough for functions,
   The normal .ent/.end serve well enough for functions,
   so those are just commented out.  */
   so those are just commented out.  */
 
 
#define PUT_SDB_BLOCK_START(LINE)                       \
#define PUT_SDB_BLOCK_START(LINE)                       \
do {                                                    \
do {                                                    \
  fprintf (asm_out_file,                                \
  fprintf (asm_out_file,                                \
           "%sLb%d:\n\t.begin\t%sLb%d\t%d\n",           \
           "%sLb%d:\n\t.begin\t%sLb%d\t%d\n",           \
           LOCAL_LABEL_PREFIX,                          \
           LOCAL_LABEL_PREFIX,                          \
           sdb_label_count,                             \
           sdb_label_count,                             \
           LOCAL_LABEL_PREFIX,                          \
           LOCAL_LABEL_PREFIX,                          \
           sdb_label_count,                             \
           sdb_label_count,                             \
           (LINE));                                     \
           (LINE));                                     \
  sdb_label_count++;                                    \
  sdb_label_count++;                                    \
} while (0)
} while (0)
 
 
#define PUT_SDB_BLOCK_END(LINE)                         \
#define PUT_SDB_BLOCK_END(LINE)                         \
do {                                                    \
do {                                                    \
  fprintf (asm_out_file,                                \
  fprintf (asm_out_file,                                \
           "%sLe%d:\n\t.bend\t%sLe%d\t%d\n",            \
           "%sLe%d:\n\t.bend\t%sLe%d\t%d\n",            \
           LOCAL_LABEL_PREFIX,                          \
           LOCAL_LABEL_PREFIX,                          \
           sdb_label_count,                             \
           sdb_label_count,                             \
           LOCAL_LABEL_PREFIX,                          \
           LOCAL_LABEL_PREFIX,                          \
           sdb_label_count,                             \
           sdb_label_count,                             \
           (LINE));                                     \
           (LINE));                                     \
  sdb_label_count++;                                    \
  sdb_label_count++;                                    \
} while (0)
} while (0)
 
 
#define PUT_SDB_FUNCTION_START(LINE)
#define PUT_SDB_FUNCTION_START(LINE)
 
 
#define PUT_SDB_FUNCTION_END(LINE)                      \
#define PUT_SDB_FUNCTION_END(LINE)                      \
do {                                                    \
do {                                                    \
  SDB_OUTPUT_SOURCE_LINE (asm_out_file, LINE + sdb_begin_function_line); \
  SDB_OUTPUT_SOURCE_LINE (asm_out_file, LINE + sdb_begin_function_line); \
} while (0)
} while (0)
 
 
#define PUT_SDB_EPILOGUE_END(NAME)
#define PUT_SDB_EPILOGUE_END(NAME)
 
 
/* We need to use .esize and .etype instead of .size and .type to
/* We need to use .esize and .etype instead of .size and .type to
   avoid conflicting with ELF directives.  */
   avoid conflicting with ELF directives.  */
#undef PUT_SDB_SIZE
#undef PUT_SDB_SIZE
#define PUT_SDB_SIZE(a)                                 \
#define PUT_SDB_SIZE(a)                                 \
do {                                                    \
do {                                                    \
  fprintf (asm_out_file, "\t.esize\t" HOST_WIDE_INT_PRINT_DEC ";", \
  fprintf (asm_out_file, "\t.esize\t" HOST_WIDE_INT_PRINT_DEC ";", \
           (HOST_WIDE_INT) (a));                        \
           (HOST_WIDE_INT) (a));                        \
} while (0)
} while (0)
 
 
#undef PUT_SDB_TYPE
#undef PUT_SDB_TYPE
#define PUT_SDB_TYPE(a)                                 \
#define PUT_SDB_TYPE(a)                                 \
do {                                                    \
do {                                                    \
  fprintf (asm_out_file, "\t.etype\t0x%x;", (a));       \
  fprintf (asm_out_file, "\t.etype\t0x%x;", (a));       \
} while (0)
} while (0)
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.