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

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

Issue 513213002: Generate some intrinsics using our IR. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 3 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) 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 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64.
6 #if defined(TARGET_ARCH_X64) 6 #if defined(TARGET_ARCH_X64)
7 7
8 #include "vm/flow_graph_compiler.h" 8 #include "vm/flow_graph_compiler.h"
9 9
10 #include "vm/ast_printer.h" 10 #include "vm/ast_printer.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 return FLAG_enable_simd_inline; 50 return FLAG_enable_simd_inline;
51 } 51 }
52 52
53 53
54 54
55 bool FlowGraphCompiler::SupportsSinCos() { 55 bool FlowGraphCompiler::SupportsSinCos() {
56 return true; 56 return true;
57 } 57 }
58 58
59 59
60 void FlowGraphCompiler::EnterIntrinsicMode() {
61 ASSERT(!intrinsic_mode());
62 intrinsic_mode_ = true;
63 assembler()->set_allow_constant_pool(false);
64 }
65
66
67 void FlowGraphCompiler::ExitIntrinsicMode() {
68 ASSERT(intrinsic_mode());
69 intrinsic_mode_ = false;
70 assembler()->set_allow_constant_pool(true);
71 }
72
73
60 RawDeoptInfo* CompilerDeoptInfo::CreateDeoptInfo(FlowGraphCompiler* compiler, 74 RawDeoptInfo* CompilerDeoptInfo::CreateDeoptInfo(FlowGraphCompiler* compiler,
61 DeoptInfoBuilder* builder, 75 DeoptInfoBuilder* builder,
62 const Array& deopt_table) { 76 const Array& deopt_table) {
63 if (deopt_env_ == NULL) { 77 if (deopt_env_ == NULL) {
64 return DeoptInfo::null(); 78 return DeoptInfo::null();
65 } 79 }
66 80
67 intptr_t stack_height = compiler->StackSize(); 81 intptr_t stack_height = compiler->StackSize();
68 AllocateIncomingParametersRecursive(deopt_env_, &stack_height); 82 AllocateIncomingParametersRecursive(deopt_env_, &stack_height);
69 83
(...skipping 1618 matching lines...) Expand 10 before | Expand all | Expand 10 after
1688 void ParallelMoveResolver::Exchange(Register reg, const Address& mem) { 1702 void ParallelMoveResolver::Exchange(Register reg, const Address& mem) {
1689 __ Exchange(reg, mem); 1703 __ Exchange(reg, mem);
1690 } 1704 }
1691 1705
1692 1706
1693 void ParallelMoveResolver::Exchange(const Address& mem1, const Address& mem2) { 1707 void ParallelMoveResolver::Exchange(const Address& mem1, const Address& mem2) {
1694 __ Exchange(mem1, mem2); 1708 __ Exchange(mem1, mem2);
1695 } 1709 }
1696 1710
1697 1711
1698 void ParallelMoveResolver::Exchange(Register reg, intptr_t stack_offset) { 1712 void ParallelMoveResolver::Exchange(Register reg,
1713 Register base_reg,
1714 intptr_t stack_offset) {
1699 UNREACHABLE(); 1715 UNREACHABLE();
1700 } 1716 }
1701 1717
1702 1718
1703 void ParallelMoveResolver::Exchange(intptr_t stack_offset1, 1719 void ParallelMoveResolver::Exchange(Register base_reg1,
1720 intptr_t stack_offset1,
1721 Register base_reg2,
1704 intptr_t stack_offset2) { 1722 intptr_t stack_offset2) {
1705 UNREACHABLE(); 1723 UNREACHABLE();
1706 } 1724 }
1707 1725
1708 1726
1709 void ParallelMoveResolver::SpillScratch(Register reg) { 1727 void ParallelMoveResolver::SpillScratch(Register reg) {
1710 __ pushq(reg); 1728 __ pushq(reg);
1711 } 1729 }
1712 1730
1713 1731
(...skipping 12 matching lines...) Expand all
1726 __ movups(reg, Address(RSP, 0)); 1744 __ movups(reg, Address(RSP, 0));
1727 __ AddImmediate(RSP, Immediate(kFpuRegisterSize), PP); 1745 __ AddImmediate(RSP, Immediate(kFpuRegisterSize), PP);
1728 } 1746 }
1729 1747
1730 1748
1731 #undef __ 1749 #undef __
1732 1750
1733 } // namespace dart 1751 } // namespace dart
1734 1752
1735 #endif // defined TARGET_ARCH_X64 1753 #endif // defined TARGET_ARCH_X64
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698