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

Side by Side Diff: src/ast.cc

Issue 226233002: Revert "Reland of https://codereview.chromium.org/172523002/" (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 8 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/arm64/lithium-codegen-arm64.cc ('k') | src/builtins.h » ('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 576 matching lines...) Expand 10 before | Expand all | Expand 10 after
587 // TODO(rossberg): all RecordTypeFeedback functions should disappear 587 // TODO(rossberg): all RecordTypeFeedback functions should disappear
588 // once we use the common type field in the AST consistently. 588 // once we use the common type field in the AST consistently.
589 589
590 void Expression::RecordToBooleanTypeFeedback(TypeFeedbackOracle* oracle) { 590 void Expression::RecordToBooleanTypeFeedback(TypeFeedbackOracle* oracle) {
591 to_boolean_types_ = oracle->ToBooleanTypes(test_id()); 591 to_boolean_types_ = oracle->ToBooleanTypes(test_id());
592 } 592 }
593 593
594 594
595 int Call::ComputeFeedbackSlotCount(Isolate* isolate) { 595 int Call::ComputeFeedbackSlotCount(Isolate* isolate) {
596 CallType call_type = GetCallType(isolate); 596 CallType call_type = GetCallType(isolate);
597 if (call_type == POSSIBLY_EVAL_CALL) { 597 if (call_type == LOOKUP_SLOT_CALL || call_type == OTHER_CALL) {
598 return 0; 598 // Call only uses a slot in some cases.
599 return 1;
599 } 600 }
600 601
601 return 1; 602 return 0;
602 } 603 }
603 604
604 605
605 Call::CallType Call::GetCallType(Isolate* isolate) const { 606 Call::CallType Call::GetCallType(Isolate* isolate) const {
606 VariableProxy* proxy = expression()->AsVariableProxy(); 607 VariableProxy* proxy = expression()->AsVariableProxy();
607 if (proxy != NULL) { 608 if (proxy != NULL) {
608 if (proxy->var()->is_possibly_eval(isolate)) { 609 if (proxy->var()->is_possibly_eval(isolate)) {
609 return POSSIBLY_EVAL_CALL; 610 return POSSIBLY_EVAL_CALL;
610 } else if (proxy->var()->IsUnallocated()) { 611 } else if (proxy->var()->IsUnallocated()) {
611 return GLOBAL_CALL; 612 return GLOBAL_CALL;
(...skipping 562 matching lines...) Expand 10 before | Expand all | Expand 10 after
1174 OS::SNPrintF(buffer, "%d", Smi::cast(*value_)->value()); 1175 OS::SNPrintF(buffer, "%d", Smi::cast(*value_)->value());
1175 str = arr; 1176 str = arr;
1176 } else { 1177 } else {
1177 str = DoubleToCString(value_->Number(), buffer); 1178 str = DoubleToCString(value_->Number(), buffer);
1178 } 1179 }
1179 return isolate_->factory()->NewStringFromAscii(CStrVector(str)); 1180 return isolate_->factory()->NewStringFromAscii(CStrVector(str));
1180 } 1181 }
1181 1182
1182 1183
1183 } } // namespace v8::internal 1184 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm64/lithium-codegen-arm64.cc ('k') | src/builtins.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698