(NOTE_INSN_FUNCTION_BEG): Make non-zero.
authorDoug Evans <dje@gnu.org>
Mon, 26 Apr 1993 00:18:16 +0000 (00:18 +0000)
committerDoug Evans <dje@gnu.org>
Mon, 26 Apr 1993 00:18:16 +0000 (00:18 +0000)
From-SVN: r4226

gcc/rtl.c
gcc/rtl.h

index 9a25158cc9c5f7e4e5e6150a06508db8d718db39..d5eea1239e584a0287baa88f0d39eba54ec815dd 100644 (file)
--- a/gcc/rtl.c
+++ b/gcc/rtl.c
@@ -170,13 +170,13 @@ char rtx_class[] = {
 
 /* Names for kinds of NOTEs and REG_NOTEs.  */
 
-char *note_insn_name[] = { "NOTE_INSN_FUNCTION_BEG", "NOTE_INSN_DELETED",
+char *note_insn_name[] = { 0                    , "NOTE_INSN_DELETED",
                           "NOTE_INSN_BLOCK_BEG", "NOTE_INSN_BLOCK_END",
                           "NOTE_INSN_LOOP_BEG", "NOTE_INSN_LOOP_END",
                           "NOTE_INSN_FUNCTION_END", "NOTE_INSN_SETJMP",
                           "NOTE_INSN_LOOP_CONT", "NOTE_INSN_LOOP_VTOP",
                           "NOTE_INSN_PROLOGUE_END", "NOTE_INSN_EPILOGUE_BEG",
-                          "NOTE_INSN_DELETED_LABEL"};
+                          "NOTE_INSN_DELETED_LABEL", "NOTE_INSN_FUNCTION_BEG"};
 
 char *reg_note_name[] = { "", "REG_DEAD", "REG_INC", "REG_EQUIV", "REG_WAS_0",
                          "REG_EQUAL", "REG_RETVAL", "REG_LIBCALL",
index f223cf6fd725542ef05f9eb5b10a05915e65c2cb..fbebd17f6557f26df6e55a97ed051345c64db14c 100644 (file)
--- a/gcc/rtl.h
+++ b/gcc/rtl.h
@@ -353,11 +353,17 @@ extern char *reg_note_name[];
 #define NOTE_LINE_NUMBER(INSN) ((INSN)->fld[4].rtint)
 
 /* Codes that appear in the NOTE_LINE_NUMBER field
-   for kinds of notes that are not line numbers.  */
+   for kinds of notes that are not line numbers.
 
-/* This note indicates the end of the real body of the function,
-   after moving the parms into their homes, etc.  */
-#define NOTE_INSN_FUNCTION_BEG 0
+   Notice that we do not try to use zero here for any of
+   the special note codes because sometimes the source line
+   actually can be zero!  This happens (for example) when we
+   are generating code for the per-translation-unit constructor
+   and destructor routines for some C++ translation unit.
+
+   If you should change any of the following values, or if you
+   should add a new value here, don't forget to change the
+   note_insn_name array in rtl.c.  */
 
 /* This note is used to get rid of an insn
    when it isn't safe to patch the insn out of the chain.  */
@@ -384,7 +390,10 @@ extern char *reg_note_name[];
 #define NOTE_INSN_EPILOGUE_BEG -11
 /* Generated in place of user-declared labels when they are deleted.  */
 #define NOTE_INSN_DELETED_LABEL -12
-/* Don't forget to change note_insn_name in rtl.c.  */
+/* This note indicates the start of the real body of the function,
+   i.e. the point just after all of the parms have been moved into
+   their homes, etc.  */
+#define NOTE_INSN_FUNCTION_BEG -13
 
 
 #if 0 /* These are not used, and I don't know what they were for. --rms.  */