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

Side by Side Diff: src/runtime.cc

Issue 582703002: Widen the intake valve for TurboFan. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 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
OLDNEW
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 <stdlib.h> 5 #include <stdlib.h>
6 #include <limits> 6 #include <limits>
7 7
8 #include "src/v8.h" 8 #include "src/v8.h"
9 9
10 #include "src/accessors.h" 10 #include "src/accessors.h"
(...skipping 8450 matching lines...) Expand 10 before | Expand all | Expand 10 after
8461 PrintF("]\n"); 8461 PrintF("]\n");
8462 } 8462 }
8463 #endif 8463 #endif
8464 8464
8465 // Compile the target function. 8465 // Compile the target function.
8466 DCHECK(function->shared()->allows_lazy_compilation()); 8466 DCHECK(function->shared()->allows_lazy_compilation());
8467 8467
8468 Handle<Code> code; 8468 Handle<Code> code;
8469 ASSIGN_RETURN_FAILURE_ON_EXCEPTION(isolate, code, 8469 ASSIGN_RETURN_FAILURE_ON_EXCEPTION(isolate, code,
8470 Compiler::GetLazyCode(function)); 8470 Compiler::GetLazyCode(function));
8471 DCHECK(code->kind() == Code::FUNCTION ||
8472 code->kind() == Code::OPTIMIZED_FUNCTION);
8471 function->ReplaceCode(*code); 8473 function->ReplaceCode(*code);
8472
8473 // All done. Return the compiled code.
8474 DCHECK(function->is_compiled());
8475 DCHECK(function->code()->kind() == Code::FUNCTION ||
8476 (FLAG_always_opt &&
8477 function->code()->kind() == Code::OPTIMIZED_FUNCTION));
8478 return *code; 8474 return *code;
8479 } 8475 }
8480 8476
8481 8477
8482 RUNTIME_FUNCTION(Runtime_CompileOptimized) { 8478 RUNTIME_FUNCTION(Runtime_CompileOptimized) {
8483 HandleScope scope(isolate); 8479 HandleScope scope(isolate);
8484 DCHECK(args.length() == 2); 8480 DCHECK(args.length() == 2);
8485 CONVERT_ARG_HANDLE_CHECKED(JSFunction, function, 0); 8481 CONVERT_ARG_HANDLE_CHECKED(JSFunction, function, 0);
8486 CONVERT_BOOLEAN_ARG_CHECKED(concurrent, 1); 8482 CONVERT_BOOLEAN_ARG_CHECKED(concurrent, 1);
8487 8483
(...skipping 7272 matching lines...) Expand 10 before | Expand all | Expand 10 after
15760 } 15756 }
15761 return NULL; 15757 return NULL;
15762 } 15758 }
15763 15759
15764 15760
15765 const Runtime::Function* Runtime::FunctionForId(Runtime::FunctionId id) { 15761 const Runtime::Function* Runtime::FunctionForId(Runtime::FunctionId id) {
15766 return &(kIntrinsicFunctions[static_cast<int>(id)]); 15762 return &(kIntrinsicFunctions[static_cast<int>(id)]);
15767 } 15763 }
15768 15764
15769 } } // namespace v8::internal 15765 } } // namespace v8::internal
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698