OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 2670 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2681 JSFunction* function) | 2681 JSFunction* function) |
2682 : frame_size_(frame_size), | 2682 : frame_size_(frame_size), |
2683 function_(function), | 2683 function_(function), |
2684 top_(kZapUint32), | 2684 top_(kZapUint32), |
2685 pc_(kZapUint32), | 2685 pc_(kZapUint32), |
2686 fp_(kZapUint32), | 2686 fp_(kZapUint32), |
2687 context_(kZapUint32), | 2687 context_(kZapUint32), |
2688 constant_pool_(kZapUint32) { | 2688 constant_pool_(kZapUint32) { |
2689 // Zap all the registers. | 2689 // Zap all the registers. |
2690 for (int r = 0; r < Register::kNumRegisters; r++) { | 2690 for (int r = 0; r < Register::kNumRegisters; r++) { |
| 2691 // TODO(jbramley): It isn't safe to use kZapUint32 here. If the register |
| 2692 // isn't used before the next safepoint, the GC will try to scan it as a |
| 2693 // tagged value. kZapUint32 looks like a valid tagged pointer, but it isn't. |
2691 SetRegister(r, kZapUint32); | 2694 SetRegister(r, kZapUint32); |
2692 } | 2695 } |
2693 | 2696 |
2694 // Zap all the slots. | 2697 // Zap all the slots. |
2695 for (unsigned o = 0; o < frame_size; o += kPointerSize) { | 2698 for (unsigned o = 0; o < frame_size; o += kPointerSize) { |
2696 SetFrameSlot(o, kZapUint32); | 2699 SetFrameSlot(o, kZapUint32); |
2697 } | 2700 } |
2698 } | 2701 } |
2699 | 2702 |
2700 | 2703 |
(...skipping 756 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3457 | 3460 |
3458 void DeoptimizedFrameInfo::Iterate(ObjectVisitor* v) { | 3461 void DeoptimizedFrameInfo::Iterate(ObjectVisitor* v) { |
3459 v->VisitPointer(BitCast<Object**>(&function_)); | 3462 v->VisitPointer(BitCast<Object**>(&function_)); |
3460 v->VisitPointers(parameters_, parameters_ + parameters_count_); | 3463 v->VisitPointers(parameters_, parameters_ + parameters_count_); |
3461 v->VisitPointers(expression_stack_, expression_stack_ + expression_count_); | 3464 v->VisitPointers(expression_stack_, expression_stack_ + expression_count_); |
3462 } | 3465 } |
3463 | 3466 |
3464 #endif // ENABLE_DEBUGGER_SUPPORT | 3467 #endif // ENABLE_DEBUGGER_SUPPORT |
3465 | 3468 |
3466 } } // namespace v8::internal | 3469 } } // namespace v8::internal |
OLD | NEW |