1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 19:12:56 +02:00

Do not count kill, implicit_def instructions as printed instructions.

llvm-svn: 102453
This commit is contained in:
Evan Cheng 2010-04-27 19:38:45 +00:00
parent a9c1328501
commit 2aaefc6167
2 changed files with 5 additions and 5 deletions

View File

@ -531,11 +531,11 @@ void AsmPrinter::EmitFunctionBody() {
for (MachineBasicBlock::const_iterator II = I->begin(), IE = I->end();
II != IE; ++II) {
// Print the assembly for the instruction.
if (!II->isLabel())
if (!II->isLabel() && !II->isImplicitDef() && !II->isKill()) {
HasAnyRealCode = true;
++EmittedInsts;
++EmittedInsts;
}
if (ShouldPrintDebugScopes) {
if (TimePassesIsEnabled) {
NamedRegionTimer T(DbgTimerName, DWARFGroupName);

View File

@ -1,5 +1,5 @@
; RUN: llc < %s -march=x86-64 -o %t -stats -info-output-file - | \
; RUN: grep {asm-printer} | grep {Number of machine instrs printed} | grep 10
; RUN: grep {asm-printer} | grep {Number of machine instrs printed} | grep 9
; RUN: grep {leal 1(\%rsi),} %t
define fastcc zeroext i8 @fullGtU(i32 %i1, i32 %i2, i8* %ptr) nounwind optsize {