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

Side by Side Diff: src/hydrogen.cc

Issue 9580007: Revert r10908 due to flakiness and crashes. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 9 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/heap-inl.h ('k') | src/hydrogen-instructions.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 5402 matching lines...) Expand 10 before | Expand all | Expand 10 after
5413 bool HGraphBuilder::TryInlineBuiltinFunctionCall(Call* expr, bool drop_extra) { 5413 bool HGraphBuilder::TryInlineBuiltinFunctionCall(Call* expr, bool drop_extra) {
5414 if (!expr->target()->shared()->HasBuiltinFunctionId()) return false; 5414 if (!expr->target()->shared()->HasBuiltinFunctionId()) return false;
5415 BuiltinFunctionId id = expr->target()->shared()->builtin_function_id(); 5415 BuiltinFunctionId id = expr->target()->shared()->builtin_function_id();
5416 switch (id) { 5416 switch (id) {
5417 case kMathRound: 5417 case kMathRound:
5418 case kMathAbs: 5418 case kMathAbs:
5419 case kMathSqrt: 5419 case kMathSqrt:
5420 case kMathLog: 5420 case kMathLog:
5421 case kMathSin: 5421 case kMathSin:
5422 case kMathCos: 5422 case kMathCos:
5423 case kMathTan:
5424 if (expr->arguments()->length() == 1) { 5423 if (expr->arguments()->length() == 1) {
5425 HValue* argument = Pop(); 5424 HValue* argument = Pop();
5426 HValue* context = environment()->LookupContext(); 5425 HValue* context = environment()->LookupContext();
5427 Drop(1); // Receiver. 5426 Drop(1); // Receiver.
5428 HUnaryMathOperation* op = 5427 HUnaryMathOperation* op =
5429 new(zone()) HUnaryMathOperation(context, argument, id); 5428 new(zone()) HUnaryMathOperation(context, argument, id);
5430 op->set_position(expr->position()); 5429 op->set_position(expr->position());
5431 if (drop_extra) Drop(1); // Optionally drop the function. 5430 if (drop_extra) Drop(1); // Optionally drop the function.
5432 ast_context()->ReturnInstruction(op, expr->id()); 5431 ast_context()->ReturnInstruction(op, expr->id());
5433 return true; 5432 return true;
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
5474 return true; 5473 return true;
5475 } 5474 }
5476 break; 5475 break;
5477 case kMathRound: 5476 case kMathRound:
5478 case kMathFloor: 5477 case kMathFloor:
5479 case kMathAbs: 5478 case kMathAbs:
5480 case kMathSqrt: 5479 case kMathSqrt:
5481 case kMathLog: 5480 case kMathLog:
5482 case kMathSin: 5481 case kMathSin:
5483 case kMathCos: 5482 case kMathCos:
5484 case kMathTan:
5485 if (argument_count == 2 && check_type == RECEIVER_MAP_CHECK) { 5483 if (argument_count == 2 && check_type == RECEIVER_MAP_CHECK) {
5486 AddCheckConstantFunction(expr, receiver, receiver_map, true); 5484 AddCheckConstantFunction(expr, receiver, receiver_map, true);
5487 HValue* argument = Pop(); 5485 HValue* argument = Pop();
5488 HValue* context = environment()->LookupContext(); 5486 HValue* context = environment()->LookupContext();
5489 Drop(1); // Receiver. 5487 Drop(1); // Receiver.
5490 HUnaryMathOperation* op = 5488 HUnaryMathOperation* op =
5491 new(zone()) HUnaryMathOperation(context, argument, id); 5489 new(zone()) HUnaryMathOperation(context, argument, id);
5492 op->set_position(expr->position()); 5490 op->set_position(expr->position());
5493 ast_context()->ReturnInstruction(op, expr->id()); 5491 ast_context()->ReturnInstruction(op, expr->id());
5494 return true; 5492 return true;
(...skipping 2552 matching lines...) Expand 10 before | Expand all | Expand 10 after
8047 } 8045 }
8048 } 8046 }
8049 8047
8050 #ifdef DEBUG 8048 #ifdef DEBUG
8051 if (graph_ != NULL) graph_->Verify(false); // No full verify. 8049 if (graph_ != NULL) graph_->Verify(false); // No full verify.
8052 if (allocator_ != NULL) allocator_->Verify(); 8050 if (allocator_ != NULL) allocator_->Verify();
8053 #endif 8051 #endif
8054 } 8052 }
8055 8053
8056 } } // namespace v8::internal 8054 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/heap-inl.h ('k') | src/hydrogen-instructions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698