[llvm-commits] Patch to allow llvm.gcroot to work with non-pointer allocas.
Duncan Sands
baldrick at free.fr
Fri Sep 17 00:32:45 PDT 2010
Hi Talin,
> This patch modifies Verifier.cpp to allow the first argument to llvm.gcroot to
> be a "non-pointer" alloca. This allows you to have an alloca of, say, struct
> type which may contain pointers that need to be traced. Note that the first
> argument is still required to be an alloca, but is no longer required to be an
> alloca of a pointer.
is this really needed? In this situation, can't you just declare two allocas:
your struct alloca, and a pointer alloca that contains the address of the struct
alloca. You then pass the pointer alloca as the gc root.
Ciao,
Duncan.
More information about the llvm-commits
mailing list