mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-04 06:09:05 +00:00
Inline trivial constructors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13797 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
b03de0c780
commit
f6e8cb4954
@ -99,12 +99,26 @@ public:
|
||||
// BranchInst(BB* T, BB *F, Value *C, Inst *I) - 'br C, T, F', insert before I
|
||||
// BranchInst(BB* B, BB *I) - 'br B' insert at end
|
||||
// BranchInst(BB* T, BB *F, Value *C, BB *I) - 'br C, T, F', insert at end
|
||||
BranchInst(BasicBlock *IfTrue, Instruction *InsertBefore = 0);
|
||||
BranchInst(BasicBlock *IfTrue, BasicBlock *IfFalse, Value *cond,
|
||||
Instruction *InsertBefore = 0);
|
||||
BranchInst(BasicBlock *IfTrue, BasicBlock *InsertAtEnd);
|
||||
BranchInst(BasicBlock *IfTrue, BasicBlock *IfFalse, Value *cond,
|
||||
BasicBlock *InsertAtEnd);
|
||||
BranchInst(BasicBlock *IfTrue, Instruction *InsertBefore = 0)
|
||||
: TerminatorInst(Instruction::Br, InsertBefore) {
|
||||
init(IfTrue);
|
||||
}
|
||||
BranchInst(BasicBlock *IfTrue, BasicBlock *IfFalse, Value *Cond,
|
||||
Instruction *InsertBefore = 0)
|
||||
: TerminatorInst(Instruction::Br, InsertBefore) {
|
||||
init(IfTrue, IfFalse, Cond);
|
||||
}
|
||||
|
||||
BranchInst(BasicBlock *IfTrue, BasicBlock *InsertAtEnd)
|
||||
: TerminatorInst(Instruction::Br, InsertAtEnd) {
|
||||
init(IfTrue);
|
||||
}
|
||||
|
||||
BranchInst(BasicBlock *IfTrue, BasicBlock *IfFalse, Value *Cond,
|
||||
BasicBlock *InsertAtEnd)
|
||||
: TerminatorInst(Instruction::Br, InsertAtEnd) {
|
||||
init(IfTrue, IfFalse, Cond);
|
||||
}
|
||||
|
||||
virtual Instruction *clone() const { return new BranchInst(*this); }
|
||||
|
||||
@ -168,8 +182,14 @@ class SwitchInst : public TerminatorInst {
|
||||
void init(Value *Value, BasicBlock *Default);
|
||||
|
||||
public:
|
||||
SwitchInst(Value *Value, BasicBlock *Default, Instruction *InsertBefore = 0);
|
||||
SwitchInst(Value *Value, BasicBlock *Default, BasicBlock *InsertAtEnd);
|
||||
SwitchInst(Value *Value, BasicBlock *Default, Instruction *InsertBefore = 0)
|
||||
: TerminatorInst(Instruction::Switch, InsertBefore) {
|
||||
init(Value, Default);
|
||||
}
|
||||
SwitchInst(Value *Value, BasicBlock *Default, BasicBlock *InsertAtEnd)
|
||||
: TerminatorInst(Instruction::Switch, InsertAtEnd) {
|
||||
init(Value, Default);
|
||||
}
|
||||
|
||||
virtual Instruction *clone() const { return new SwitchInst(*this); }
|
||||
|
||||
|
@ -47,28 +47,6 @@ void BranchInst::init(BasicBlock *IfTrue, BasicBlock *IfFalse, Value *Cond)
|
||||
Operands.push_back(Use(Cond, this));
|
||||
}
|
||||
|
||||
BranchInst::BranchInst(BasicBlock *True, BasicBlock *False, Value *Cond,
|
||||
Instruction *InsertBefore)
|
||||
: TerminatorInst(Instruction::Br, InsertBefore) {
|
||||
init(True, False, Cond);
|
||||
}
|
||||
|
||||
BranchInst::BranchInst(BasicBlock *True, BasicBlock *False, Value *Cond,
|
||||
BasicBlock *InsertAtEnd)
|
||||
: TerminatorInst(Instruction::Br, InsertAtEnd) {
|
||||
init(True, False, Cond);
|
||||
}
|
||||
|
||||
BranchInst::BranchInst(BasicBlock *True, Instruction *InsertBefore)
|
||||
: TerminatorInst(Instruction::Br, InsertBefore) {
|
||||
init(True);
|
||||
}
|
||||
|
||||
BranchInst::BranchInst(BasicBlock *True, BasicBlock *InsertAtEnd)
|
||||
: TerminatorInst(Instruction::Br, InsertAtEnd) {
|
||||
init(True);
|
||||
}
|
||||
|
||||
BranchInst::BranchInst(const BranchInst &BI) : TerminatorInst(Instruction::Br) {
|
||||
Operands.reserve(BI.Operands.size());
|
||||
Operands.push_back(Use(BI.Operands[0], this));
|
||||
|
@ -22,17 +22,6 @@ void SwitchInst::init(Value *Value, BasicBlock *Default)
|
||||
Operands.push_back(Use(Default, this));
|
||||
}
|
||||
|
||||
SwitchInst::SwitchInst(Value *V, BasicBlock *D,
|
||||
Instruction *InsertBefore)
|
||||
: TerminatorInst(Instruction::Switch, InsertBefore) {
|
||||
init(V, D);
|
||||
}
|
||||
|
||||
SwitchInst::SwitchInst(Value *V, BasicBlock *D, BasicBlock *InsertAtEnd)
|
||||
: TerminatorInst(Instruction::Switch, InsertAtEnd) {
|
||||
init(V, D);
|
||||
}
|
||||
|
||||
SwitchInst::SwitchInst(const SwitchInst &SI)
|
||||
: TerminatorInst(Instruction::Switch) {
|
||||
Operands.reserve(SI.Operands.size());
|
||||
|
Loading…
Reference in New Issue
Block a user