Skip to content

Commit d8a549c

Browse files
committed
fix: mips rate not taking into account SIE executed instructions
The instruction count must be maintained in "regs" (the host CPU) not "GUESTREGS" (the virtual SIE cpu) The results are then tallied per CPU by timer.c which is responsible for triggering a panel refresh.
1 parent eab6bf3 commit d8a549c

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

sie.c

+6-6
Original file line numberDiff line numberDiff line change
@@ -1058,7 +1058,7 @@ static int ARCH_DEP( run_sie )( REGS* regs )
10581058

10591059
PROCESS_TRACE( GUESTREGS, ip, sie_fetch_instruction );
10601060
EXECUTE_INSTRUCTION( current_opcode_table, ip, GUESTREGS );
1061-
GUESTREGS->instcount++;
1061+
regs->instcount++;
10621062
UPDATE_SYSBLK_INSTCOUNT( 1 );
10631063
SIE_PERFMON( SIE_PERF_EXEC_U );
10641064

@@ -1067,7 +1067,7 @@ static int ARCH_DEP( run_sie )( REGS* regs )
10671067
UNROLLED_EXECUTE( current_opcode_table, GUESTREGS );
10681068
UNROLLED_EXECUTE( current_opcode_table, GUESTREGS );
10691069
}
1070-
GUESTREGS->instcount += (i * 2);
1070+
regs->instcount += (i * 2);
10711071
UPDATE_SYSBLK_INSTCOUNT( (i * 2) );
10721072

10731073
/* Perform automatic instruction tracing if it's enabled */
@@ -1085,7 +1085,7 @@ static int ARCH_DEP( run_sie )( REGS* regs )
10851085

10861086
PROCESS_TRACE( GUESTREGS, ip, sie_fetch_instruction );
10871087
EXECUTE_INSTRUCTION( current_opcode_table, ip, GUESTREGS );
1088-
GUESTREGS->instcount++;
1088+
regs->instcount++;
10891089
UPDATE_SYSBLK_INSTCOUNT( 1 );
10901090
SIE_PERFMON( SIE_PERF_EXEC_U );
10911091

@@ -1101,7 +1101,7 @@ static int ARCH_DEP( run_sie )( REGS* regs )
11011101

11021102
UNROLLED_EXECUTE( current_opcode_table, GUESTREGS );
11031103
}
1104-
GUESTREGS->instcount += (i * 2);
1104+
regs->instcount += (i * 2);
11051105
UPDATE_SYSBLK_INSTCOUNT( (i * 2) );
11061106

11071107
/* Perform automatic instruction tracing if it's enabled */
@@ -1112,7 +1112,7 @@ static int ARCH_DEP( run_sie )( REGS* regs )
11121112

11131113
PROCESS_TRACE( GUESTREGS, ip, sie_fetch_instruction );
11141114
TXF_EXECUTE_INSTRUCTION( current_opcode_table, ip, GUESTREGS );
1115-
GUESTREGS->instcount++;
1115+
regs->instcount++;
11161116
UPDATE_SYSBLK_INSTCOUNT( 1 );
11171117
SIE_PERFMON( SIE_PERF_EXEC_U );
11181118

@@ -1128,7 +1128,7 @@ static int ARCH_DEP( run_sie )( REGS* regs )
11281128

11291129
TXF_UNROLLED_EXECUTE( current_opcode_table, GUESTREGS );
11301130
}
1131-
GUESTREGS->instcount += (i * 2);
1131+
regs->instcount += (i * 2);
11321132
UPDATE_SYSBLK_INSTCOUNT( (i * 2) );
11331133

11341134
/* Perform automatic instruction tracing if it's enabled */

0 commit comments

Comments
 (0)