OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 | 96 |
97 CodeGenState::~CodeGenState() { | 97 CodeGenState::~CodeGenState() { |
98 ASSERT(owner_->state() == this); | 98 ASSERT(owner_->state() == this); |
99 owner_->set_state(previous_); | 99 owner_->set_state(previous_); |
100 } | 100 } |
101 | 101 |
102 | 102 |
103 // ------------------------------------------------------------------------- | 103 // ------------------------------------------------------------------------- |
104 // CodeGenerator implementation | 104 // CodeGenerator implementation |
105 | 105 |
106 CodeGenerator::CodeGenerator(int buffer_size, | 106 CodeGenerator::CodeGenerator(MacroAssembler* masm, |
107 Handle<Script> script, | 107 Handle<Script> script, |
108 bool is_eval) | 108 bool is_eval) |
109 : is_eval_(is_eval), | 109 : is_eval_(is_eval), |
110 script_(script), | 110 script_(script), |
111 deferred_(8), | 111 deferred_(8), |
112 masm_(new MacroAssembler(NULL, buffer_size)), | 112 masm_(masm), |
113 scope_(NULL), | 113 scope_(NULL), |
114 frame_(NULL), | 114 frame_(NULL), |
115 allocator_(NULL), | 115 allocator_(NULL), |
116 state_(NULL), | 116 state_(NULL), |
117 loop_nesting_(0), | 117 loop_nesting_(0), |
118 function_return_is_shadowed_(false), | 118 function_return_is_shadowed_(false), |
119 in_spilled_code_(false) { | 119 in_spilled_code_(false) { |
120 } | 120 } |
121 | 121 |
122 | 122 |
(...skipping 9980 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10103 | 10103 |
10104 // Call the runtime; it returns -1 (less), 0 (equal), or 1 (greater) | 10104 // Call the runtime; it returns -1 (less), 0 (equal), or 1 (greater) |
10105 // tagged as a small integer. | 10105 // tagged as a small integer. |
10106 __ bind(&runtime); | 10106 __ bind(&runtime); |
10107 __ TailCallRuntime(ExternalReference(Runtime::kStringCompare), 2, 1); | 10107 __ TailCallRuntime(ExternalReference(Runtime::kStringCompare), 2, 1); |
10108 } | 10108 } |
10109 | 10109 |
10110 #undef __ | 10110 #undef __ |
10111 | 10111 |
10112 } } // namespace v8::internal | 10112 } } // namespace v8::internal |
OLD | NEW |