| OLD | NEW |
| 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 7862 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7873 // non-optimizable if optimization is disabled for the shared | 7873 // non-optimizable if optimization is disabled for the shared |
| 7874 // function info. | 7874 // function info. |
| 7875 set_optimization_disabled(true); | 7875 set_optimization_disabled(true); |
| 7876 // Code should be the lazy compilation stub or else unoptimized. If the | 7876 // Code should be the lazy compilation stub or else unoptimized. If the |
| 7877 // latter, disable optimization for the code too. | 7877 // latter, disable optimization for the code too. |
| 7878 ASSERT(code()->kind() == Code::FUNCTION || code()->kind() == Code::BUILTIN); | 7878 ASSERT(code()->kind() == Code::FUNCTION || code()->kind() == Code::BUILTIN); |
| 7879 if (code()->kind() == Code::FUNCTION) { | 7879 if (code()->kind() == Code::FUNCTION) { |
| 7880 code()->set_optimizable(false); | 7880 code()->set_optimizable(false); |
| 7881 } | 7881 } |
| 7882 if (FLAG_trace_opt) { | 7882 if (FLAG_trace_opt) { |
| 7883 PrintF("[disabled optimization for: "); | 7883 PrintF("[disabled optimization for %s]\n", *DebugName()->ToCString()); |
| 7884 DebugName()->ShortPrint(); | |
| 7885 PrintF("]\n"); | |
| 7886 } | 7884 } |
| 7887 } | 7885 } |
| 7888 | 7886 |
| 7889 | 7887 |
| 7890 bool SharedFunctionInfo::VerifyBailoutId(int id) { | 7888 bool SharedFunctionInfo::VerifyBailoutId(int id) { |
| 7891 ASSERT(id != AstNode::kNoNumber); | 7889 ASSERT(id != AstNode::kNoNumber); |
| 7892 Code* unoptimized = code(); | 7890 Code* unoptimized = code(); |
| 7893 DeoptimizationOutputData* data = | 7891 DeoptimizationOutputData* data = |
| 7894 DeoptimizationOutputData::cast(unoptimized->deoptimization_data()); | 7892 DeoptimizationOutputData::cast(unoptimized->deoptimization_data()); |
| 7895 unsigned ignore = Deoptimizer::GetOutputInfo(data, id, this); | 7893 unsigned ignore = Deoptimizer::GetOutputInfo(data, id, this); |
| (...skipping 5273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 13169 if (break_point_objects()->IsUndefined()) return 0; | 13167 if (break_point_objects()->IsUndefined()) return 0; |
| 13170 // Single break point. | 13168 // Single break point. |
| 13171 if (!break_point_objects()->IsFixedArray()) return 1; | 13169 if (!break_point_objects()->IsFixedArray()) return 1; |
| 13172 // Multiple break points. | 13170 // Multiple break points. |
| 13173 return FixedArray::cast(break_point_objects())->length(); | 13171 return FixedArray::cast(break_point_objects())->length(); |
| 13174 } | 13172 } |
| 13175 #endif // ENABLE_DEBUGGER_SUPPORT | 13173 #endif // ENABLE_DEBUGGER_SUPPORT |
| 13176 | 13174 |
| 13177 | 13175 |
| 13178 } } // namespace v8::internal | 13176 } } // namespace v8::internal |
| OLD | NEW |