Garrison Venn
2010-Jan-09 12:54 UTC
[LLVMdev] Exception Implementation Example added to Wiki
If the powers at be want this, I could easily transform the source to the LLVM coding standards, and add the necessary portable UNIX support--someone else would have to add non-UNIX support although the System library probably helps with this. However I'm guessing the LLVM release flux of the exception system, along with a lack of universal platform, dwarf JIT support might be a hinderance in such an endeavor. I don't know what the current platform boundaries are for either JIT or JIT with dwarf emission, but I do know that the LLVM exception design is being reconsidered for future releases (possibly 2.7?). Also, as noted in the wiki, please see: http://code.google.com/p/tart/ and http://www.incasoftware.de/~kamm/projects/index.php/2008/08/19/exception-handling-in-llvmdc-using-llvm/ for real world implementations. There are many others, as can be seen in the LLVM project page. Garrison On Jan 8, 2010, at 20:06, OvermindDL1 wrote:> On Fri, Jan 8, 2010 at 12:12 PM, Garrison Venn <gvenn.cfe.dev at gmail.com> wrote: >> I just added an exception example to the wiki intended to be run in a JIT environment. Although this information is heavily date dependent, >> as the LLVM exception subsystem will be modified as time goes on, I could have used such an example when I was looking into this; hence the submission. >> Having said this, I'm not an LLVM expert, and even though the code works, I'm sure there are omissions and inaccuracies, so if the experts have >> the time ... >> >> Hopefully some members of the community will find this beneficial >> >> Garrison >> >> PS: Is there a better to upload source to the wiki than merely pasting it in? Only image file types seemed to be allowed for upload. > > > Oh I could definitely use an example like that, would be very nice if > there was such an example as an included project in LLVM itself like > the other examples and tutorials, would force it to stay updated too. > > EDIT: Er, helps if I send to the LLVM list... > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
OvermindDL1
2010-Jan-09 13:07 UTC
[LLVMdev] Exception Implementation Example added to Wiki
On Sat, Jan 9, 2010 at 5:54 AM, Garrison Venn <gvenn.cfe.dev at gmail.com> wrote:> If the powers at be want this, I could easily transform the source to the LLVM coding standards, and add > the necessary portable UNIX support--someone else would have to add non-UNIX support although the > System library probably helps with this. However I'm guessing the LLVM release flux of the exception system, > along with a lack of universal platform, dwarf JIT support might be a hinderance in such an endeavor. I don't > know what the current platform boundaries are for either JIT or JIT with dwarf emission, but I do know that > the LLVM exception design is being reconsidered for future releases (possibly 2.7?). > > Also, as noted in the wiki, please see: > > http://code.google.com/p/tart/ and > http://www.incasoftware.de/~kamm/projects/index.php/2008/08/19/exception-handling-in-llvmdc-using-llvm/ > > for real world implementations. There are many others, as can be seen in the LLVM project page.I am one such non-unix platform, so if the example does not work for me, it is still as worthless as bad documentation for note...
Garrison Venn
2010-Jan-09 13:39 UTC
[LLVMdev] Exception Implementation Example added to Wiki
Understood. Sorry for my lack of background on these platforms. Do you know if llvm.eh.selector and dwarf emission for a JIT execution environment works on your platform of choice? If so, and if the unwind system conforms to http://refspecs.freestandards.org/abi-eh-1.21.html, the port will not be too bad. Beyond use of fprintf and strtoul, and an include of unwind.h, I don't believe there is much else that is specific to UNIX. These may even exist in your platform's headers. The structures/APIs defined in unwind.h are fully defined and useable as is in http://refspecs.freestandards.org/abi-eh-1.21.html. Garrison On Jan 9, 2010, at 8:07, OvermindDL1 wrote:> On Sat, Jan 9, 2010 at 5:54 AM, Garrison Venn <gvenn.cfe.dev at gmail.com> wrote: >> If the powers at be want this, I could easily transform the source to the LLVM coding standards, and add >> the necessary portable UNIX support--someone else would have to add non-UNIX support although the >> System library probably helps with this. However I'm guessing the LLVM release flux of the exception system, >> along with a lack of universal platform, dwarf JIT support might be a hinderance in such an endeavor. I don't >> know what the current platform boundaries are for either JIT or JIT with dwarf emission, but I do know that >> the LLVM exception design is being reconsidered for future releases (possibly 2.7?). >> >> Also, as noted in the wiki, please see: >> >> http://code.google.com/p/tart/ and >> http://www.incasoftware.de/~kamm/projects/index.php/2008/08/19/exception-handling-in-llvmdc-using-llvm/ >> >> for real world implementations. There are many others, as can be seen in the LLVM project page. > > I am one such non-unix platform, so if the example does not work for > me, it is still as worthless as bad documentation for note... > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev