| 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 "v8.h" | 5 #include "v8.h" |
| 6 | 6 |
| 7 #include "accessors.h" | 7 #include "accessors.h" |
| 8 #include "codegen.h" | 8 #include "codegen.h" |
| 9 #include "deoptimizer.h" | 9 #include "deoptimizer.h" |
| 10 #include "disasm.h" | 10 #include "disasm.h" |
| (...skipping 2888 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2899 // The bits encode the sign in the least significant bit. | 2899 // The bits encode the sign in the least significant bit. |
| 2900 bool is_negative = (bits & 1) == 1; | 2900 bool is_negative = (bits & 1) == 1; |
| 2901 int32_t result = bits >> 1; | 2901 int32_t result = bits >> 1; |
| 2902 return is_negative ? -result : result; | 2902 return is_negative ? -result : result; |
| 2903 } | 2903 } |
| 2904 | 2904 |
| 2905 | 2905 |
| 2906 Handle<ByteArray> TranslationBuffer::CreateByteArray(Factory* factory) { | 2906 Handle<ByteArray> TranslationBuffer::CreateByteArray(Factory* factory) { |
| 2907 int length = contents_.length(); | 2907 int length = contents_.length(); |
| 2908 Handle<ByteArray> result = factory->NewByteArray(length, TENURED); | 2908 Handle<ByteArray> result = factory->NewByteArray(length, TENURED); |
| 2909 MemCopy(result->GetDataStartAddress(), contents_.ToVector().start(), length); | 2909 OS::MemCopy( |
| 2910 result->GetDataStartAddress(), contents_.ToVector().start(), length); |
| 2910 return result; | 2911 return result; |
| 2911 } | 2912 } |
| 2912 | 2913 |
| 2913 | 2914 |
| 2914 void Translation::BeginConstructStubFrame(int literal_id, unsigned height) { | 2915 void Translation::BeginConstructStubFrame(int literal_id, unsigned height) { |
| 2915 buffer_->Add(CONSTRUCT_STUB_FRAME, zone()); | 2916 buffer_->Add(CONSTRUCT_STUB_FRAME, zone()); |
| 2916 buffer_->Add(literal_id, zone()); | 2917 buffer_->Add(literal_id, zone()); |
| 2917 buffer_->Add(height, zone()); | 2918 buffer_->Add(height, zone()); |
| 2918 } | 2919 } |
| 2919 | 2920 |
| (...skipping 660 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3580 } | 3581 } |
| 3581 | 3582 |
| 3582 | 3583 |
| 3583 void DeoptimizedFrameInfo::Iterate(ObjectVisitor* v) { | 3584 void DeoptimizedFrameInfo::Iterate(ObjectVisitor* v) { |
| 3584 v->VisitPointer(BitCast<Object**>(&function_)); | 3585 v->VisitPointer(BitCast<Object**>(&function_)); |
| 3585 v->VisitPointers(parameters_, parameters_ + parameters_count_); | 3586 v->VisitPointers(parameters_, parameters_ + parameters_count_); |
| 3586 v->VisitPointers(expression_stack_, expression_stack_ + expression_count_); | 3587 v->VisitPointers(expression_stack_, expression_stack_ + expression_count_); |
| 3587 } | 3588 } |
| 3588 | 3589 |
| 3589 } } // namespace v8::internal | 3590 } } // namespace v8::internal |
| OLD | NEW |