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

Side by Side Diff: src/hydrogen.cc

Issue 10413030: Fix prepareElementsForSort crash bug=117879 . This is a back (Closed) Base URL: http://v8.googlecode.com/svn/branches/3.8/
Patch Set: Created 8 years, 7 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/array.js ('k') | src/ia32/full-codegen-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 6764 matching lines...) Expand 10 before | Expand all | Expand 10 after
6775 ASSERT_EQ(1, call->arguments()->length()); 6775 ASSERT_EQ(1, call->arguments()->length());
6776 CHECK_ALIVE(VisitArgumentList(call->arguments())); 6776 CHECK_ALIVE(VisitArgumentList(call->arguments()));
6777 HValue* context = environment()->LookupContext(); 6777 HValue* context = environment()->LookupContext();
6778 HCallStub* result = 6778 HCallStub* result =
6779 new(zone()) HCallStub(context, CodeStub::NumberToString, 1); 6779 new(zone()) HCallStub(context, CodeStub::NumberToString, 1);
6780 Drop(1); 6780 Drop(1);
6781 return ast_context()->ReturnInstruction(result, call->id()); 6781 return ast_context()->ReturnInstruction(result, call->id());
6782 } 6782 }
6783 6783
6784 6784
6785 // Fast swapping of elements. Takes three expressions, the object and two
6786 // indices. This should only be used if the indices are known to be
6787 // non-negative and within bounds of the elements array at the call site.
6788 void HGraphBuilder::GenerateSwapElements(CallRuntime* call) {
6789 return Bailout("inlined runtime function: SwapElements");
6790 }
6791
6792
6793 // Fast call for custom callbacks. 6785 // Fast call for custom callbacks.
6794 void HGraphBuilder::GenerateCallFunction(CallRuntime* call) { 6786 void HGraphBuilder::GenerateCallFunction(CallRuntime* call) {
6795 // 1 ~ The function to call is not itself an argument to the call. 6787 // 1 ~ The function to call is not itself an argument to the call.
6796 int arg_count = call->arguments()->length() - 1; 6788 int arg_count = call->arguments()->length() - 1;
6797 ASSERT(arg_count >= 1); // There's always at least a receiver. 6789 ASSERT(arg_count >= 1); // There's always at least a receiver.
6798 6790
6799 for (int i = 0; i < arg_count; ++i) { 6791 for (int i = 0; i < arg_count; ++i) {
6800 CHECK_ALIVE(VisitArgument(call->arguments()->at(i))); 6792 CHECK_ALIVE(VisitArgument(call->arguments()->at(i)));
6801 } 6793 }
6802 CHECK_ALIVE(VisitForValue(call->arguments()->last())); 6794 CHECK_ALIVE(VisitForValue(call->arguments()->last()));
(...skipping 678 matching lines...) Expand 10 before | Expand all | Expand 10 after
7481 } 7473 }
7482 } 7474 }
7483 7475
7484 #ifdef DEBUG 7476 #ifdef DEBUG
7485 if (graph_ != NULL) graph_->Verify(false); // No full verify. 7477 if (graph_ != NULL) graph_->Verify(false); // No full verify.
7486 if (allocator_ != NULL) allocator_->Verify(); 7478 if (allocator_ != NULL) allocator_->Verify();
7487 #endif 7479 #endif
7488 } 7480 }
7489 7481
7490 } } // namespace v8::internal 7482 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/array.js ('k') | src/ia32/full-codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698