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

Side by Side Diff: src/arm/lithium-arm.h

Issue 330053002: ARM, ARM64: Optimize array copy (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 6 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 | « no previous file | src/arm/lithium-arm.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_ARM_LITHIUM_ARM_H_ 5 #ifndef V8_ARM_LITHIUM_ARM_H_
6 #define V8_ARM_LITHIUM_ARM_H_ 6 #define V8_ARM_LITHIUM_ARM_H_
7 7
8 #include "src/hydrogen.h" 8 #include "src/hydrogen.h"
9 #include "src/lithium-allocator.h" 9 #include "src/lithium-allocator.h"
10 #include "src/lithium.h" 10 #include "src/lithium.h"
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 V(CmpHoleAndBranch) \ 53 V(CmpHoleAndBranch) \
54 V(CmpMapAndBranch) \ 54 V(CmpMapAndBranch) \
55 V(CmpT) \ 55 V(CmpT) \
56 V(ConstantD) \ 56 V(ConstantD) \
57 V(ConstantE) \ 57 V(ConstantE) \
58 V(ConstantI) \ 58 V(ConstantI) \
59 V(ConstantS) \ 59 V(ConstantS) \
60 V(ConstantT) \ 60 V(ConstantT) \
61 V(ConstructDouble) \ 61 V(ConstructDouble) \
62 V(Context) \ 62 V(Context) \
63 V(CopyElements) \
63 V(DateField) \ 64 V(DateField) \
64 V(DebugBreak) \ 65 V(DebugBreak) \
65 V(DeclareGlobals) \ 66 V(DeclareGlobals) \
66 V(Deoptimize) \ 67 V(Deoptimize) \
67 V(DivByConstI) \ 68 V(DivByConstI) \
68 V(DivByPowerOf2I) \ 69 V(DivByPowerOf2I) \
69 V(DivI) \ 70 V(DivI) \
70 V(DoubleBits) \ 71 V(DoubleBits) \
71 V(DoubleToI) \ 72 V(DoubleToI) \
72 V(DoubleToSmi) \ 73 V(DoubleToSmi) \
73 V(Drop) \ 74 V(Drop) \
74 V(Dummy) \ 75 V(Dummy) \
75 V(DummyUse) \ 76 V(DummyUse) \
77 V(FillElements) \
76 V(FlooringDivByConstI) \ 78 V(FlooringDivByConstI) \
77 V(FlooringDivByPowerOf2I) \ 79 V(FlooringDivByPowerOf2I) \
78 V(FlooringDivI) \ 80 V(FlooringDivI) \
79 V(ForInCacheArray) \ 81 V(ForInCacheArray) \
80 V(ForInPrepareMap) \ 82 V(ForInPrepareMap) \
81 V(FunctionLiteral) \ 83 V(FunctionLiteral) \
82 V(GetCachedArrayIndex) \ 84 V(GetCachedArrayIndex) \
83 V(Goto) \ 85 V(Goto) \
84 V(HasCachedArrayIndexAndBranch) \ 86 V(HasCachedArrayIndexAndBranch) \
85 V(HasInstanceTypeAndBranch) \ 87 V(HasInstanceTypeAndBranch) \
(...skipping 2099 matching lines...) Expand 10 before | Expand all | Expand 10 after
2185 DECLARE_CONCRETE_INSTRUCTION(StoreNamedGeneric, "store-named-generic") 2187 DECLARE_CONCRETE_INSTRUCTION(StoreNamedGeneric, "store-named-generic")
2186 DECLARE_HYDROGEN_ACCESSOR(StoreNamedGeneric) 2188 DECLARE_HYDROGEN_ACCESSOR(StoreNamedGeneric)
2187 2189
2188 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE; 2190 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE;
2189 2191
2190 Handle<Object> name() const { return hydrogen()->name(); } 2192 Handle<Object> name() const { return hydrogen()->name(); }
2191 StrictMode strict_mode() { return hydrogen()->strict_mode(); } 2193 StrictMode strict_mode() { return hydrogen()->strict_mode(); }
2192 }; 2194 };
2193 2195
2194 2196
2197 class LFillElements V8_FINAL : public LTemplateInstruction<0, 4, 1> {
2198 public:
2199 LFillElements(LOperand* object, LOperand* from, LOperand* to,
2200 LOperand* value, LOperand* scratch) {
2201 inputs_[0] = object;
2202 inputs_[1] = from;
2203 inputs_[2] = to;
2204 inputs_[3] = value;
2205 temps_[0] = scratch;
2206 }
2207 LOperand* elements() { return inputs_[0]; }
2208 LOperand* from() { return inputs_[1]; }
2209 LOperand* to() { return inputs_[2]; }
2210 LOperand* value() { return inputs_[3]; }
2211 LOperand* scratch() { return temps_[0]; }
2212
2213 DECLARE_CONCRETE_INSTRUCTION(FillElements, "fill-elements")
2214 DECLARE_HYDROGEN_ACCESSOR(FillElements)
2215
2216 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE;
2217
2218 // Max size for unroll (choosen to generate the smallest code size).
2219 static const int32_t kMaxUnrolledSize = 4;
2220 };
2221
2222
2223 class LCopyElements V8_FINAL : public LTemplateInstruction<0, 3, 0> {
2224 public:
2225 LCopyElements(LOperand* src, LOperand* dst, LOperand* length) {
2226 inputs_[0] = src;
2227 inputs_[1] = dst;
2228 inputs_[2] = length;
2229 }
2230 LOperand* src() { return inputs_[0]; }
2231 LOperand* dst() { return inputs_[1]; }
2232 LOperand* length() { return inputs_[2]; }
2233 ElementsKind elements_kind() const { return hydrogen()->elements_kind(); }
2234
2235 DECLARE_CONCRETE_INSTRUCTION(CopyElements, "copy-elements")
2236 DECLARE_HYDROGEN_ACCESSOR(CopyElements)
2237
2238 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE;
2239 };
2240
2241
2195 class LStoreKeyed V8_FINAL : public LTemplateInstruction<0, 3, 0> { 2242 class LStoreKeyed V8_FINAL : public LTemplateInstruction<0, 3, 0> {
2196 public: 2243 public:
2197 LStoreKeyed(LOperand* object, LOperand* key, LOperand* value) { 2244 LStoreKeyed(LOperand* object, LOperand* key, LOperand* value) {
2198 inputs_[0] = object; 2245 inputs_[0] = object;
2199 inputs_[1] = key; 2246 inputs_[1] = key;
2200 inputs_[2] = value; 2247 inputs_[2] = value;
2201 } 2248 }
2202 2249
2203 bool is_external() const { return hydrogen()->is_external(); } 2250 bool is_external() const { return hydrogen()->is_external(); }
2204 bool is_fixed_typed_array() const { 2251 bool is_fixed_typed_array() const {
(...skipping 667 matching lines...) Expand 10 before | Expand all | Expand 10 after
2872 2919
2873 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); 2920 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder);
2874 }; 2921 };
2875 2922
2876 #undef DECLARE_HYDROGEN_ACCESSOR 2923 #undef DECLARE_HYDROGEN_ACCESSOR
2877 #undef DECLARE_CONCRETE_INSTRUCTION 2924 #undef DECLARE_CONCRETE_INSTRUCTION
2878 2925
2879 } } // namespace v8::internal 2926 } } // namespace v8::internal
2880 2927
2881 #endif // V8_ARM_LITHIUM_ARM_H_ 2928 #endif // V8_ARM_LITHIUM_ARM_H_
OLDNEW
« no previous file with comments | « no previous file | src/arm/lithium-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698