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

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

Issue 131853006: Fix debugger stub patching on x64 architecture (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 11 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 | « runtime/vm/debugger_x64.cc ('k') | runtime/vm/instructions_x64.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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 // Classes that describe assembly patterns as used by inline caches. 4 // Classes that describe assembly patterns as used by inline caches.
5 5
6 #ifndef VM_INSTRUCTIONS_X64_H_ 6 #ifndef VM_INSTRUCTIONS_X64_H_
7 #define VM_INSTRUCTIONS_X64_H_ 7 #define VM_INSTRUCTIONS_X64_H_
8 8
9 #ifndef VM_INSTRUCTIONS_H_ 9 #ifndef VM_INSTRUCTIONS_H_
10 #error Do not include instructions_ia32.h directly; use instructions.h instead. 10 #error Do not include instructions_ia32.h directly; use instructions.h instead.
(...skipping 21 matching lines...) Expand all
32 virtual bool IsValid() const { 32 virtual bool IsValid() const {
33 return TestBytesWith(pattern(), pattern_length_in_bytes()); 33 return TestBytesWith(pattern(), pattern_length_in_bytes());
34 } 34 }
35 35
36 // 'pattern' returns the expected byte pattern in form of an integer array 36 // 'pattern' returns the expected byte pattern in form of an integer array
37 // with length of 'pattern_length_in_bytes'. A '-1' element means 'any byte'. 37 // with length of 'pattern_length_in_bytes'. A '-1' element means 'any byte'.
38 virtual const int* pattern() const = 0; 38 virtual const int* pattern() const = 0;
39 virtual int pattern_length_in_bytes() const = 0; 39 virtual int pattern_length_in_bytes() const = 0;
40 40
41 static intptr_t IndexFromPPLoad(uword start); 41 static intptr_t IndexFromPPLoad(uword start);
42 static intptr_t OffsetFromPPIndex(intptr_t index);
42 43
43 protected: 44 protected:
44 uword start() const { return start_; } 45 uword start() const { return start_; }
45 46
46 private: 47 private:
47 // Returns true if the 'num_bytes' bytes at 'start_' correspond to 48 // Returns true if the 'num_bytes' bytes at 'start_' correspond to
48 // array of integers 'data'. 'data' elements are either a byte or -1, which 49 // array of integers 'data'. 'data' elements are either a byte or -1, which
49 // represents any byte. 50 // represents any byte.
50 bool TestBytesWith(const int* data, int num_bytes) const; 51 bool TestBytesWith(const int* data, int num_bytes) const;
51 52
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 static const int kLengthInBytes = 5; 120 static const int kLengthInBytes = 5;
120 virtual const int* pattern() const; 121 virtual const int* pattern() const;
121 122
122 DISALLOW_COPY_AND_ASSIGN(ShortCallPattern); 123 DISALLOW_COPY_AND_ASSIGN(ShortCallPattern);
123 }; 124 };
124 125
125 126
126 } // namespace dart 127 } // namespace dart
127 128
128 #endif // VM_INSTRUCTIONS_X64_H_ 129 #endif // VM_INSTRUCTIONS_X64_H_
OLDNEW
« no previous file with comments | « runtime/vm/debugger_x64.cc ('k') | runtime/vm/instructions_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698