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

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

Issue 12613004: To fully support hydrogen code stubs which accept a variable number of arguments, (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 9 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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1373 matching lines...) Expand 10 before | Expand all | Expand 10 after
1384 virtual void CompileToNative(LCodeGen* generator); 1384 virtual void CompileToNative(LCodeGen* generator);
1385 virtual const char* Mnemonic() const; 1385 virtual const char* Mnemonic() const;
1386 1386
1387 Token::Value op() const { return op_; } 1387 Token::Value op() const { return op_; }
1388 1388
1389 private: 1389 private:
1390 Token::Value op_; 1390 Token::Value op_;
1391 }; 1391 };
1392 1392
1393 1393
1394 class LReturn: public LTemplateInstruction<0, 2, 0> { 1394 class LReturn: public LTemplateInstruction<0, 3, 0> {
1395 public: 1395 public:
1396 explicit LReturn(LOperand* value, LOperand* context) { 1396 explicit LReturn(LOperand* value, LOperand* context,
1397 LOperand* parameter_count) {
1397 inputs_[0] = value; 1398 inputs_[0] = value;
1398 inputs_[1] = context; 1399 inputs_[1] = context;
1400 inputs_[2] = parameter_count;
1401 }
1402
1403 bool has_constant_parameter_count() const {
1404 return hydrogen()->has_constant_parameter_count();
danno 2013/03/07 15:11:14 You can implement these in terms of calls on the p
mvstanton 2013/03/07 16:48:49 Done.
1405 }
1406 int constant_parameter_count() const {
1407 return hydrogen()->constant_parameter_count();
1408 }
1409 LOperand* parameter_count() {
1410 ASSERT(!has_constant_parameter_count());
1411 return inputs_[2];
1399 } 1412 }
1400 1413
1401 DECLARE_CONCRETE_INSTRUCTION(Return, "return") 1414 DECLARE_CONCRETE_INSTRUCTION(Return, "return")
1415 DECLARE_HYDROGEN_ACCESSOR(Return)
1402 }; 1416 };
1403 1417
1404 1418
1405 class LLoadNamedField: public LTemplateInstruction<1, 1, 0> { 1419 class LLoadNamedField: public LTemplateInstruction<1, 1, 0> {
1406 public: 1420 public:
1407 explicit LLoadNamedField(LOperand* object) { 1421 explicit LLoadNamedField(LOperand* object) {
1408 inputs_[0] = object; 1422 inputs_[0] = object;
1409 } 1423 }
1410 1424
1411 LOperand* object() { return inputs_[0]; } 1425 LOperand* object() { return inputs_[0]; }
(...skipping 1417 matching lines...) Expand 10 before | Expand all | Expand 10 after
2829 2843
2830 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); 2844 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder);
2831 }; 2845 };
2832 2846
2833 #undef DECLARE_HYDROGEN_ACCESSOR 2847 #undef DECLARE_HYDROGEN_ACCESSOR
2834 #undef DECLARE_CONCRETE_INSTRUCTION 2848 #undef DECLARE_CONCRETE_INSTRUCTION
2835 2849
2836 } } // namespace v8::internal 2850 } } // namespace v8::internal
2837 2851
2838 #endif // V8_IA32_LITHIUM_IA32_H_ 2852 #endif // V8_IA32_LITHIUM_IA32_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698