Commit 78b2a18d authored by baptiste.afsa@arm.com's avatar baptiste.afsa@arm.com

A64: Remove early_exit unused mechanism in CompareMap.

R=jochen@chromium.org, ulan@chromium.org

Review URL: https://codereview.chromium.org/169733003

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19473 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 53f2aefe
...@@ -2109,7 +2109,7 @@ void LCodeGen::DoCheckMaps(LCheckMaps* instr) { ...@@ -2109,7 +2109,7 @@ void LCodeGen::DoCheckMaps(LCheckMaps* instr) {
Label success; Label success;
for (int i = 0; i < map_set.size(); i++) { for (int i = 0; i < map_set.size(); i++) {
Handle<Map> map = map_set.at(i).handle(); Handle<Map> map = map_set.at(i).handle();
__ CompareMap(map_reg, map, &success); __ CompareMap(map_reg, map);
__ B(eq, &success); __ B(eq, &success);
} }
......
...@@ -3441,18 +3441,14 @@ void MacroAssembler::CompareInstanceType(Register map, ...@@ -3441,18 +3441,14 @@ void MacroAssembler::CompareInstanceType(Register map,
void MacroAssembler::CompareMap(Register obj, void MacroAssembler::CompareMap(Register obj,
Register scratch, Register scratch,
Handle<Map> map, Handle<Map> map) {
Label* early_success) {
// TODO(jbramley): The early_success label isn't used. Remove it.
Ldr(scratch, FieldMemOperand(obj, HeapObject::kMapOffset)); Ldr(scratch, FieldMemOperand(obj, HeapObject::kMapOffset));
CompareMap(scratch, map, early_success); CompareMap(scratch, map);
} }
void MacroAssembler::CompareMap(Register obj_map, void MacroAssembler::CompareMap(Register obj_map,
Handle<Map> map, Handle<Map> map) {
Label* early_success) {
// TODO(jbramley): The early_success label isn't used. Remove it.
Cmp(obj_map, Operand(map)); Cmp(obj_map, Operand(map));
} }
...@@ -3466,10 +3462,8 @@ void MacroAssembler::CheckMap(Register obj, ...@@ -3466,10 +3462,8 @@ void MacroAssembler::CheckMap(Register obj,
JumpIfSmi(obj, fail); JumpIfSmi(obj, fail);
} }
Label success; CompareMap(obj, scratch, map);
CompareMap(obj, scratch, map, &success);
B(ne, fail); B(ne, fail);
Bind(&success);
} }
...@@ -3493,10 +3487,9 @@ void MacroAssembler::CheckMap(Register obj_map, ...@@ -3493,10 +3487,9 @@ void MacroAssembler::CheckMap(Register obj_map,
if (smi_check_type == DO_SMI_CHECK) { if (smi_check_type == DO_SMI_CHECK) {
JumpIfSmi(obj_map, fail); JumpIfSmi(obj_map, fail);
} }
Label success;
CompareMap(obj_map, map, &success); CompareMap(obj_map, map);
B(ne, fail); B(ne, fail);
Bind(&success);
} }
......
...@@ -1307,20 +1307,16 @@ class MacroAssembler : public Assembler { ...@@ -1307,20 +1307,16 @@ class MacroAssembler : public Assembler {
Register type_reg, Register type_reg,
InstanceType type); InstanceType type);
// Compare an object's map with the specified map and its transitioned // Compare an object's map with the specified map. Condition flags are set
// elements maps if mode is ALLOW_ELEMENT_TRANSITION_MAPS. Condition flags are // with result of map compare.
// set with result of map compare. If multiple map compares are required, the
// compare sequences branches to early_success.
void CompareMap(Register obj, void CompareMap(Register obj,
Register scratch, Register scratch,
Handle<Map> map, Handle<Map> map);
Label* early_success = NULL);
// As above, but the map of the object is already loaded into the register // As above, but the map of the object is already loaded into the register
// which is preserved by the code generated. // which is preserved by the code generated.
void CompareMap(Register obj_map, void CompareMap(Register obj_map,
Handle<Map> map, Handle<Map> map);
Label* early_success = NULL);
// Check if the map of an object is equal to a specified map and branch to // Check if the map of an object is equal to a specified map and branch to
// label if not. Skip the smi check if not required (object is known to be a // label if not. Skip the smi check if not required (object is known to be a
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment