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 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
126 // | 126 // |
127 // The live registers are: | 127 // The live registers are: |
128 // o a1: the JS function object being called (i.e. ourselves) | 128 // o a1: the JS function object being called (i.e. ourselves) |
129 // o cp: our context | 129 // o cp: our context |
130 // o fp: our caller's frame pointer | 130 // o fp: our caller's frame pointer |
131 // o sp: stack pointer | 131 // o sp: stack pointer |
132 // o ra: return address | 132 // o ra: return address |
133 // | 133 // |
134 // The function builds a JS frame. Please see JavaScriptFrameConstants in | 134 // The function builds a JS frame. Please see JavaScriptFrameConstants in |
135 // frames-mips.h for its layout. | 135 // frames-mips.h for its layout. |
136 void FullCodeGenerator::Generate(CompilationInfo* info) { | 136 void FullCodeGenerator::Generate() { |
137 ASSERT(info_ == NULL); | 137 CompilationInfo* info = info_; |
138 info_ = info; | |
139 scope_ = info->scope(); | |
140 handler_table_ = | 138 handler_table_ = |
141 isolate()->factory()->NewFixedArray(function()->handler_count(), TENURED); | 139 isolate()->factory()->NewFixedArray(function()->handler_count(), TENURED); |
142 SetFunctionPosition(function()); | 140 SetFunctionPosition(function()); |
143 Comment cmnt(masm_, "[ function compiled by full code generator"); | 141 Comment cmnt(masm_, "[ function compiled by full code generator"); |
144 | 142 |
145 #ifdef DEBUG | 143 #ifdef DEBUG |
146 if (strlen(FLAG_stop_at) > 0 && | 144 if (strlen(FLAG_stop_at) > 0 && |
147 info->function()->name()->IsEqualTo(CStrVector(FLAG_stop_at))) { | 145 info->function()->name()->IsEqualTo(CStrVector(FLAG_stop_at))) { |
148 __ stop("stop-at"); | 146 __ stop("stop-at"); |
149 } | 147 } |
(...skipping 4307 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4457 *context_length = 0; | 4455 *context_length = 0; |
4458 return previous_; | 4456 return previous_; |
4459 } | 4457 } |
4460 | 4458 |
4461 | 4459 |
4462 #undef __ | 4460 #undef __ |
4463 | 4461 |
4464 } } // namespace v8::internal | 4462 } } // namespace v8::internal |
4465 | 4463 |
4466 #endif // V8_TARGET_ARCH_MIPS | 4464 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |