Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 #ifndef V8_CODEGEN_H_ | 5 #ifndef V8_CODEGEN_H_ |
| 6 #define V8_CODEGEN_H_ | 6 #define V8_CODEGEN_H_ |
| 7 | 7 |
| 8 #include "src/code-stubs.h" | 8 #include "src/code-stubs.h" |
| 9 #include "src/runtime/runtime.h" | 9 #include "src/runtime/runtime.h" |
| 10 | 10 |
| (...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 156 uint32_t young_sequence_length() const { return young_sequence_.length(); } | 156 uint32_t young_sequence_length() const { return young_sequence_.length(); } |
| 157 bool IsYoung(byte* candidate) const { | 157 bool IsYoung(byte* candidate) const { |
| 158 return memcmp(candidate, | 158 return memcmp(candidate, |
| 159 young_sequence_.start(), | 159 young_sequence_.start(), |
| 160 young_sequence_.length()) == 0; | 160 young_sequence_.length()) == 0; |
| 161 } | 161 } |
| 162 void CopyYoungSequenceTo(byte* new_buffer) const { | 162 void CopyYoungSequenceTo(byte* new_buffer) const { |
| 163 CopyBytes(new_buffer, young_sequence_.start(), young_sequence_.length()); | 163 CopyBytes(new_buffer, young_sequence_.start(), young_sequence_.length()); |
| 164 } | 164 } |
| 165 | 165 |
| 166 #ifdef DEBUG | 166 #if DCHECK_IS_ON |
| 167 bool IsOld(byte* candidate) const; | 167 bool IsOld(byte* candidate) const; |
| 168 #endif | 168 #endif |
| 169 | 169 |
| 170 protected: | 170 protected: |
| 171 const EmbeddedVector<byte, kNoCodeAgeSequenceLength> young_sequence_; | 171 const EmbeddedVector<byte, kNoCodeAgeSequenceLength> young_sequence_; |
| 172 #ifdef DEBUG | 172 #ifdef DEBUG |
|
Jakob Kummerow
2014/12/03 10:53:53
This is gonna cause arm64 compile errors (cf. code
| |
| 173 #ifdef V8_TARGET_ARCH_ARM64 | 173 #ifdef V8_TARGET_ARCH_ARM64 |
| 174 const EmbeddedVector<byte, kNoCodeAgeSequenceLength> old_sequence_; | 174 const EmbeddedVector<byte, kNoCodeAgeSequenceLength> old_sequence_; |
| 175 #endif | 175 #endif |
| 176 #endif | 176 #endif |
| 177 }; | 177 }; |
| 178 | 178 |
| 179 } } // namespace v8::internal | 179 } } // namespace v8::internal |
| 180 | 180 |
| 181 #endif // V8_CODEGEN_H_ | 181 #endif // V8_CODEGEN_H_ |
| OLD | NEW |