[LLVMdev] LLVM Graph Representation

Eli Friedman eli.friedman at gmail.com
Mon Jul 6 14:54:33 PDT 2009


On Mon, Jul 6, 2009 at 2:25 PM, Andre Tavares<andrelct at dcc.ufmg.br> wrote:
> Why not use SmallPtrSet instead of std::vector? Isn't there something in
> LLVM I can use?

SmallPtrSet would work as well; whether it matters depends on the
sorts of lookups you're trying to do.  As far as I know, there isn't
anything builtin, though; none of the existing passes have any use for
such a datastructure.

Again, I would suggest looking at the algorithm and checking whether
you really need to explicitly construct the graph.

-Eli



More information about the llvm-dev mailing list