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 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
47 bool V8::has_been_disposed_ = false; | 47 bool V8::has_been_disposed_ = false; |
48 bool V8::has_fatal_error_ = false; | 48 bool V8::has_fatal_error_ = false; |
49 bool V8::use_crankshaft_ = true; | 49 bool V8::use_crankshaft_ = true; |
50 | 50 |
51 | 51 |
52 bool V8::Initialize(Deserializer* des) { | 52 bool V8::Initialize(Deserializer* des) { |
53 bool create_heap_objects = des == NULL; | 53 bool create_heap_objects = des == NULL; |
54 if (has_been_disposed_ || has_fatal_error_) return false; | 54 if (has_been_disposed_ || has_fatal_error_) return false; |
55 if (IsRunning()) return true; | 55 if (IsRunning()) return true; |
56 | 56 |
| 57 #if defined(V8_TARGET_ARCH_ARM) && !defined(USE_ARM_EABI) |
| 58 use_crankshaft_ = false; |
| 59 #else |
57 use_crankshaft_ = FLAG_crankshaft; | 60 use_crankshaft_ = FLAG_crankshaft; |
| 61 #endif |
| 62 |
58 // Peephole optimization might interfere with deoptimization. | 63 // Peephole optimization might interfere with deoptimization. |
59 FLAG_peephole_optimization = !use_crankshaft_; | 64 FLAG_peephole_optimization = !use_crankshaft_; |
60 is_running_ = true; | 65 is_running_ = true; |
61 has_been_setup_ = true; | 66 has_been_setup_ = true; |
62 has_fatal_error_ = false; | 67 has_fatal_error_ = false; |
63 has_been_disposed_ = false; | 68 has_been_disposed_ = false; |
64 #ifdef DEBUG | 69 #ifdef DEBUG |
65 // The initialization process does not handle memory exhaustion. | 70 // The initialization process does not handle memory exhaustion. |
66 DisallowAllocationFailure disallow_allocation_failure; | 71 DisallowAllocationFailure disallow_allocation_failure; |
67 #endif | 72 #endif |
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
256 // ( 1.(20 0s)(32 random bits) x 2^20 ) - (1.0 x 2^20)). | 261 // ( 1.(20 0s)(32 random bits) x 2^20 ) - (1.0 x 2^20)). |
257 const double binary_million = 1048576.0; | 262 const double binary_million = 1048576.0; |
258 r->double_value = binary_million; | 263 r->double_value = binary_million; |
259 r->uint64_t_value |= random_bits; | 264 r->uint64_t_value |= random_bits; |
260 r->double_value -= binary_million; | 265 r->double_value -= binary_million; |
261 | 266 |
262 return heap_number; | 267 return heap_number; |
263 } | 268 } |
264 | 269 |
265 } } // namespace v8::internal | 270 } } // namespace v8::internal |
OLD | NEW |