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

Side by Side Diff: src/compiler/common-operator.h

Issue 530783002: Convert Linkage to use MachineSignature. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Another try at size_t. Staunch the bleeding. 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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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_COMMON_OPERATOR_H_ 5 #ifndef V8_COMPILER_COMMON_OPERATOR_H_
6 #define V8_COMPILER_COMMON_OPERATOR_H_ 6 #define V8_COMPILER_COMMON_OPERATOR_H_
7 7
8 #include "src/v8.h" 8 #include "src/v8.h"
9 9
10 #include "src/assembler.h" 10 #include "src/assembler.h"
(...skipping 15 matching lines...) Expand all
26 int outputs, int controls, const char* mnemonic) 26 int outputs, int controls, const char* mnemonic)
27 : Operator1<int>(opcode, properties, inputs, outputs, mnemonic, 27 : Operator1<int>(opcode, properties, inputs, outputs, mnemonic,
28 controls) {} 28 controls) {}
29 29
30 virtual OStream& PrintParameter(OStream& os) const { return os; } // NOLINT 30 virtual OStream& PrintParameter(OStream& os) const { return os; } // NOLINT
31 int ControlInputCount() const { return parameter(); } 31 int ControlInputCount() const { return parameter(); }
32 }; 32 };
33 33
34 class CallOperator : public Operator1<CallDescriptor*> { 34 class CallOperator : public Operator1<CallDescriptor*> {
35 public: 35 public:
36 // TODO(titzer): Operator still uses int, whereas CallDescriptor uses size_t.
36 CallOperator(CallDescriptor* descriptor, const char* mnemonic) 37 CallOperator(CallDescriptor* descriptor, const char* mnemonic)
37 : Operator1<CallDescriptor*>( 38 : Operator1<CallDescriptor*>(
38 IrOpcode::kCall, descriptor->properties(), 39 IrOpcode::kCall, descriptor->properties(),
39 descriptor->InputCount() + descriptor->FrameStateCount(), 40 static_cast<int>(descriptor->InputCount() +
40 descriptor->ReturnCount(), mnemonic, descriptor) {} 41 descriptor->FrameStateCount()),
42 static_cast<int>(descriptor->ReturnCount()), mnemonic, descriptor) {
43 }
41 44
42 virtual OStream& PrintParameter(OStream& os) const { // NOLINT 45 virtual OStream& PrintParameter(OStream& os) const { // NOLINT
43 return os << "[" << *parameter() << "]"; 46 return os << "[" << *parameter() << "]";
44 } 47 }
45 }; 48 };
46 49
47 // Flag that describes how to combine the current environment with 50 // Flag that describes how to combine the current environment with
48 // the output of a node to obtain a framestate for lazy bailout. 51 // the output of a node to obtain a framestate for lazy bailout.
49 enum OutputFrameStateCombine { 52 enum OutputFrameStateCombine {
50 kPushOutput, // Push the output on the expression stack. 53 kPushOutput, // Push the output on the expression stack.
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after
306 309
307 template <typename T> 310 template <typename T>
308 inline T ValueOf(Operator* op) { 311 inline T ValueOf(Operator* op) {
309 return CommonOperatorTraits<T>::ValueOf(op); 312 return CommonOperatorTraits<T>::ValueOf(op);
310 } 313 }
311 } 314 }
312 } 315 }
313 } // namespace v8::internal::compiler 316 } // namespace v8::internal::compiler
314 317
315 #endif // V8_COMPILER_COMMON_OPERATOR_H_ 318 #endif // V8_COMPILER_COMMON_OPERATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698