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

Side by Side Diff: runtime/vm/assembler_arm.h

Issue 12378080: Adds mrc instruction to arm simulator, assembler, disassembler. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 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 | « no previous file | runtime/vm/assembler_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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_ASSEMBLER_ARM_H_ 5 #ifndef VM_ASSEMBLER_ARM_H_
6 #define VM_ASSEMBLER_ARM_H_ 6 #define VM_ASSEMBLER_ARM_H_
7 7
8 #ifndef VM_ASSEMBLER_H_ 8 #ifndef VM_ASSEMBLER_H_
9 #error Do not include assembler_arm.h directly; use assembler.h instead. 9 #error Do not include assembler_arm.h directly; use assembler.h instead.
10 #endif 10 #endif
11 11
12 #include "platform/assert.h" 12 #include "platform/assert.h"
13 #include "platform/utils.h" 13 #include "platform/utils.h"
14 #include "vm/constants_arm.h" 14 #include "vm/constants_arm.h"
15 #include "vm/simulator.h"
15 16
16 namespace dart { 17 namespace dart {
17 18
18 class Label : public ValueObject { 19 class Label : public ValueObject {
19 public: 20 public:
20 Label() : position_(0) { } 21 Label() : position_(0) { }
21 22
22 ~Label() { 23 ~Label() {
23 // Assert if label is being destroyed with unresolved branches pending. 24 // Assert if label is being destroyed with unresolved branches pending.
24 ASSERT(!IsLinked()); 25 ASSERT(!IsLinked());
(...skipping 29 matching lines...) Expand all
54 ASSERT(IsLinked()); 55 ASSERT(IsLinked());
55 } 56 }
56 57
57 friend class Assembler; 58 friend class Assembler;
58 DISALLOW_COPY_AND_ASSIGN(Label); 59 DISALLOW_COPY_AND_ASSIGN(Label);
59 }; 60 };
60 61
61 62
62 class CPUFeatures : public AllStatic { 63 class CPUFeatures : public AllStatic {
63 public: 64 public:
64 static void InitOnce() { } 65 static void InitOnce();
65 static bool double_truncate_round_supported() { 66 static bool double_truncate_round_supported() {
66 UNIMPLEMENTED(); 67 UNIMPLEMENTED();
67 return false; 68 return false;
68 } 69 }
70 static bool integer_division_supported();
71 #if defined(USING_SIMULATOR)
72 static void set_integer_division_supported(bool supported);
73 #endif
74 private:
75 static bool integer_division_supported_;
76 #if defined(DEBUG)
77 static bool initialized_;
78 #endif
69 }; 79 };
70 80
71 81
72 // Encodes Addressing Mode 1 - Data-processing operands. 82 // Encodes Addressing Mode 1 - Data-processing operands.
73 class ShifterOperand : public ValueObject { 83 class ShifterOperand : public ValueObject {
74 public: 84 public:
75 // Data-processing operands - Uninitialized. 85 // Data-processing operands - Uninitialized.
76 ShifterOperand() : type_(-1), encoding_(-1) { } 86 ShifterOperand() : type_(-1), encoding_(-1) { }
77 87
78 // Data-processing operands - Copy constructor. 88 // Data-processing operands - Copy constructor.
(...skipping 402 matching lines...) Expand 10 before | Expand all | Expand 10 after
481 void vcmpsz(SRegister sd, Condition cond = AL); 491 void vcmpsz(SRegister sd, Condition cond = AL);
482 void vcmpdz(DRegister dd, Condition cond = AL); 492 void vcmpdz(DRegister dd, Condition cond = AL);
483 void vmstat(Condition cond = AL); // VMRS APSR_nzcv, FPSCR 493 void vmstat(Condition cond = AL); // VMRS APSR_nzcv, FPSCR
484 494
485 // Branch instructions. 495 // Branch instructions.
486 void b(Label* label, Condition cond = AL); 496 void b(Label* label, Condition cond = AL);
487 void bl(Label* label, Condition cond = AL); 497 void bl(Label* label, Condition cond = AL);
488 void bx(Register rm, Condition cond = AL); 498 void bx(Register rm, Condition cond = AL);
489 void blx(Register rm, Condition cond = AL); 499 void blx(Register rm, Condition cond = AL);
490 500
501 // Move to ARM core register from Coprocessor.
502 void mrc(Register rd, int32_t coproc, int32_t opc1,
503 int32_t crn, int32_t crm, int32_t opc2, Condition cond = AL);
504
491 // Macros. 505 // Macros.
492 // Branch to an entry address. Call sequence is never patched. 506 // Branch to an entry address. Call sequence is never patched.
493 void Branch(const ExternalLabel* label, Condition cond = AL); 507 void Branch(const ExternalLabel* label, Condition cond = AL);
494 508
495 // Branch and link to an entry address. Call sequence is never patched. 509 // Branch and link to an entry address. Call sequence is never patched.
496 void BranchLink(const ExternalLabel* label); 510 void BranchLink(const ExternalLabel* label);
497 511
498 // Branch and link to an entry address. Call sequence can be patched. 512 // Branch and link to an entry address. Call sequence can be patched.
499 void BranchLinkPatchable(const ExternalLabel* label); 513 void BranchLinkPatchable(const ExternalLabel* label);
500 514
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
702 return *reg1 - *reg2; 716 return *reg1 - *reg2;
703 } 717 }
704 718
705 DISALLOW_ALLOCATION(); 719 DISALLOW_ALLOCATION();
706 DISALLOW_COPY_AND_ASSIGN(Assembler); 720 DISALLOW_COPY_AND_ASSIGN(Assembler);
707 }; 721 };
708 722
709 } // namespace dart 723 } // namespace dart
710 724
711 #endif // VM_ASSEMBLER_ARM_H_ 725 #endif // VM_ASSEMBLER_ARM_H_
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/assembler_arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698