Chromium Code Reviews| Index: src/runtime/runtime-function.cc |
| diff --git a/src/runtime/runtime-function.cc b/src/runtime/runtime-function.cc |
| index 31da4a4535b97186d9154cc0cca3f6743e4a5e24..7bd94bbb29af62d2bac8a7ac108338f269fda996 100644 |
| --- a/src/runtime/runtime-function.cc |
| +++ b/src/runtime/runtime-function.cc |
| @@ -170,6 +170,14 @@ RUNTIME_FUNCTION(Runtime_SetCode) { |
| Handle<SharedFunctionInfo> target_shared(target->shared()); |
| Handle<SharedFunctionInfo> source_shared(source->shared()); |
| + if (FLAG_mark_shared_functions_for_tier_up) { |
| + // During bootstrapping with stress-opt, it can happen that we've |
| + // marked some builtin code for optimization. Defeat this, as |
| + // that optimization attempt may fail on code without a script |
| + // (all the %SetCode usages are like this). |
| + source_shared->set_marked_for_tier_up(false); |
| + } |
|
Leszek Swirski
2017/02/09 13:22:33
Hm, I'm not sure I like your solution here -- for
|
| + |
| if (!Compiler::Compile(source, Compiler::KEEP_EXCEPTION)) { |
| return isolate->heap()->exception(); |
| } |