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

Side by Side Diff: src/compiler/linkage.h

Issue 1460183002: [turbofan] Add general support for sp-based frame access (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix arm64 Created 5 years, 1 month 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
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_COMPILER_LINKAGE_H_ 5 #ifndef V8_COMPILER_LINKAGE_H_
6 #define V8_COMPILER_LINKAGE_H_ 6 #define V8_COMPILER_LINKAGE_H_
7 7
8 #include "src/base/flags.h" 8 #include "src/base/flags.h"
9 #include "src/compiler/frame.h" 9 #include "src/compiler/frame.h"
10 #include "src/compiler/machine-type.h" 10 #include "src/compiler/machine-type.h"
11 #include "src/compiler/operator.h" 11 #include "src/compiler/operator.h"
12 #include "src/frames.h" 12 #include "src/frames.h"
13 #include "src/runtime/runtime.h" 13 #include "src/runtime/runtime.h"
14 #include "src/zone.h" 14 #include "src/zone.h"
15 15
16 namespace v8 { 16 namespace v8 {
17 namespace internal { 17 namespace internal {
18 18
19 class CallInterfaceDescriptor; 19 class CallInterfaceDescriptor;
20 class CompilationInfo; 20 class CompilationInfo;
21 21
22 namespace compiler { 22 namespace compiler {
23 23
24 const RegList kNoCalleeSaved = 0; 24 const RegList kNoCalleeSaved = 0;
25 25
26 class FrameAccessState;
26 class Node; 27 class Node;
27 class OsrHelper; 28 class OsrHelper;
28 29
29 // Describes the location for a parameter or a return value to a call. 30 // Describes the location for a parameter or a return value to a call.
30 class LinkageLocation { 31 class LinkageLocation {
31 public: 32 public:
32 bool operator==(const LinkageLocation& other) const { 33 bool operator==(const LinkageLocation& other) const {
33 return bit_field_ == other.bit_field_; 34 return bit_field_ == other.bit_field_;
34 } 35 }
35 36
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
345 return incoming_->GetReturnType(index); 346 return incoming_->GetReturnType(index);
346 } 347 }
347 348
348 bool ParameterHasSecondaryLocation(int index) const; 349 bool ParameterHasSecondaryLocation(int index) const;
349 LinkageLocation GetParameterSecondaryLocation(int index) const; 350 LinkageLocation GetParameterSecondaryLocation(int index) const;
350 351
351 // Get the frame offset for a given spill slot. The location depends on the 352 // Get the frame offset for a given spill slot. The location depends on the
352 // calling convention and the specific frame layout, and may thus be 353 // calling convention and the specific frame layout, and may thus be
353 // architecture-specific. Negative spill slots indicate arguments on the 354 // architecture-specific. Negative spill slots indicate arguments on the
354 // caller's frame. 355 // caller's frame.
355 FrameOffset GetFrameOffset(int spill_slot, Frame* frame) const; 356 FrameOffset GetFrameOffset(int spill_slot,
357 FrameAccessState* frame_access_state) const;
Benedikt Meurer 2015/11/20 09:53:10 Nit: pass as const* or const&.
danno 2015/11/24 12:02:00 Done.
356 358
357 static int FrameStateInputCount(Runtime::FunctionId function); 359 static int FrameStateInputCount(Runtime::FunctionId function);
358 360
359 // Get the location where an incoming OSR value is stored. 361 // Get the location where an incoming OSR value is stored.
360 LinkageLocation GetOsrValueLocation(int index) const; 362 LinkageLocation GetOsrValueLocation(int index) const;
361 363
362 // A special parameter index for JSCalls that represents the closure. 364 // A special parameter index for JSCalls that represents the closure.
363 static const int kJSFunctionCallClosureParamIndex = -1; 365 static const int kJSFunctionCallClosureParamIndex = -1;
364 366
365 // A special {OsrValue} index to indicate the context spill slot. 367 // A special {OsrValue} index to indicate the context spill slot.
(...skipping 12 matching lines...) Expand all
378 CallDescriptor* const incoming_; 380 CallDescriptor* const incoming_;
379 381
380 DISALLOW_COPY_AND_ASSIGN(Linkage); 382 DISALLOW_COPY_AND_ASSIGN(Linkage);
381 }; 383 };
382 384
383 } // namespace compiler 385 } // namespace compiler
384 } // namespace internal 386 } // namespace internal
385 } // namespace v8 387 } // namespace v8
386 388
387 #endif // V8_COMPILER_LINKAGE_H_ 389 #endif // V8_COMPILER_LINKAGE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698