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

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

Issue 9395016: First part of new ICData infrastructure: use a wrapper object instead of an array. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 10 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
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 // Class for patching compiled code. 4 // Class for patching compiled code.
5 5
6 #ifndef VM_CODE_PATCHER_H_ 6 #ifndef VM_CODE_PATCHER_H_
7 #define VM_CODE_PATCHER_H_ 7 #define VM_CODE_PATCHER_H_
8 8
9 #include "vm/allocation.h" 9 #include "vm/allocation.h"
10 10
11 namespace dart { 11 namespace dart {
12 12
13 // Forward declaration. 13 // Forward declaration.
14 class Array; 14 class Array;
15 class Code; 15 class Code;
16 class ExternalLabel; 16 class ExternalLabel;
17 class Function; 17 class Function;
18 class RawArray; 18 class RawArray;
regis 2012/02/21 21:51:34 Is RawArray still needed?
srdjan 2012/02/22 14:59:45 Removed
19 class RawICData;
19 class String; 20 class String;
20 21
21 class CodePatcher : public AllStatic { 22 class CodePatcher : public AllStatic {
22 public: 23 public:
23 // Dart static calls have a distinct, machine-dependent code pattern. 24 // Dart static calls have a distinct, machine-dependent code pattern.
24 25
25 // Patch static call to the new target. 26 // Patch static call to the new target.
26 static void PatchStaticCallAt(uword addr, uword new_target_address); 27 static void PatchStaticCallAt(uword addr, uword new_target_address);
27 28
28 // Patch instance call to the new target. 29 // Patch instance call to the new target.
(...skipping 18 matching lines...) Expand all
47 Function* function, 48 Function* function,
48 uword* target); 49 uword* target);
49 50
50 // Get instance call information. 51 // Get instance call information.
51 static void GetInstanceCallAt(uword return_address, 52 static void GetInstanceCallAt(uword return_address,
52 String* function_name, 53 String* function_name,
53 int* num_arguments, 54 int* num_arguments,
54 int* num_named_arguments, 55 int* num_named_arguments,
55 uword* target); 56 uword* target);
56 57
57 static RawArray* GetInstanceCallIcDataAt(uword return_address); 58 static RawICData* GetInstanceCallIcDataAt(uword return_address);
58
59 static void SetInstanceCallIcDataAt(uword return_address,
60 const Array& ic_data);
61 59
62 static intptr_t InstanceCallSizeInBytes(); 60 static intptr_t InstanceCallSizeInBytes();
63 }; 61 };
64 62
65 } // namespace dart 63 } // namespace dart
66 64
67 #endif // VM_CODE_PATCHER_H_ 65 #endif // VM_CODE_PATCHER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698