| 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 2174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2185 if (!maybe_obj->ToObject(&obj)) return false; | 2185 if (!maybe_obj->ToObject(&obj)) return false; |
| 2186 } | 2186 } |
| 2187 set_minus_zero_value(obj); | 2187 set_minus_zero_value(obj); |
| 2188 ASSERT(signbit(minus_zero_value()->Number()) != 0); | 2188 ASSERT(signbit(minus_zero_value()->Number()) != 0); |
| 2189 | 2189 |
| 2190 { MaybeObject* maybe_obj = AllocateHeapNumber(OS::nan_value(), TENURED); | 2190 { MaybeObject* maybe_obj = AllocateHeapNumber(OS::nan_value(), TENURED); |
| 2191 if (!maybe_obj->ToObject(&obj)) return false; | 2191 if (!maybe_obj->ToObject(&obj)) return false; |
| 2192 } | 2192 } |
| 2193 set_nan_value(obj); | 2193 set_nan_value(obj); |
| 2194 | 2194 |
| 2195 { MaybeObject* maybe_obj = AllocateHeapNumber(V8_INFINITY, TENURED); |
| 2196 if (!maybe_obj->ToObject(&obj)) return false; |
| 2197 } |
| 2198 set_infinity_value(obj); |
| 2199 |
| 2195 { MaybeObject* maybe_obj = Allocate(oddball_map(), OLD_POINTER_SPACE); | 2200 { MaybeObject* maybe_obj = Allocate(oddball_map(), OLD_POINTER_SPACE); |
| 2196 if (!maybe_obj->ToObject(&obj)) return false; | 2201 if (!maybe_obj->ToObject(&obj)) return false; |
| 2197 } | 2202 } |
| 2198 set_undefined_value(obj); | 2203 set_undefined_value(obj); |
| 2199 Oddball::cast(obj)->set_kind(Oddball::kUndefined); | 2204 Oddball::cast(obj)->set_kind(Oddball::kUndefined); |
| 2200 ASSERT(!InNewSpace(undefined_value())); | 2205 ASSERT(!InNewSpace(undefined_value())); |
| 2201 | 2206 |
| 2202 // Allocate initial symbol table. | 2207 // Allocate initial symbol table. |
| 2203 { MaybeObject* maybe_obj = SymbolTable::Allocate(kInitialSymbolTableSize); | 2208 { MaybeObject* maybe_obj = SymbolTable::Allocate(kInitialSymbolTableSize); |
| 2204 if (!maybe_obj->ToObject(&obj)) return false; | 2209 if (!maybe_obj->ToObject(&obj)) return false; |
| (...skipping 4183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6388 } | 6393 } |
| 6389 isolate_->heap()->store_buffer()->Filter(MemoryChunk::ABOUT_TO_BE_FREED); | 6394 isolate_->heap()->store_buffer()->Filter(MemoryChunk::ABOUT_TO_BE_FREED); |
| 6390 for (chunk = chunks_queued_for_free_; chunk != NULL; chunk = next) { | 6395 for (chunk = chunks_queued_for_free_; chunk != NULL; chunk = next) { |
| 6391 next = chunk->next_chunk(); | 6396 next = chunk->next_chunk(); |
| 6392 isolate_->memory_allocator()->Free(chunk); | 6397 isolate_->memory_allocator()->Free(chunk); |
| 6393 } | 6398 } |
| 6394 chunks_queued_for_free_ = NULL; | 6399 chunks_queued_for_free_ = NULL; |
| 6395 } | 6400 } |
| 6396 | 6401 |
| 6397 } } // namespace v8::internal | 6402 } } // namespace v8::internal |
| OLD | NEW |