[LLVMdev] Some questions about building an LLVM frontend

Rafael Espindola espindola at google.com
Sat Aug 25 02:52:54 PDT 2007


> The one example that seems close to what I want is the llc.cpp source
> file; But when I try to do the same thing in my code, I find that the
> TargetMachineRegistry is empty; And yet I see no code in llc.cpp that
> initializes this, nor do I see #includes or Makefile dependencies in the
> llc project that would do this implicitly.
>
> Sincerely Puzzled,

If i remember correctly, all you need to do is link with some of the
target code generators. They use the static constructors to register
them in TargetMachineRegistry.

> -- Talin

Cheers,
-- 
Rafael Avila de Espindola

Google Ireland Ltd.
Gordon House
Barrow Street
Dublin 4
Ireland

Registered in Dublin, Ireland
Registration Number: 368047



More information about the llvm-dev mailing list