[LLVMdev] extracting data and operands
coolhersh at gmail.com
Mon Nov 16 13:25:25 CST 2009
I wish to implement dead code elimination as a pass in llvm. This is not the
same as unreachable block.
For this, I plan to go ahead like this :
In each function
Identify the store and branch operations
Identify the operands involved in these operations.
Build the UD chain of these and check if there is any variable that is
not used and mark its definition (the entire instruction)
Delete all marked instructions.
I have no clue how to do this using llvm. Any help would be greatly
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the LLVMdev