diff options
| author | Chris Lattner <sabre@nondot.org> | 2002-02-05 04:20:12 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2002-02-05 04:20:12 +0000 |
| commit | 748697d2421051b3ff1263d13cccaf410f3e7034 (patch) | |
| tree | 78b10a43c512846fce169c36f72c2a7a4c9bc43f /lib/Analysis/LiveVar/BBLiveVar.h | |
| parent | 3773094a1da7d7fc76a2491211fadf734c3b8645 (diff) | |
| download | external_llvm-748697d2421051b3ff1263d13cccaf410f3e7034.zip external_llvm-748697d2421051b3ff1263d13cccaf410f3e7034.tar.gz external_llvm-748697d2421051b3ff1263d13cccaf410f3e7034.tar.bz2 | |
Minor change: Methods that return ValueSet's that are guaranteed to be valid
return references instead of pointers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1719 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/LiveVar/BBLiveVar.h')
| -rw-r--r-- | lib/Analysis/LiveVar/BBLiveVar.h | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/lib/Analysis/LiveVar/BBLiveVar.h b/lib/Analysis/LiveVar/BBLiveVar.h index 1fc91f1..442eb22 100644 --- a/lib/Analysis/LiveVar/BBLiveVar.h +++ b/lib/Analysis/LiveVar/BBLiveVar.h @@ -31,11 +31,12 @@ class BBLiveVar { const BasicBlock *PredBB); // To add an operand which is a def - void addDef(const Value *Op); + void addDef(const Value *Op); // To add an operand which is a use - void addUse(const Value *Op); + void addUse(const Value *Op); + void calcDefUseSets(); // calculates the Def & Use sets for this BB public: BBLiveVar(const BasicBlock *BB, unsigned POID); @@ -44,18 +45,16 @@ class BBLiveVar { inline unsigned getPOId() const { return POID; } - void calcDefUseSets(); // calculates the Def & Use sets for this BB bool applyTransferFunc(); // calcultes the In in terms of Out // calculates Out set using In sets of the predecessors bool applyFlowFunc(std::map<const BasicBlock *, BBLiveVar *> &LVMap); - inline const ValueSet *getOutSet() const { return &OutSet; } - inline const ValueSet *getInSet() const { return &InSet; } + inline const ValueSet &getOutSet() const { return OutSet; } + inline const ValueSet &getInSet() const { return InSet; } void printAllSets() const; // for printing Def/In/Out sets void printInOutSets() const; // for printing In/Out sets }; #endif - |
