[LLVMdev] Patch to allow llvm.gcroot to work with non-pointer allocas.

Talin viridia at gmail.com
Wed Sep 22 08:52:50 PDT 2010


I'm moving this thread to llvm-dev in the hopes of reaching a wider
audience.

This patch relaxes the restriction on llvm.gcroot so that it can work with
non-pointer allocas. The only changes are to Verifier.cpp - it appears from
my testing that llvm.gcroot always worked fine with non-pointer allocas,
except that the verifier wouldn't allow it. I've used this patch to build an
efficient stack crawler (an alternative to shadow-stack that uses only
static constant data structures.)

Here's a deal: If you accept this patch, I'll write up an extensive tutorial
on how to write a stack crawler like mine. (Actually, it's already written,
however without this patch the tutorial doesn't make any sense.)

-- 
-- Talin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20100922/b2265924/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gcroot.patch
Type: text/x-patch
Size: 1025 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20100922/b2265924/attachment.bin>


More information about the llvm-dev mailing list