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

Side by Side Diff: src/x64/fast-codegen-x64.cc

Issue 341002: Fix missing recording of source position for property access in fast compiler... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 1 month 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/ia32/fast-codegen-ia32.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 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 493 matching lines...) Expand 10 before | Expand all | Expand 10 after
504 } 504 }
505 } 505 }
506 } 506 }
507 507
508 508
509 void FastCodeGenerator::VisitProperty(Property* expr) { 509 void FastCodeGenerator::VisitProperty(Property* expr) {
510 Comment cmnt(masm_, "[ Property"); 510 Comment cmnt(masm_, "[ Property");
511 Expression* key = expr->key(); 511 Expression* key = expr->key();
512 uint32_t dummy; 512 uint32_t dummy;
513 513
514 // Record the source position for the property load.
515 SetSourcePosition(expr->position());
516
514 // Evaluate receiver. 517 // Evaluate receiver.
515 Visit(expr->obj()); 518 Visit(expr->obj());
516 519
517 if (key->AsLiteral() != NULL && key->AsLiteral()->handle()->IsSymbol() && 520 if (key->AsLiteral() != NULL && key->AsLiteral()->handle()->IsSymbol() &&
518 !String::cast(*(key->AsLiteral()->handle()))->AsArrayIndex(&dummy)) { 521 !String::cast(*(key->AsLiteral()->handle()))->AsArrayIndex(&dummy)) {
519 // Do a NAMED property load. 522 // Do a NAMED property load.
520 // The IC expects the property name in rcx and the receiver on the stack. 523 // The IC expects the property name in rcx and the receiver on the stack.
521 __ Move(rcx, key->AsLiteral()->handle()); 524 __ Move(rcx, key->AsLiteral()->handle());
522 Handle<Code> ic(Builtins::builtin(Builtins::LoadIC_Initialize)); 525 Handle<Code> ic(Builtins::builtin(Builtins::LoadIC_Initialize));
523 __ call(ic, RelocInfo::CODE_TARGET); 526 __ call(ic, RelocInfo::CODE_TARGET);
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
719 } else { 722 } else {
720 Visit(right); 723 Visit(right);
721 Move(destination, right->location()); 724 Move(destination, right->location());
722 } 725 }
723 726
724 __ bind(&done); 727 __ bind(&done);
725 } 728 }
726 729
727 730
728 } } // namespace v8::internal 731 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ia32/fast-codegen-ia32.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698