Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(340)

Side by Side Diff: src/arm/assembler-arm.cc

Issue 6677076: Merge up to bleeding_edge r7201 to isolates branch. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/isolates
Patch Set: Fix lint. Created 9 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/arm/assembler-arm.h ('k') | src/arm/code-stubs-arm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions 5 // modification, are permitted provided that the following conditions
6 // are met: 6 // are met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 const Instr kLdrStrInstrArgumentMask = 0x0000ffff; 263 const Instr kLdrStrInstrArgumentMask = 0x0000ffff;
264 const Instr kLdrStrOffsetMask = 0x00000fff; 264 const Instr kLdrStrOffsetMask = 0x00000fff;
265 265
266 266
267 // Spare buffer. 267 // Spare buffer.
268 static const int kMinimalBufferSize = 4*KB; 268 static const int kMinimalBufferSize = 4*KB;
269 269
270 270
271 Assembler::Assembler(void* buffer, int buffer_size) 271 Assembler::Assembler(void* buffer, int buffer_size)
272 : positions_recorder_(this), 272 : positions_recorder_(this),
273 allow_peephole_optimization_(false) { 273 allow_peephole_optimization_(false),
274 emit_debug_code_(FLAG_debug_code) {
274 Isolate* isolate = Isolate::Current(); 275 Isolate* isolate = Isolate::Current();
275 allow_peephole_optimization_ = FLAG_peephole_optimization; 276 allow_peephole_optimization_ = FLAG_peephole_optimization;
276 if (buffer == NULL) { 277 if (buffer == NULL) {
277 // Do our own buffer management. 278 // Do our own buffer management.
278 if (buffer_size <= kMinimalBufferSize) { 279 if (buffer_size <= kMinimalBufferSize) {
279 buffer_size = kMinimalBufferSize; 280 buffer_size = kMinimalBufferSize;
280 281
281 if (isolate->assembler_spare_buffer() != NULL) { 282 if (isolate->assembler_spare_buffer() != NULL) {
282 buffer = isolate->assembler_spare_buffer(); 283 buffer = isolate->assembler_spare_buffer();
283 isolate->set_assembler_spare_buffer(NULL); 284 isolate->set_assembler_spare_buffer(NULL);
(...skipping 2097 matching lines...) Expand 10 before | Expand all | Expand 10 after
2381 2382
2382 void Assembler::vcvt_f32_f64(const SwVfpRegister dst, 2383 void Assembler::vcvt_f32_f64(const SwVfpRegister dst,
2383 const DwVfpRegister src, 2384 const DwVfpRegister src,
2384 VFPConversionMode mode, 2385 VFPConversionMode mode,
2385 const Condition cond) { 2386 const Condition cond) {
2386 ASSERT(Isolate::Current()->cpu_features()->IsEnabled(VFP3)); 2387 ASSERT(Isolate::Current()->cpu_features()->IsEnabled(VFP3));
2387 emit(EncodeVCVT(F32, dst.code(), F64, src.code(), mode, cond)); 2388 emit(EncodeVCVT(F32, dst.code(), F64, src.code(), mode, cond));
2388 } 2389 }
2389 2390
2390 2391
2392 void Assembler::vneg(const DwVfpRegister dst,
2393 const DwVfpRegister src,
2394 const Condition cond) {
2395 emit(cond | 0xE*B24 | 0xB*B20 | B16 | dst.code()*B12 |
2396 0x5*B9 | B8 | B6 | src.code());
2397 }
2398
2399
2391 void Assembler::vabs(const DwVfpRegister dst, 2400 void Assembler::vabs(const DwVfpRegister dst,
2392 const DwVfpRegister src, 2401 const DwVfpRegister src,
2393 const Condition cond) { 2402 const Condition cond) {
2394 emit(cond | 0xE*B24 | 0xB*B20 | dst.code()*B12 | 2403 emit(cond | 0xE*B24 | 0xB*B20 | dst.code()*B12 |
2395 0x5*B9 | B8 | 0x3*B6 | src.code()); 2404 0x5*B9 | B8 | 0x3*B6 | src.code());
2396 } 2405 }
2397 2406
2398 2407
2399 void Assembler::vadd(const DwVfpRegister dst, 2408 void Assembler::vadd(const DwVfpRegister dst,
2400 const DwVfpRegister src1, 2409 const DwVfpRegister src1,
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after
2654 BlockConstPoolBefore(pc_offset() + kInstrSize); 2663 BlockConstPoolBefore(pc_offset() + kInstrSize);
2655 } 2664 }
2656 if (rinfo.rmode() != RelocInfo::NONE) { 2665 if (rinfo.rmode() != RelocInfo::NONE) {
2657 // Don't record external references unless the heap will be serialized. 2666 // Don't record external references unless the heap will be serialized.
2658 if (rmode == RelocInfo::EXTERNAL_REFERENCE) { 2667 if (rmode == RelocInfo::EXTERNAL_REFERENCE) {
2659 #ifdef DEBUG 2668 #ifdef DEBUG
2660 if (!Serializer::enabled()) { 2669 if (!Serializer::enabled()) {
2661 Serializer::TooLateToEnableNow(); 2670 Serializer::TooLateToEnableNow();
2662 } 2671 }
2663 #endif 2672 #endif
2664 if (!Serializer::enabled() && !FLAG_debug_code) { 2673 if (!Serializer::enabled() && !emit_debug_code()) {
2665 return; 2674 return;
2666 } 2675 }
2667 } 2676 }
2668 ASSERT(buffer_space() >= kMaxRelocSize); // too late to grow buffer here 2677 ASSERT(buffer_space() >= kMaxRelocSize); // too late to grow buffer here
2669 reloc_info_writer.Write(&rinfo); 2678 reloc_info_writer.Write(&rinfo);
2670 } 2679 }
2671 } 2680 }
2672 2681
2673 2682
2674 void Assembler::CheckConstPool(bool force_emit, bool require_jump) { 2683 void Assembler::CheckConstPool(bool force_emit, bool require_jump) {
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
2775 2784
2776 // Since a constant pool was just emitted, move the check offset forward by 2785 // Since a constant pool was just emitted, move the check offset forward by
2777 // the standard interval. 2786 // the standard interval.
2778 next_buffer_check_ = pc_offset() + kCheckConstInterval; 2787 next_buffer_check_ = pc_offset() + kCheckConstInterval;
2779 } 2788 }
2780 2789
2781 2790
2782 } } // namespace v8::internal 2791 } } // namespace v8::internal
2783 2792
2784 #endif // V8_TARGET_ARCH_ARM 2793 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/assembler-arm.h ('k') | src/arm/code-stubs-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698