Danny Backx wrote: > > I've had little time to spend on this recently, but I've approached > things the other way. If I get far enough, then maybe both may meet. >
Yes. What you're doing would be the very minimum we need to do to have the compiler output the needed structures. > I fiddled with gcc/config/arm/mingw32.h to put stuff around a function. > This is the difference obtained on a small example : > > dannypc: {13} diff nullptr-before.s nullptr.s > 12c12,18 > < .global main > --- >> .global main >> @ ASM_DECLARE_FUNCTION_NAME a >> .global _cegcc_main_data ^^^^^^^ You shouln't need to make these symbols global, but I understand it if you are using it for debug purposes. >> _cegcc_main_data: >> .word 0 /* _cegcc_main_handler */ >> .word 0 /* _cegcc_main_size */ ^^^ This is not supposed to be the size, but a pointer to data to the passed to the handler. The size goes into the .pdata structure, as does the prologue size. It looks like you've already found how to get at the prologue size, as you're outputting "yow prologue" - probably from arm.c, right? > > Right now this is pretty useless, I'd need an interface to be able to > get to this from source. Working on that. > That's when things start getting interesting. Curious on what you are thinking to do it? Are you going to try to change the c parser to understand __try/__except/__finally, or are you looking for a new __attribute__, a new builtin, other? I'm also curious on if we could reuse the runtime support from coredll.dll, like __C_specific_handler. Great to see some work on this! A hint: You can infer a lot of info of SEH on ARM from the more abundant info on SEH on x64, which is similar. Also looking for OS/2 model of exceptions is informative, as it is very similar to SEH on x86 - this is comprehensive as MSFT worked on it. Cheers, Pedro Alves ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Cegcc-devel mailing list Cegcc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/cegcc-devel