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 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
309 scope->num_parameters() + 1 + scope->num_stack_slots() > locals_limit) { | 309 scope->num_parameters() + 1 + scope->num_stack_slots() > locals_limit) { |
310 info()->set_bailout_reason("too many parameters/locals"); | 310 info()->set_bailout_reason("too many parameters/locals"); |
311 return AbortOptimization(); | 311 return AbortOptimization(); |
312 } | 312 } |
313 | 313 |
314 // Take --hydrogen-filter into account. | 314 // Take --hydrogen-filter into account. |
315 Handle<String> name = info()->function()->debug_name(); | 315 Handle<String> name = info()->function()->debug_name(); |
316 if (*FLAG_hydrogen_filter != '\0') { | 316 if (*FLAG_hydrogen_filter != '\0') { |
317 Vector<const char> filter = CStrVector(FLAG_hydrogen_filter); | 317 Vector<const char> filter = CStrVector(FLAG_hydrogen_filter); |
318 if ((filter[0] == '-' | 318 if ((filter[0] == '-' |
319 && name->IsEqualTo(filter.SubVector(1, filter.length()))) | 319 && name->IsUtf8EqualTo(filter.SubVector(1, filter.length()))) |
320 || (filter[0] != '-' && !name->IsEqualTo(filter))) { | 320 || (filter[0] != '-' && !name->IsUtf8EqualTo(filter))) { |
321 info()->SetCode(code); | 321 info()->SetCode(code); |
322 return SetLastStatus(BAILED_OUT); | 322 return SetLastStatus(BAILED_OUT); |
323 } | 323 } |
324 } | 324 } |
325 | 325 |
326 // Recompile the unoptimized version of the code if the current version | 326 // Recompile the unoptimized version of the code if the current version |
327 // doesn't have deoptimization support. Alternatively, we may decide to | 327 // doesn't have deoptimization support. Alternatively, we may decide to |
328 // run the full code generator to get a baseline for the compile-time | 328 // run the full code generator to get a baseline for the compile-time |
329 // performance of the hydrogen-based compiler. | 329 // performance of the hydrogen-based compiler. |
330 bool should_recompile = !info()->shared_info()->has_deoptimization_support(); | 330 bool should_recompile = !info()->shared_info()->has_deoptimization_support(); |
(...skipping 779 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1110 } | 1110 } |
1111 } | 1111 } |
1112 | 1112 |
1113 GDBJIT(AddCode(Handle<String>(shared->DebugName()), | 1113 GDBJIT(AddCode(Handle<String>(shared->DebugName()), |
1114 Handle<Script>(info->script()), | 1114 Handle<Script>(info->script()), |
1115 Handle<Code>(info->code()), | 1115 Handle<Code>(info->code()), |
1116 info)); | 1116 info)); |
1117 } | 1117 } |
1118 | 1118 |
1119 } } // namespace v8::internal | 1119 } } // namespace v8::internal |
OLD | NEW |