| OLD | NEW |
| 1 // Copyright 2006-2009 the V8 project authors. All rights reserved. | 1 // Copyright 2006-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 12 matching lines...) Expand all Loading... |
| 23 // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 23 // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
| 24 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 24 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 25 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 25 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 27 | 27 |
| 28 #include "v8.h" | 28 #include "v8.h" |
| 29 | 29 |
| 30 #include "bootstrapper.h" | 30 #include "bootstrapper.h" |
| 31 #include "debug.h" | 31 #include "debug.h" |
| 32 #include "serialize.h" | 32 #include "serialize.h" |
| 33 #include "simulator.h" |
| 33 #include "stub-cache.h" | 34 #include "stub-cache.h" |
| 34 #include "oprofile-agent.h" | 35 #include "oprofile-agent.h" |
| 35 | 36 |
| 36 #if V8_TARGET_ARCH_ARM | |
| 37 #include "arm/simulator-arm.h" | |
| 38 #endif | |
| 39 | |
| 40 namespace v8 { | 37 namespace v8 { |
| 41 namespace internal { | 38 namespace internal { |
| 42 | 39 |
| 43 bool V8::is_running_ = false; | 40 bool V8::is_running_ = false; |
| 44 bool V8::has_been_setup_ = false; | 41 bool V8::has_been_setup_ = false; |
| 45 bool V8::has_been_disposed_ = false; | 42 bool V8::has_been_disposed_ = false; |
| 46 bool V8::has_fatal_error_ = false; | 43 bool V8::has_fatal_error_ = false; |
| 47 | 44 |
| 48 bool V8::Initialize(GenericDeserializer *des) { | 45 bool V8::Initialize(GenericDeserializer *des) { |
| 49 bool create_heap_objects = des == NULL; | 46 bool create_heap_objects = des == NULL; |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 | 179 |
| 183 Smi* V8::RandomPositiveSmi() { | 180 Smi* V8::RandomPositiveSmi() { |
| 184 uint32_t random = Random(); | 181 uint32_t random = Random(); |
| 185 ASSERT(static_cast<uint32_t>(Smi::kMaxValue) >= kRandomPositiveSmiMax); | 182 ASSERT(static_cast<uint32_t>(Smi::kMaxValue) >= kRandomPositiveSmiMax); |
| 186 // kRandomPositiveSmiMax must match the value being divided | 183 // kRandomPositiveSmiMax must match the value being divided |
| 187 // by in math.js. | 184 // by in math.js. |
| 188 return Smi::FromInt(random & kRandomPositiveSmiMax); | 185 return Smi::FromInt(random & kRandomPositiveSmiMax); |
| 189 } | 186 } |
| 190 | 187 |
| 191 } } // namespace v8::internal | 188 } } // namespace v8::internal |
| OLD | NEW |