[llvm-commits] CVS: llvm/lib/Bytecode/Writer/WriteInst.cpp
Chris Lattner
lattner at cs.uiuc.edu
Tue Jan 21 14:14:01 PST 2003
Changes in directory llvm/lib/Bytecode/Writer:
WriteInst.cpp updated: 1.26 -> 1.27
---
Log message:
Don't keep track of # big vs #small instructions seperately
---
Diffs of the changes:
Index: llvm/lib/Bytecode/Writer/WriteInst.cpp
diff -u llvm/lib/Bytecode/Writer/WriteInst.cpp:1.26 llvm/lib/Bytecode/Writer/WriteInst.cpp:1.27
--- llvm/lib/Bytecode/Writer/WriteInst.cpp:1.26 Tue Oct 1 17:38:32 2002
+++ llvm/lib/Bytecode/Writer/WriteInst.cpp Tue Jan 21 14:13:49 2003
@@ -18,9 +18,7 @@
#include <algorithm>
static Statistic<>
-NumOversized("bytecodewriter", "Number of oversized instructions");
-static Statistic<>
-NumNormal("bytecodewriter", "Number of normal instructions");
+NumInstrs("bytecodewriter", "Number of instructions");
typedef unsigned char uchar;
@@ -52,7 +50,6 @@
}
align32(Out); // We must maintain correct alignment!
- ++NumOversized;
}
@@ -102,7 +99,6 @@
output_vbr((unsigned)Slot, Out);
}
align32(Out); // We must maintain correct alignment!
- ++NumOversized;
}
@@ -124,7 +120,6 @@
unsigned Bits = 1 | (Opcode << 2) | (Type << 8) | (Slots[0] << 20);
// cerr << "1 " << IType << " " << Type << " " << Slots[0] << endl;
output(Bits, Out);
- ++NumNormal;
}
@@ -149,7 +144,6 @@
// cerr << "2 " << IType << " " << Type << " " << Slots[0] << " "
// << Slots[1] << endl;
output(Bits, Out);
- ++NumNormal;
}
@@ -175,7 +169,6 @@
//cerr << "3 " << IType << " " << Type << " " << Slots[0] << " "
// << Slots[1] << " " << Slots[2] << endl;
output(Bits, Out);
- ++NumNormal;
}
void BytecodeWriter::processInstruction(const Instruction &I) {
@@ -245,6 +238,8 @@
return;
}
}
+
+ ++NumInstrs;
// Decide which instruction encoding to use. This is determined primarily by
// the number of operands, and secondarily by whether or not the max operand
More information about the llvm-commits
mailing list