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

Side by Side Diff: vm/stub_code_ia32.cc

Issue 10827249: - Register canonical names for internal VM classes and get rid of the method GetSingletonClassName (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 4 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 | « vm/snapshot_ids.h ('k') | vm/stub_code_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) 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 4
5 #include "vm/globals.h" 5 #include "vm/globals.h"
6 #if defined(TARGET_ARCH_IA32) 6 #if defined(TARGET_ARCH_IA32)
7 7
8 #include "vm/assembler.h" 8 #include "vm/assembler.h"
9 #include "vm/assembler_macros.h" 9 #include "vm/assembler_macros.h"
10 #include "vm/compiler.h" 10 #include "vm/compiler.h"
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after
286 __ movl(EAX, FieldAddress(CTX, Context::isolate_offset())); 286 __ movl(EAX, FieldAddress(CTX, Context::isolate_offset()));
287 __ movl(EAX, Address(EAX, Isolate::object_store_offset())); 287 __ movl(EAX, Address(EAX, Isolate::object_store_offset()));
288 __ movl(EAX, Address(EAX, ObjectStore::object_class_offset())); 288 __ movl(EAX, Address(EAX, ObjectStore::object_class_offset()));
289 289
290 __ Bind(&class_in_eax); 290 __ Bind(&class_in_eax);
291 // Class is in EAX. 291 // Class is in EAX.
292 292
293 Label loop, next_iteration; 293 Label loop, next_iteration;
294 // Get functions_cache, since it is allocated lazily it maybe null. 294 // Get functions_cache, since it is allocated lazily it maybe null.
295 __ movl(EAX, FieldAddress(EAX, Class::functions_cache_offset())); 295 __ movl(EAX, FieldAddress(EAX, Class::functions_cache_offset()));
296 __ cmpl(EAX, raw_null);
297 __ j(EQUAL, &not_found, Assembler::kNearJump);
298
296 // Iterate and search for identical name. 299 // Iterate and search for identical name.
297 __ leal(EBX, FieldAddress(EAX, Array::data_offset())); 300 __ leal(EBX, FieldAddress(EAX, Array::data_offset()));
298 301
299 // EBX is pointing into content of functions_map_ array. 302 // EBX is pointing into content of functions_map_ array.
300 __ Bind(&loop); 303 __ Bind(&loop);
301 __ movl(EDI, Address(EBX, FunctionsCache::kFunctionName * kWordSize)); 304 __ movl(EDI, Address(EBX, FunctionsCache::kFunctionName * kWordSize));
302 305
303 __ cmpl(EDI, raw_null); 306 __ cmpl(EDI, raw_null);
304 __ j(EQUAL, &not_found, Assembler::kNearJump); 307 __ j(EQUAL, &not_found, Assembler::kNearJump);
305 308
(...skipping 1667 matching lines...) Expand 10 before | Expand all | Expand 10 after
1973 __ movl(EAX, Address(ESP, 4 * kWordSize)); // Load error object. 1976 __ movl(EAX, Address(ESP, 4 * kWordSize)); // Load error object.
1974 __ movl(EBP, Address(ESP, 3 * kWordSize)); // Load target frame_pointer. 1977 __ movl(EBP, Address(ESP, 3 * kWordSize)); // Load target frame_pointer.
1975 __ movl(EBX, Address(ESP, 1 * kWordSize)); // Load target PC into EBX. 1978 __ movl(EBX, Address(ESP, 1 * kWordSize)); // Load target PC into EBX.
1976 __ movl(ESP, Address(ESP, 2 * kWordSize)); // Load target stack_pointer. 1979 __ movl(ESP, Address(ESP, 2 * kWordSize)); // Load target stack_pointer.
1977 __ jmp(EBX); // Jump to the exception handler code. 1980 __ jmp(EBX); // Jump to the exception handler code.
1978 } 1981 }
1979 1982
1980 } // namespace dart 1983 } // namespace dart
1981 1984
1982 #endif // defined TARGET_ARCH_IA32 1985 #endif // defined TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « vm/snapshot_ids.h ('k') | vm/stub_code_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698