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

Side by Side Diff: runtime/vm/disassembler_ia32.cc

Issue 2226893002: Optimize AOT's switchable calls for the monomorphic case. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: sync Created 4 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
« no previous file with comments | « runtime/vm/disassembler.cc ('k') | runtime/vm/exceptions.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 4
5 #include "vm/disassembler.h" 5 #include "vm/disassembler.h"
6 6
7 #include "vm/globals.h" // Needed here to get TARGET_ARCH_IA32. 7 #include "vm/globals.h" // Needed here to get TARGET_ARCH_IA32.
8 #if defined(TARGET_ARCH_IA32) 8 #if defined(TARGET_ARCH_IA32)
9 #include "platform/utils.h" 9 #include "platform/utils.h"
10 #include "vm/allocation.h" 10 #include "vm/allocation.h"
(...skipping 1798 matching lines...) Expand 10 before | Expand all | Expand 10 after
1809 } 1809 }
1810 hex_buffer[hex_index] = '\0'; 1810 hex_buffer[hex_index] = '\0';
1811 if (out_instr_len) { 1811 if (out_instr_len) {
1812 *out_instr_len = instruction_length; 1812 *out_instr_len = instruction_length;
1813 } 1813 }
1814 1814
1815 *object = NULL; 1815 *object = NULL;
1816 if (!code.IsNull() && code.is_alive()) { 1816 if (!code.IsNull() && code.is_alive()) {
1817 intptr_t offsets_length = code.pointer_offsets_length(); 1817 intptr_t offsets_length = code.pointer_offsets_length();
1818 for (intptr_t i = 0; i < offsets_length; i++) { 1818 for (intptr_t i = 0; i < offsets_length; i++) {
1819 uword addr = code.GetPointerOffsetAt(i) + code.EntryPoint(); 1819 uword addr = code.GetPointerOffsetAt(i) + code.PayloadStart();
1820 if ((pc <= addr) && (addr < (pc + instruction_length))) { 1820 if ((pc <= addr) && (addr < (pc + instruction_length))) {
1821 *object = &Object::Handle(*reinterpret_cast<RawObject**>(addr)); 1821 *object = &Object::Handle(*reinterpret_cast<RawObject**>(addr));
1822 break; 1822 break;
1823 } 1823 }
1824 } 1824 }
1825 } 1825 }
1826 } 1826 }
1827 1827
1828 #endif // !PRODUCT 1828 #endif // !PRODUCT
1829 1829
1830 } // namespace dart 1830 } // namespace dart
1831 1831
1832 #endif // defined TARGET_ARCH_IA32 1832 #endif // defined TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « runtime/vm/disassembler.cc ('k') | runtime/vm/exceptions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698