[LLVMdev] Writing an address space re-numbering pass?

Matt Arsenault Matthew.Arsenault at amd.com
Fri May 16 11:32:44 PDT 2014


On 05/16/2014 06:41 AM, Dan Liew wrote:
> - What do I need to iterate over? I couldn't see an obvious way to
> iterate over Types belonging to a module, so do I just need to iterate
> over "everything" (i.e. Functions, globals, aliases and instructions)
> and somehow iterate over the types that they use? Doing it in the way
> I just described (if it's even possible) sounds like a disaster
> because types are uniqued so I would
I believe the correct way to do this would be to use 
ValueMapTypeRemapper to help you rewrite a function with the same 
instructions, but new types



More information about the llvm-dev mailing list