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 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #include "src/disasm.h" | 7 #include "src/disasm.h" |
8 #include "src/disassembler.h" | 8 #include "src/disassembler.h" |
9 #include "src/heap/objects-visiting.h" | 9 #include "src/heap/objects-visiting.h" |
10 #include "src/jsregexp.h" | 10 #include "src/jsregexp.h" |
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
383 Object* e = get(i); | 383 Object* e = get(i); |
384 VerifyPointer(e); | 384 VerifyPointer(e); |
385 } | 385 } |
386 } | 386 } |
387 | 387 |
388 | 388 |
389 void FixedDoubleArray::FixedDoubleArrayVerify() { | 389 void FixedDoubleArray::FixedDoubleArrayVerify() { |
390 for (int i = 0; i < length(); i++) { | 390 for (int i = 0; i < length(); i++) { |
391 if (!is_the_hole(i)) { | 391 if (!is_the_hole(i)) { |
392 uint64_t value = get_representation(i); | 392 uint64_t value = get_representation(i); |
393 CHECK((value & V8_UINT64_C(0x7FF8000000000000)) != | 393 uint64_t unexpected = |
394 V8_UINT64_C(0x7FF0000000000000) || | 394 bit_cast<uint64_t>(std::numeric_limits<double>::quiet_NaN()) & |
| 395 V8_UINT64_C(0x7FF8000000000000); |
| 396 // Create implementation specific sNaN by inverting relevant bit. |
| 397 unexpected ^= V8_UINT64_C(0x0008000000000000); |
| 398 CHECK((value & V8_UINT64_C(0x7FF8000000000000)) != unexpected || |
395 (value & V8_UINT64_C(0x0007FFFFFFFFFFFF)) == V8_UINT64_C(0)); | 399 (value & V8_UINT64_C(0x0007FFFFFFFFFFFF)) == V8_UINT64_C(0)); |
396 } | 400 } |
397 } | 401 } |
398 } | 402 } |
399 | 403 |
400 | 404 |
401 void ConstantPoolArray::ConstantPoolArrayVerify() { | 405 void ConstantPoolArray::ConstantPoolArrayVerify() { |
402 CHECK(IsConstantPoolArray()); | 406 CHECK(IsConstantPoolArray()); |
403 ConstantPoolArray::Iterator code_iter(this, ConstantPoolArray::CODE_PTR); | 407 ConstantPoolArray::Iterator code_iter(this, ConstantPoolArray::CODE_PTR); |
404 while (!code_iter.is_finished()) { | 408 while (!code_iter.is_finished()) { |
(...skipping 869 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1274 ? it.rinfo()->target_cell() | 1278 ? it.rinfo()->target_cell() |
1275 : it.rinfo()->target_object(); | 1279 : it.rinfo()->target_object(); |
1276 CHECK(!CanLeak(target, heap, skip_weak_cell)); | 1280 CHECK(!CanLeak(target, heap, skip_weak_cell)); |
1277 } | 1281 } |
1278 } | 1282 } |
1279 | 1283 |
1280 | 1284 |
1281 #endif // DEBUG | 1285 #endif // DEBUG |
1282 | 1286 |
1283 } } // namespace v8::internal | 1287 } } // namespace v8::internal |
OLD | NEW |