OLD | NEW |
---|---|
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 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 1514 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1525 | 1525 |
1526 // If V8 hasn't been and cannot be initialized, just return. | 1526 // If V8 hasn't been and cannot be initialized, just return. |
1527 if (!V8::HasBeenSetup() && !V8::Initialize(NULL)) return; | 1527 if (!V8::HasBeenSetup() && !V8::Initialize(NULL)) return; |
1528 | 1528 |
1529 // Before creating the roots we must save the context and restore it | 1529 // Before creating the roots we must save the context and restore it |
1530 // on all function exits. | 1530 // on all function exits. |
1531 HandleScope scope; | 1531 HandleScope scope; |
1532 SaveContext context; | 1532 SaveContext context; |
1533 | 1533 |
1534 CreateRoots(global_template, global_object); | 1534 CreateRoots(global_template, global_object); |
1535 | |
1536 #ifndef V8_HOST_ARCH_64_BIT | |
William Hesse
2009/05/22 12:21:13
This should be marked with a TODO to remove it whe
| |
1535 if (!InstallNatives()) return; | 1537 if (!InstallNatives()) return; |
Kevin Millikin (Chromium)
2009/05/22 12:47:49
There may be a general documentation advantage to
Lasse Reichstein
2009/05/22 13:10:10
I have moved the ifdef inside the function, and ev
| |
1538 #endif // V8_HOST_ARCH_64_BIT | |
1536 | 1539 |
1537 MakeFunctionInstancePrototypeWritable(); | 1540 MakeFunctionInstancePrototypeWritable(); |
1538 BuildSpecialFunctionTable(); | 1541 BuildSpecialFunctionTable(); |
1539 | 1542 |
1540 if (!ConfigureGlobalObjects(global_template)) return; | 1543 if (!ConfigureGlobalObjects(global_template)) return; |
1541 | 1544 |
1542 if (!InstallExtensions(extensions)) return; | 1545 if (!InstallExtensions(extensions)) return; |
1543 | 1546 |
1544 if (!InstallSpecialObjects()) return; | 1547 if (!InstallSpecialObjects()) return; |
1545 | 1548 |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1581 } | 1584 } |
1582 | 1585 |
1583 | 1586 |
1584 // Restore statics that are thread local. | 1587 // Restore statics that are thread local. |
1585 char* Genesis::RestoreState(char* from) { | 1588 char* Genesis::RestoreState(char* from) { |
1586 current_ = *reinterpret_cast<Genesis**>(from); | 1589 current_ = *reinterpret_cast<Genesis**>(from); |
1587 return from + sizeof(current_); | 1590 return from + sizeof(current_); |
1588 } | 1591 } |
1589 | 1592 |
1590 } } // namespace v8::internal | 1593 } } // namespace v8::internal |
OLD | NEW |