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

Side by Side Diff: src/hydrogen-instructions.h

Issue 104013008: Reland v8:18458 "Load the global proxy from the context of the target function." (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 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 | Annotate | Revision Log
« no previous file with comments | « src/hydrogen.cc ('k') | src/ia32/builtins-ia32.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 // 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 2396 matching lines...) Expand 10 before | Expand all | Expand 10 after
2407 HCallNamed(HValue* context, Handle<String> name, int argument_count) 2407 HCallNamed(HValue* context, Handle<String> name, int argument_count)
2408 : HUnaryCall(context, argument_count), name_(name) { 2408 : HUnaryCall(context, argument_count), name_(name) {
2409 } 2409 }
2410 2410
2411 Handle<String> name_; 2411 Handle<String> name_;
2412 }; 2412 };
2413 2413
2414 2414
2415 enum CallMode { 2415 enum CallMode {
2416 NORMAL_CALL, 2416 NORMAL_CALL,
2417 TAIL_CALL 2417 TAIL_CALL,
2418 NORMAL_CONTEXTUAL_CALL
2418 }; 2419 };
2419 2420
2420 2421
2421 class HCallFunction V8_FINAL : public HBinaryCall { 2422 class HCallFunction V8_FINAL : public HBinaryCall {
2422 public: 2423 public:
2423 DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P2(HCallFunction, HValue*, int); 2424 DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P2(HCallFunction, HValue*, int);
2424 DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P3( 2425 DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P3(
2425 HCallFunction, HValue*, int, CallMode); 2426 HCallFunction, HValue*, int, CallMode);
2426 2427
2427 bool IsTailCall() const { return call_mode_ == TAIL_CALL; } 2428 bool IsTailCall() const { return call_mode_ == TAIL_CALL; }
2428 2429 bool IsContextualCall() const { return call_mode_ == NORMAL_CONTEXTUAL_CALL; }
2429 HValue* context() { return first(); } 2430 HValue* context() { return first(); }
2430 HValue* function() { return second(); } 2431 HValue* function() { return second(); }
2431 2432
2432 DECLARE_CONCRETE_INSTRUCTION(CallFunction) 2433 DECLARE_CONCRETE_INSTRUCTION(CallFunction)
2433 2434
2434 virtual int argument_delta() const V8_OVERRIDE { 2435 virtual int argument_delta() const V8_OVERRIDE {
2435 if (IsTailCall()) return 0; 2436 if (IsTailCall()) return 0;
2436 return -argument_count(); 2437 return -argument_count();
2437 } 2438 }
2438 2439
(...skipping 5137 matching lines...) Expand 10 before | Expand all | Expand 10 after
7576 virtual bool IsDeletable() const V8_OVERRIDE { return true; } 7577 virtual bool IsDeletable() const V8_OVERRIDE { return true; }
7577 }; 7578 };
7578 7579
7579 7580
7580 #undef DECLARE_INSTRUCTION 7581 #undef DECLARE_INSTRUCTION
7581 #undef DECLARE_CONCRETE_INSTRUCTION 7582 #undef DECLARE_CONCRETE_INSTRUCTION
7582 7583
7583 } } // namespace v8::internal 7584 } } // namespace v8::internal
7584 7585
7585 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ 7586 #endif // V8_HYDROGEN_INSTRUCTIONS_H_
OLDNEW
« no previous file with comments | « src/hydrogen.cc ('k') | src/ia32/builtins-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698