OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 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 1394 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1405 | 1405 |
1406 obj = CreateOddball(oddball_map(), "hole", Smi::FromInt(-1)); | 1406 obj = CreateOddball(oddball_map(), "hole", Smi::FromInt(-1)); |
1407 if (obj->IsFailure()) return false; | 1407 if (obj->IsFailure()) return false; |
1408 set_the_hole_value(obj); | 1408 set_the_hole_value(obj); |
1409 | 1409 |
1410 obj = CreateOddball( | 1410 obj = CreateOddball( |
1411 oddball_map(), "no_interceptor_result_sentinel", Smi::FromInt(-2)); | 1411 oddball_map(), "no_interceptor_result_sentinel", Smi::FromInt(-2)); |
1412 if (obj->IsFailure()) return false; | 1412 if (obj->IsFailure()) return false; |
1413 set_no_interceptor_result_sentinel(obj); | 1413 set_no_interceptor_result_sentinel(obj); |
1414 | 1414 |
| 1415 obj = CreateOddball(oddball_map(), "termination_exception", Smi::FromInt(-3)); |
| 1416 if (obj->IsFailure()) return false; |
| 1417 set_termination_exception(obj); |
1415 | 1418 |
1416 // Allocate the empty string. | 1419 // Allocate the empty string. |
1417 obj = AllocateRawAsciiString(0, TENURED); | 1420 obj = AllocateRawAsciiString(0, TENURED); |
1418 if (obj->IsFailure()) return false; | 1421 if (obj->IsFailure()) return false; |
1419 set_empty_string(String::cast(obj)); | 1422 set_empty_string(String::cast(obj)); |
1420 | 1423 |
1421 for (unsigned i = 0; i < ARRAY_SIZE(constant_symbol_table); i++) { | 1424 for (unsigned i = 0; i < ARRAY_SIZE(constant_symbol_table); i++) { |
1422 obj = LookupAsciiSymbol(constant_symbol_table[i].contents); | 1425 obj = LookupAsciiSymbol(constant_symbol_table[i].contents); |
1423 if (obj->IsFailure()) return false; | 1426 if (obj->IsFailure()) return false; |
1424 roots_[constant_symbol_table[i].index] = String::cast(obj); | 1427 roots_[constant_symbol_table[i].index] = String::cast(obj); |
(...skipping 2487 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3912 #ifdef DEBUG | 3915 #ifdef DEBUG |
3913 bool Heap::GarbageCollectionGreedyCheck() { | 3916 bool Heap::GarbageCollectionGreedyCheck() { |
3914 ASSERT(FLAG_gc_greedy); | 3917 ASSERT(FLAG_gc_greedy); |
3915 if (Bootstrapper::IsActive()) return true; | 3918 if (Bootstrapper::IsActive()) return true; |
3916 if (disallow_allocation_failure()) return true; | 3919 if (disallow_allocation_failure()) return true; |
3917 return CollectGarbage(0, NEW_SPACE); | 3920 return CollectGarbage(0, NEW_SPACE); |
3918 } | 3921 } |
3919 #endif | 3922 #endif |
3920 | 3923 |
3921 } } // namespace v8::internal | 3924 } } // namespace v8::internal |
OLD | NEW |