1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 04:02:41 +01:00

hasSideEffects should be marked virtual

stores and free's have sideeffects

llvm-svn: 170
This commit is contained in:
Chris Lattner 2001-07-09 19:38:26 +00:00
parent 9240fe6721
commit a36e2a7fbe
2 changed files with 5 additions and 1 deletions

View File

@ -39,7 +39,7 @@ public:
//
inline const BasicBlock *getParent() const { return Parent; }
inline BasicBlock *getParent() { return Parent; }
bool hasSideEffects() const { return false; } // Memory & Call insts = true
virtual bool hasSideEffects() const { return false; } // Memory & Call insts
// ---------------------------------------------------------------------------
// Subclass classification... getInstType() returns a member of

View File

@ -95,6 +95,8 @@ public:
virtual Instruction *clone() const { return new FreeInst(Operands[0]); }
virtual const char *getOpcodeName() const { return "free"; }
virtual bool hasSideEffects() const { return true; }
};
@ -155,6 +157,8 @@ public:
const string &Name = "");
virtual Instruction *clone() const { return new StoreInst(*this); }
virtual const char *getOpcodeName() const { return "store"; }
virtual bool hasSideEffects() const { return true; }
};