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

Side by Side Diff: src/runtime/runtime-utils.h

Issue 1576093004: [Interpreter] Add ForInPrepare runtime function which returns a ObjectTriple. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Add MIPS port Created 4 years, 11 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 | « src/runtime/runtime-interpreter.cc ('k') | src/x64/code-stubs-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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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_RUNTIME_RUNTIME_UTILS_H_ 5 #ifndef V8_RUNTIME_RUNTIME_UTILS_H_
6 #define V8_RUNTIME_RUNTIME_UTILS_H_ 6 #define V8_RUNTIME_RUNTIME_UTILS_H_
7 7
8 #include "src/runtime/runtime.h" 8 #include "src/runtime/runtime.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
155 (reinterpret_cast<ObjectPair>(y) << 32); 155 (reinterpret_cast<ObjectPair>(y) << 32);
156 #elif defined(V8_TARGET_BIG_ENDIAN) 156 #elif defined(V8_TARGET_BIG_ENDIAN)
157 return reinterpret_cast<uint32_t>(y) | 157 return reinterpret_cast<uint32_t>(y) |
158 (reinterpret_cast<ObjectPair>(x) << 32); 158 (reinterpret_cast<ObjectPair>(x) << 32);
159 #else 159 #else
160 #error Unknown endianness 160 #error Unknown endianness
161 #endif 161 #endif
162 } 162 }
163 #endif 163 #endif
164 164
165
166 // A mechanism to return a triple of Object pointers. In all calling
167 // conventions, a struct of two pointers is returned in memory,
168 // allocated by the caller, and passed as a pointer in a hidden first parameter.
169 struct ObjectTriple {
170 Object* x;
171 Object* y;
172 Object* z;
173 };
174
175 static inline ObjectTriple MakeTriple(Object* x, Object* y, Object* z) {
176 ObjectTriple result = {x, y, z};
177 // ObjectTriple is assigned to a hidden first argument.
178 return result;
179 }
180
165 } // namespace internal 181 } // namespace internal
166 } // namespace v8 182 } // namespace v8
167 183
168 #endif // V8_RUNTIME_RUNTIME_UTILS_H_ 184 #endif // V8_RUNTIME_RUNTIME_UTILS_H_
OLDNEW
« no previous file with comments | « src/runtime/runtime-interpreter.cc ('k') | src/x64/code-stubs-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698