This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] RFA add dwarf calling convention support
- From: Eric Christopher <echristo at redhat dot com>
- To: Jason Merrill <jason at redhat dot com>
- Cc: Richard Henderson <rth at redhat dot com>, gcc-patches at gcc dot gnu dot org
- Date: Fri, 01 Oct 2004 16:23:49 -0700
- Subject: Re: [patch] RFA add dwarf calling convention support
- References: <1096581377.20484.23.camel@localhost.localdomain> <20040930223006.GA9654@redhat.com> <1096588618.30127.1.camel@localhost.localdomain> <xypy8iq2siw.fsf@miranda.boston.redhat.com>
How's this then? Just built cc1 with it for now.
-eric
--
Eric Christopher <echristo@redhat.com>
2004-10-01 Eric Christopher <echristo@redhat.com>
* dwarf2.h (dwarf_calling_convention): Add GNU prefix to
locally defined enum.
* dwarf2out.c (add_calling_convention_attribute): Don't
emit DW_CC_normal.
Index: dwarf2.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/dwarf2.h,v
retrieving revision 1.27
diff -u -p -w -r1.27 dwarf2.h
--- dwarf2.h 1 Oct 2004 05:08:55 -0000 1.27
+++ dwarf2.h 1 Oct 2004 23:19:43 -0000
@@ -475,7 +475,7 @@ enum dwarf_calling_convention
DW_CC_normal = 0x1,
DW_CC_program = 0x2,
DW_CC_nocall = 0x3,
- DW_CC_renesas_sh = 0x40
+ DW_CC_GNU_renesas_sh = 0x40
};
#define DW_CC_lo_user 0x40
Index: dwarf2out.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/dwarf2out.c,v
retrieving revision 1.551
diff -u -p -w -r1.551 dwarf2out.c
--- dwarf2out.c 1 Oct 2004 05:08:55 -0000 1.551
+++ dwarf2out.c 1 Oct 2004 23:19:45 -0000
@@ -10631,8 +10631,9 @@ add_calling_convention_attribute (dw_die
value = targetm.dwarf_calling_convention (type);
- /* Only add the attribute if the backend requests it. */
- if (value)
+ /* Only add the attribute if the backend requests it, and
+ is not DW_CC_normal. */
+ if (value && (value != DW_CC_normal))
add_AT_unsigned (subr_die, DW_AT_calling_convention, value);
}