[llvm-commits] CVS: llvm/include/llvm/Analysis/Dominators.h
Chris Lattner
clattner at apple.com
Thu Apr 19 22:24:23 PDT 2007
On Apr 19, 2007, at 11:10 AM, Devang Patel wrote:
>
> On Apr 17, 2007, at 9:38 PM, Owen Anderson wrote:
>
>> Index: llvm/include/llvm/Analysis/Dominators.h
>> diff -u llvm/include/llvm/Analysis/Dominators.h:1.72 llvm/include/
>> llvm/Analysis/Dominators.h:1.73
>> --- llvm/include/llvm/Analysis/Dominators.h:1.72 Sun Apr 15 18:14:18
>> 2007
>> +++ llvm/include/llvm/Analysis/Dominators.h Tue Apr 17 23:38:39 2007
>> @@ -320,6 +320,13 @@
>> return NULL;
>> return Common->getData<BasicBlock>();
>> }
>> +
>> + /// Return the immediate dominator of A.
>> + BasicBlock *getIDom(BasicBlock *A) {
>> + ETNode *NodeA = getNode(A);
>
> Please add an assert to check that NodeA is not null. Thanks!
Also, please mark this method const :)
-Chris
More information about the llvm-commits
mailing list