6858208: jvm crash when specifying TypeProfileWidth=0 on jdk 6.0

Add an explicit check for TypeProfileWidth == 0 in record_klass_in_profile_helper() functions.

Reviewed-by: never, coleenp
This commit is contained in:
Poonam Bajaj 2009-09-01 23:34:08 -07:00
parent 13516fe398
commit c04761e799
3 changed files with 9 additions and 0 deletions

View File

@ -1696,6 +1696,9 @@ void InterpreterMacroAssembler::profile_virtual_call(Register receiver,
void InterpreterMacroAssembler::record_klass_in_profile_helper(
Register receiver, Register scratch,
int start_row, Label& done) {
if (TypeProfileWidth == 0)
return;
int last_row = VirtualCallData::row_limit() - 1;
assert(start_row <= last_row, "must be work left to do");
// Test this row for both the receiver and for null.

View File

@ -1262,6 +1262,9 @@ void InterpreterMacroAssembler::record_klass_in_profile_helper(
Register receiver, Register mdp,
Register reg2,
int start_row, Label& done) {
if (TypeProfileWidth == 0)
return;
int last_row = VirtualCallData::row_limit() - 1;
assert(start_row <= last_row, "must be work left to do");
// Test this row for both the receiver and for null.

View File

@ -1272,6 +1272,9 @@ void InterpreterMacroAssembler::record_klass_in_profile_helper(
Register receiver, Register mdp,
Register reg2,
int start_row, Label& done) {
if (TypeProfileWidth == 0)
return;
int last_row = VirtualCallData::row_limit() - 1;
assert(start_row <= last_row, "must be work left to do");
// Test this row for both the receiver and for null.