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_OBJECTS_H_ | 5 #ifndef V8_OBJECTS_H_ |
6 #define V8_OBJECTS_H_ | 6 #define V8_OBJECTS_H_ |
7 | 7 |
8 #include <iosfwd> | 8 #include <iosfwd> |
9 | 9 |
10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
(...skipping 2557 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2568 // Gives access to raw memory which stores the array's data. | 2568 // Gives access to raw memory which stores the array's data. |
2569 inline double* data_start(); | 2569 inline double* data_start(); |
2570 | 2570 |
2571 inline void FillWithHoles(int from, int to); | 2571 inline void FillWithHoles(int from, int to); |
2572 | 2572 |
2573 // Code Generation support. | 2573 // Code Generation support. |
2574 static int OffsetOfElementAt(int index) { return SizeFor(index); } | 2574 static int OffsetOfElementAt(int index) { return SizeFor(index); } |
2575 | 2575 |
2576 inline static bool is_the_hole_nan(double value); | 2576 inline static bool is_the_hole_nan(double value); |
2577 inline static double hole_nan_as_double(); | 2577 inline static double hole_nan_as_double(); |
2578 inline static double canonical_not_the_hole_nan_as_double(); | |
2579 | 2578 |
2580 DECLARE_CAST(FixedDoubleArray) | 2579 DECLARE_CAST(FixedDoubleArray) |
2581 | 2580 |
2582 // Maximal allowed size, in bytes, of a single FixedDoubleArray. | 2581 // Maximal allowed size, in bytes, of a single FixedDoubleArray. |
2583 // Prevents overflowing size computations, as well as extreme memory | 2582 // Prevents overflowing size computations, as well as extreme memory |
2584 // consumption. | 2583 // consumption. |
2585 static const int kMaxSize = 512 * MB; | 2584 static const int kMaxSize = 512 * MB; |
2586 // Maximally allowed length of a FixedArray. | 2585 // Maximally allowed length of a FixedArray. |
2587 static const int kMaxLength = (kMaxSize - kHeaderSize) / kDoubleSize; | 2586 static const int kMaxLength = (kMaxSize - kHeaderSize) / kDoubleSize; |
2588 | 2587 |
(...skipping 8325 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10914 } else { | 10913 } else { |
10915 value &= ~(1 << bit_position); | 10914 value &= ~(1 << bit_position); |
10916 } | 10915 } |
10917 return value; | 10916 return value; |
10918 } | 10917 } |
10919 }; | 10918 }; |
10920 | 10919 |
10921 } } // namespace v8::internal | 10920 } } // namespace v8::internal |
10922 | 10921 |
10923 #endif // V8_OBJECTS_H_ | 10922 #endif // V8_OBJECTS_H_ |
OLD | NEW |