| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/hydrogen.h" | 5 #include "src/hydrogen.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "src/v8.h" | 9 #include "src/v8.h" |
| 10 | 10 |
| (...skipping 3440 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3451 ConsStringIteratorOp op; | 3451 ConsStringIteratorOp op; |
| 3452 StringCharacterStream stream(String::cast(script->source()), | 3452 StringCharacterStream stream(String::cast(script->source()), |
| 3453 &op, | 3453 &op, |
| 3454 shared->start_position()); | 3454 shared->start_position()); |
| 3455 // fun->end_position() points to the last character in the stream. We | 3455 // fun->end_position() points to the last character in the stream. We |
| 3456 // need to compensate by adding one to calculate the length. | 3456 // need to compensate by adding one to calculate the length. |
| 3457 int source_len = | 3457 int source_len = |
| 3458 shared->end_position() - shared->start_position() + 1; | 3458 shared->end_position() - shared->start_position() + 1; |
| 3459 for (int i = 0; i < source_len; i++) { | 3459 for (int i = 0; i < source_len; i++) { |
| 3460 if (stream.HasMore()) { | 3460 if (stream.HasMore()) { |
| 3461 os.put(stream.GetNext()); | 3461 os << AsUC16(stream.GetNext()); |
| 3462 } | 3462 } |
| 3463 } | 3463 } |
| 3464 } | 3464 } |
| 3465 | 3465 |
| 3466 os << "\n--- END ---\n"; | 3466 os << "\n--- END ---\n"; |
| 3467 } | 3467 } |
| 3468 } | 3468 } |
| 3469 } | 3469 } |
| 3470 | 3470 |
| 3471 int inline_id = next_inline_id_++; | 3471 int inline_id = next_inline_id_++; |
| (...skipping 8913 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 12385 if (ShouldProduceTraceOutput()) { | 12385 if (ShouldProduceTraceOutput()) { |
| 12386 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); | 12386 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); |
| 12387 } | 12387 } |
| 12388 | 12388 |
| 12389 #ifdef DEBUG | 12389 #ifdef DEBUG |
| 12390 graph_->Verify(false); // No full verify. | 12390 graph_->Verify(false); // No full verify. |
| 12391 #endif | 12391 #endif |
| 12392 } | 12392 } |
| 12393 | 12393 |
| 12394 } } // namespace v8::internal | 12394 } } // namespace v8::internal |
| OLD | NEW |