Check code kind when resetting profiler ticks.
BUG=121147 TEST=chromium gpu_tests/WebGLConformanceTests Review URL: https://chromiumcodereview.appspot.com/9956060 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11208 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
6c8a6c2640
commit
e352114fb8
@ -7869,15 +7869,18 @@ void SharedFunctionInfo::AttachInitialMap(Map* map) {
|
||||
|
||||
void SharedFunctionInfo::ResetForNewContext(int new_ic_age) {
|
||||
code()->ClearInlineCaches();
|
||||
code()->set_profiler_ticks(0);
|
||||
set_ic_age(new_ic_age);
|
||||
if (optimization_disabled() && opt_count() >= Compiler::kDefaultMaxOptCount) {
|
||||
if (code()->kind() == Code::FUNCTION) {
|
||||
code()->set_profiler_ticks(0);
|
||||
if (optimization_disabled() &&
|
||||
opt_count() >= Compiler::kDefaultMaxOptCount) {
|
||||
// Re-enable optimizations if they were disabled due to opt_count limit.
|
||||
set_optimization_disabled(false);
|
||||
code()->set_optimizable(true);
|
||||
}
|
||||
set_opt_count(0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void GetMinInobjectSlack(Map* map, void* data) {
|
||||
|
Loading…
Reference in New Issue
Block a user