OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 4745 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4756 // We don't want to add more than a certain number of nodes from inlining. | 4756 // We don't want to add more than a certain number of nodes from inlining. |
4757 if (FLAG_limit_inlining && inlined_count_ > kMaxInlinedNodes) { | 4757 if (FLAG_limit_inlining && inlined_count_ > kMaxInlinedNodes) { |
4758 TraceInline(target, caller, "cumulative AST node limit reached"); | 4758 TraceInline(target, caller, "cumulative AST node limit reached"); |
4759 return false; | 4759 return false; |
4760 } | 4760 } |
4761 | 4761 |
4762 int count_before = AstNode::Count(); | 4762 int count_before = AstNode::Count(); |
4763 | 4763 |
4764 // Parse and allocate variables. | 4764 // Parse and allocate variables. |
4765 CompilationInfo target_info(target); | 4765 CompilationInfo target_info(target); |
4766 if (!ParserApi::Parse(&target_info) || | 4766 if (!ParserApi::Parse(&target_info, kNoParsingFlags) || |
4767 !Scope::Analyze(&target_info)) { | 4767 !Scope::Analyze(&target_info)) { |
4768 if (target_info.isolate()->has_pending_exception()) { | 4768 if (target_info.isolate()->has_pending_exception()) { |
4769 // Parse or scope error, never optimize this function. | 4769 // Parse or scope error, never optimize this function. |
4770 SetStackOverflow(); | 4770 SetStackOverflow(); |
4771 target_shared->DisableOptimization(*target); | 4771 target_shared->DisableOptimization(*target); |
4772 } | 4772 } |
4773 TraceInline(target, caller, "parse failure"); | 4773 TraceInline(target, caller, "parse failure"); |
4774 return false; | 4774 return false; |
4775 } | 4775 } |
4776 | 4776 |
(...skipping 2435 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7212 } | 7212 } |
7213 } | 7213 } |
7214 | 7214 |
7215 #ifdef DEBUG | 7215 #ifdef DEBUG |
7216 if (graph_ != NULL) graph_->Verify(false); // No full verify. | 7216 if (graph_ != NULL) graph_->Verify(false); // No full verify. |
7217 if (allocator_ != NULL) allocator_->Verify(); | 7217 if (allocator_ != NULL) allocator_->Verify(); |
7218 #endif | 7218 #endif |
7219 } | 7219 } |
7220 | 7220 |
7221 } } // namespace v8::internal | 7221 } } // namespace v8::internal |
OLD | NEW |