| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 324 Label* fail) { | 324 Label* fail) { |
| 325 mov(map, FieldOperand(heap_object, HeapObject::kMapOffset)); | 325 mov(map, FieldOperand(heap_object, HeapObject::kMapOffset)); |
| 326 IsInstanceJSObjectType(map, scratch, fail); | 326 IsInstanceJSObjectType(map, scratch, fail); |
| 327 } | 327 } |
| 328 | 328 |
| 329 | 329 |
| 330 void MacroAssembler::IsInstanceJSObjectType(Register map, | 330 void MacroAssembler::IsInstanceJSObjectType(Register map, |
| 331 Register scratch, | 331 Register scratch, |
| 332 Label* fail) { | 332 Label* fail) { |
| 333 movzx_b(scratch, FieldOperand(map, Map::kInstanceTypeOffset)); | 333 movzx_b(scratch, FieldOperand(map, Map::kInstanceTypeOffset)); |
| 334 sub(Operand(scratch), Immediate(FIRST_JS_OBJECT_TYPE)); | 334 sub(Operand(scratch), Immediate(FIRST_NONCALLABLE_SPEC_OBJECT_TYPE)); |
| 335 cmp(scratch, LAST_JS_OBJECT_TYPE - FIRST_JS_OBJECT_TYPE); | 335 cmp(scratch, |
| 336 LAST_NONCALLABLE_SPEC_OBJECT_TYPE - FIRST_NONCALLABLE_SPEC_OBJECT_TYPE); |
| 336 j(above, fail); | 337 j(above, fail); |
| 337 } | 338 } |
| 338 | 339 |
| 339 | 340 |
| 340 void MacroAssembler::FCmp() { | 341 void MacroAssembler::FCmp() { |
| 341 if (CpuFeatures::IsSupported(CMOV)) { | 342 if (CpuFeatures::IsSupported(CMOV)) { |
| 342 fucomip(); | 343 fucomip(); |
| 343 ffree(0); | 344 ffree(0); |
| 344 fincstp(); | 345 fincstp(); |
| 345 } else { | 346 } else { |
| (...skipping 1809 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2155 | 2156 |
| 2156 // Check that the code was patched as expected. | 2157 // Check that the code was patched as expected. |
| 2157 ASSERT(masm_.pc_ == address_ + size_); | 2158 ASSERT(masm_.pc_ == address_ + size_); |
| 2158 ASSERT(masm_.reloc_info_writer.pos() == address_ + size_ + Assembler::kGap); | 2159 ASSERT(masm_.reloc_info_writer.pos() == address_ + size_ + Assembler::kGap); |
| 2159 } | 2160 } |
| 2160 | 2161 |
| 2161 | 2162 |
| 2162 } } // namespace v8::internal | 2163 } } // namespace v8::internal |
| 2163 | 2164 |
| 2164 #endif // V8_TARGET_ARCH_IA32 | 2165 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |