| OLD | NEW | 
|     1 // Copyright 2012 the V8 project authors. All rights reserved. |     1 // Copyright 2012 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 #include "src/ast.h" |     5 #include "src/ast.h" | 
|     6  |     6  | 
|     7 #include <cmath>  // For isfinite. |     7 #include <cmath>  // For isfinite. | 
|     8 #include "src/builtins.h" |     8 #include "src/builtins.h" | 
|     9 #include "src/code-stubs.h" |     9 #include "src/code-stubs.h" | 
|    10 #include "src/contexts.h" |    10 #include "src/contexts.h" | 
| (...skipping 549 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|   560   if (IsUsingCallFeedbackSlot(isolate) || call_type == POSSIBLY_EVAL_CALL) { |   560   if (IsUsingCallFeedbackSlot(isolate) || call_type == POSSIBLY_EVAL_CALL) { | 
|   561     return false; |   561     return false; | 
|   562   } |   562   } | 
|   563   return true; |   563   return true; | 
|   564 } |   564 } | 
|   565  |   565  | 
|   566  |   566  | 
|   567 bool Call::IsUsingCallFeedbackSlot(Isolate* isolate) const { |   567 bool Call::IsUsingCallFeedbackSlot(Isolate* isolate) const { | 
|   568   // SuperConstructorCall uses a CallConstructStub, which wants |   568   // SuperConstructorCall uses a CallConstructStub, which wants | 
|   569   // a Slot, not an IC slot. |   569   // a Slot, not an IC slot. | 
|   570   return FLAG_experimental_classes && GetCallType(isolate) == SUPER_CALL; |   570   return GetCallType(isolate) == SUPER_CALL; | 
|   571 } |   571 } | 
|   572  |   572  | 
|   573  |   573  | 
|   574 FeedbackVectorRequirements Call::ComputeFeedbackRequirements(Isolate* isolate) { |   574 FeedbackVectorRequirements Call::ComputeFeedbackRequirements(Isolate* isolate) { | 
|   575   int ic_slots = IsUsingCallFeedbackICSlot(isolate) ? 1 : 0; |   575   int ic_slots = IsUsingCallFeedbackICSlot(isolate) ? 1 : 0; | 
|   576   int slots = IsUsingCallFeedbackSlot(isolate) ? 1 : 0; |   576   int slots = IsUsingCallFeedbackSlot(isolate) ? 1 : 0; | 
|   577   // A Call uses either a slot or an IC slot. |   577   // A Call uses either a slot or an IC slot. | 
|   578   DCHECK((ic_slots & slots) == 0); |   578   DCHECK((ic_slots & slots) == 0); | 
|   579   return FeedbackVectorRequirements(slots, ic_slots); |   579   return FeedbackVectorRequirements(slots, ic_slots); | 
|   580 } |   580 } | 
| (...skipping 438 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  1019 // static |  1019 // static | 
|  1020 bool Literal::Match(void* literal1, void* literal2) { |  1020 bool Literal::Match(void* literal1, void* literal2) { | 
|  1021   const AstValue* x = static_cast<Literal*>(literal1)->raw_value(); |  1021   const AstValue* x = static_cast<Literal*>(literal1)->raw_value(); | 
|  1022   const AstValue* y = static_cast<Literal*>(literal2)->raw_value(); |  1022   const AstValue* y = static_cast<Literal*>(literal2)->raw_value(); | 
|  1023   return (x->IsString() && y->IsString() && *x->AsString() == *y->AsString()) || |  1023   return (x->IsString() && y->IsString() && *x->AsString() == *y->AsString()) || | 
|  1024          (x->IsNumber() && y->IsNumber() && x->AsNumber() == y->AsNumber()); |  1024          (x->IsNumber() && y->IsNumber() && x->AsNumber() == y->AsNumber()); | 
|  1025 } |  1025 } | 
|  1026  |  1026  | 
|  1027  |  1027  | 
|  1028 } }  // namespace v8::internal |  1028 } }  // namespace v8::internal | 
| OLD | NEW |