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 28 matching lines...) Expand all Loading... |
39 | 39 |
40 #if V8_TARGET_ARCH_ARM | 40 #if V8_TARGET_ARCH_ARM |
41 | 41 |
42 #include "cpu.h" | 42 #include "cpu.h" |
43 #include "macro-assembler.h" | 43 #include "macro-assembler.h" |
44 #include "simulator.h" // for cache flushing. | 44 #include "simulator.h" // for cache flushing. |
45 | 45 |
46 namespace v8 { | 46 namespace v8 { |
47 namespace internal { | 47 namespace internal { |
48 | 48 |
49 void CPU::SetUp() { | |
50 CpuFeatures::Probe(); | |
51 } | |
52 | |
53 | |
54 bool CPU::SupportsCrankshaft() { | |
55 return CpuFeatures::IsSupported(VFP3); | |
56 } | |
57 | |
58 | |
59 void CPU::FlushICache(void* start, size_t size) { | 49 void CPU::FlushICache(void* start, size_t size) { |
60 // Nothing to do flushing no instructions. | 50 // Nothing to do flushing no instructions. |
61 if (size == 0) { | 51 if (size == 0) { |
62 return; | 52 return; |
63 } | 53 } |
64 | 54 |
65 #if defined(USE_SIMULATOR) | 55 #if defined(USE_SIMULATOR) |
66 // Not generating ARM instructions for C-code. This means that we are | 56 // Not generating ARM instructions for C-code. This means that we are |
67 // building an ARM emulator based target. We should notify the simulator | 57 // building an ARM emulator based target. We should notify the simulator |
68 // that the Icache was flushed. | 58 // that the Icache was flushed. |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
109 : "=r" (beg) | 99 : "=r" (beg) |
110 : "0" (beg), "r" (end), "r" (flg), "r" (__ARM_NR_cacheflush) | 100 : "0" (beg), "r" (end), "r" (flg), "r" (__ARM_NR_cacheflush) |
111 : "r3"); | 101 : "r3"); |
112 #endif | 102 #endif |
113 #endif | 103 #endif |
114 } | 104 } |
115 | 105 |
116 } } // namespace v8::internal | 106 } } // namespace v8::internal |
117 | 107 |
118 #endif // V8_TARGET_ARCH_ARM | 108 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |