OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
159 | 159 |
160 // Used internally by the JIT and memory allocator for security | 160 // Used internally by the JIT and memory allocator for security |
161 // purposes. So, we keep a different state to prevent informations | 161 // purposes. So, we keep a different state to prevent informations |
162 // leaks that could be used in an exploit. | 162 // leaks that could be used in an exploit. |
163 uint32_t V8::RandomPrivate(Isolate* isolate) { | 163 uint32_t V8::RandomPrivate(Isolate* isolate) { |
164 ASSERT(isolate == Isolate::Current()); | 164 ASSERT(isolate == Isolate::Current()); |
165 return random_base(isolate->private_random_seed()); | 165 return random_base(isolate->private_random_seed()); |
166 } | 166 } |
167 | 167 |
168 | 168 |
169 bool V8::IdleNotification() { | 169 bool V8::IdleNotification(int hint) { |
170 // Returning true tells the caller that there is no need to call | 170 // Returning true tells the caller that there is no need to call |
171 // IdleNotification again. | 171 // IdleNotification again. |
172 if (!FLAG_use_idle_notification) return true; | 172 if (!FLAG_use_idle_notification) return true; |
173 | 173 |
174 // Tell the heap that it may want to adjust. | 174 // Tell the heap that it may want to adjust. |
175 return HEAP->IdleNotification(); | 175 return HEAP->IdleNotification(hint); |
176 } | 176 } |
177 | 177 |
178 | 178 |
179 // Use a union type to avoid type-aliasing optimizations in GCC. | 179 // Use a union type to avoid type-aliasing optimizations in GCC. |
180 typedef union { | 180 typedef union { |
181 double double_value; | 181 double double_value; |
182 uint64_t uint64_t_value; | 182 uint64_t uint64_t_value; |
183 } double_int_union; | 183 } double_int_union; |
184 | 184 |
185 | 185 |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
229 ElementsAccessor::InitializeOncePerProcess(); | 229 ElementsAccessor::InitializeOncePerProcess(); |
230 | 230 |
231 if (FLAG_stress_compaction) { | 231 if (FLAG_stress_compaction) { |
232 FLAG_force_marking_deque_overflows = true; | 232 FLAG_force_marking_deque_overflows = true; |
233 FLAG_gc_global = true; | 233 FLAG_gc_global = true; |
234 FLAG_max_new_space_size = (1 << (kPageSizeBits - 10)) * 2; | 234 FLAG_max_new_space_size = (1 << (kPageSizeBits - 10)) * 2; |
235 } | 235 } |
236 } | 236 } |
237 | 237 |
238 } } // namespace v8::internal | 238 } } // namespace v8::internal |
OLD | NEW |