prologue length

Vincent R. forumer@smartmobili.com
Fri Jan 16 16:30:00 GMT 2009


Hi,

I am working on a gcc-4.1.2 and I would like to know how the prologue
length from a function can be calculated.
Indeed I am trying to evaluate what needs to be done to implement SEH and
one requirement is to be able to
fill a structure holding information like function length and prologue
length.
About function length for now a label is emitted to mark the end of
function :

#undef  ASM_DECLARE_FUNCTION_SIZE
#define ASM_DECLARE_FUNCTION_SIZE(STREAM, NAME, DECL)			\
    {									\
	if (arm_exception_handler(STREAM, NAME, DECL))			\
		asm_fprintf (STREAM, ".L%s_end:\n", NAME);		\
    }

but how could I do the same with the prologue ?

Another remark is about libstdc++ and could it be possible to avoid the
keyword __except in include/bits/basic_ios.h
because it brings confusion when trying to implement parsing of SEH.

      void
      exceptions(iostate __except)
      {
        _M_exception = __except;
        this->clear(_M_streambuf_state);
      }



Thanks



More information about the Gcc mailing list