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

Side by Side Diff: src/typing.cc

Issue 137403009: Adding a type vector to replace type cells. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed feedback. Created 6 years, 10 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/type-info.cc ('k') | src/x64/code-stubs-x64.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 305 matching lines...) Expand 10 before | Expand all | Expand 10 after
316 store_.Forget(); // Control may transfer here via 'continue'. 316 store_.Forget(); // Control may transfer here via 'continue'.
317 RECURSE(Visit(stmt->next())); 317 RECURSE(Visit(stmt->next()));
318 } 318 }
319 store_.Forget(); // Control may transfer here via termination or 'break'. 319 store_.Forget(); // Control may transfer here via termination or 'break'.
320 } 320 }
321 321
322 322
323 void AstTyper::VisitForInStatement(ForInStatement* stmt) { 323 void AstTyper::VisitForInStatement(ForInStatement* stmt) {
324 // Collect type feedback. 324 // Collect type feedback.
325 stmt->set_for_in_type(static_cast<ForInStatement::ForInType>( 325 stmt->set_for_in_type(static_cast<ForInStatement::ForInType>(
326 oracle()->ForInType(stmt->ForInFeedbackId()))); 326 oracle()->ForInType(stmt->ForInFeedbackSlot())));
327 327
328 RECURSE(Visit(stmt->enumerable())); 328 RECURSE(Visit(stmt->enumerable()));
329 store_.Forget(); // Control may transfer here via looping or 'continue'. 329 store_.Forget(); // Control may transfer here via looping or 'continue'.
330 ObserveTypesAtOsrEntry(stmt); 330 ObserveTypesAtOsrEntry(stmt);
331 RECURSE(Visit(stmt->body())); 331 RECURSE(Visit(stmt->body()));
332 store_.Forget(); // Control may transfer here via 'break'. 332 store_.Forget(); // Control may transfer here via 'break'.
333 } 333 }
334 334
335 335
336 void AstTyper::VisitForOfStatement(ForOfStatement* stmt) { 336 void AstTyper::VisitForOfStatement(ForOfStatement* stmt) {
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
523 RECURSE(Visit(expr->key())); 523 RECURSE(Visit(expr->key()));
524 524
525 // We don't know anything about the result type. 525 // We don't know anything about the result type.
526 } 526 }
527 527
528 528
529 void AstTyper::VisitCall(Call* expr) { 529 void AstTyper::VisitCall(Call* expr) {
530 // Collect type feedback. 530 // Collect type feedback.
531 RECURSE(Visit(expr->expression())); 531 RECURSE(Visit(expr->expression()));
532 if (!expr->expression()->IsProperty() && 532 if (!expr->expression()->IsProperty() &&
533 oracle()->CallIsMonomorphic(expr->CallFeedbackId())) { 533 expr->HasCallFeedbackSlot() &&
534 expr->set_target(oracle()->GetCallTarget(expr->CallFeedbackId())); 534 oracle()->CallIsMonomorphic(expr->CallFeedbackSlot())) {
535 expr->set_target(oracle()->GetCallTarget(expr->CallFeedbackSlot()));
535 } 536 }
536 537
537 ZoneList<Expression*>* args = expr->arguments(); 538 ZoneList<Expression*>* args = expr->arguments();
538 for (int i = 0; i < args->length(); ++i) { 539 for (int i = 0; i < args->length(); ++i) {
539 Expression* arg = args->at(i); 540 Expression* arg = args->at(i);
540 RECURSE(Visit(arg)); 541 RECURSE(Visit(arg));
541 } 542 }
542 543
543 VariableProxy* proxy = expr->expression()->AsVariableProxy(); 544 VariableProxy* proxy = expr->expression()->AsVariableProxy();
544 if (proxy != NULL && proxy->var()->is_possibly_eval(isolate())) { 545 if (proxy != NULL && proxy->var()->is_possibly_eval(isolate())) {
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after
790 void AstTyper::VisitModuleUrl(ModuleUrl* module) { 791 void AstTyper::VisitModuleUrl(ModuleUrl* module) {
791 } 792 }
792 793
793 794
794 void AstTyper::VisitModuleStatement(ModuleStatement* stmt) { 795 void AstTyper::VisitModuleStatement(ModuleStatement* stmt) {
795 RECURSE(Visit(stmt->body())); 796 RECURSE(Visit(stmt->body()));
796 } 797 }
797 798
798 799
799 } } // namespace v8::internal 800 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/type-info.cc ('k') | src/x64/code-stubs-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698