OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
453 // Compare object type for heap object. | 453 // Compare object type for heap object. |
454 // Always use unsigned comparisons: above and below, not less and greater. | 454 // Always use unsigned comparisons: above and below, not less and greater. |
455 // Incoming register is heap_object and outgoing register is map. | 455 // Incoming register is heap_object and outgoing register is map. |
456 // They may be the same register, and may be kScratchRegister. | 456 // They may be the same register, and may be kScratchRegister. |
457 void CmpObjectType(Register heap_object, InstanceType type, Register map); | 457 void CmpObjectType(Register heap_object, InstanceType type, Register map); |
458 | 458 |
459 // Compare instance type for map. | 459 // Compare instance type for map. |
460 // Always use unsigned comparisons: above and below, not less and greater. | 460 // Always use unsigned comparisons: above and below, not less and greater. |
461 void CmpInstanceType(Register map, InstanceType type); | 461 void CmpInstanceType(Register map, InstanceType type); |
462 | 462 |
| 463 // Check if the map of an object is equal to a specified map and |
| 464 // branch to label if not. Skip the smi check if not required |
| 465 // (object is known to be a heap object) |
| 466 void CheckMap(Register obj, |
| 467 Handle<Map> map, |
| 468 Label* fail, |
| 469 bool is_heap_object); |
| 470 |
463 // Check if the object in register heap_object is a string. Afterwards the | 471 // Check if the object in register heap_object is a string. Afterwards the |
464 // register map contains the object map and the register instance_type | 472 // register map contains the object map and the register instance_type |
465 // contains the instance_type. The registers map and instance_type can be the | 473 // contains the instance_type. The registers map and instance_type can be the |
466 // same in which case it contains the instance type afterwards. Either of the | 474 // same in which case it contains the instance type afterwards. Either of the |
467 // registers map and instance_type can be the same as heap_object. | 475 // registers map and instance_type can be the same as heap_object. |
468 Condition IsObjectStringType(Register heap_object, | 476 Condition IsObjectStringType(Register heap_object, |
469 Register map, | 477 Register map, |
470 Register instance_type); | 478 Register instance_type); |
471 | 479 |
472 // FCmp is similar to integer cmp, but requires unsigned | 480 // FCmp is similar to integer cmp, but requires unsigned |
(...skipping 331 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
804 } \ | 812 } \ |
805 masm-> | 813 masm-> |
806 #else | 814 #else |
807 #define ACCESS_MASM(masm) masm-> | 815 #define ACCESS_MASM(masm) masm-> |
808 #endif | 816 #endif |
809 | 817 |
810 | 818 |
811 } } // namespace v8::internal | 819 } } // namespace v8::internal |
812 | 820 |
813 #endif // V8_X64_MACRO_ASSEMBLER_X64_H_ | 821 #endif // V8_X64_MACRO_ASSEMBLER_X64_H_ |
OLD | NEW |