OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_MIPS | 7 #if V8_TARGET_ARCH_MIPS |
8 | 8 |
9 #include "src/codegen.h" | 9 #include "src/codegen.h" |
10 #include "src/macro-assembler.h" | 10 #include "src/macro-assembler.h" |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 return FUNCTION_CAST<UnaryMathFunction>(buffer); | 66 return FUNCTION_CAST<UnaryMathFunction>(buffer); |
67 #else | 67 #else |
68 fast_exp_mips_machine_code = buffer; | 68 fast_exp_mips_machine_code = buffer; |
69 return &fast_exp_simulator; | 69 return &fast_exp_simulator; |
70 #endif | 70 #endif |
71 } | 71 } |
72 | 72 |
73 | 73 |
74 #if defined(V8_HOST_ARCH_MIPS) | 74 #if defined(V8_HOST_ARCH_MIPS) |
75 MemCopyUint8Function CreateMemCopyUint8Function(MemCopyUint8Function stub) { | 75 MemCopyUint8Function CreateMemCopyUint8Function(MemCopyUint8Function stub) { |
76 #if defined(USE_SIMULATOR) | 76 #if defined(USE_SIMULATOR) || defined(_MIPS_ARCH_MIPS32R6) || \ |
| 77 defined(_MIPS_ARCH_MIPS32RX) |
77 return stub; | 78 return stub; |
78 #else | 79 #else |
79 size_t actual_size; | 80 size_t actual_size; |
80 byte* buffer = | 81 byte* buffer = |
81 static_cast<byte*>(base::OS::Allocate(3 * KB, &actual_size, true)); | 82 static_cast<byte*>(base::OS::Allocate(3 * KB, &actual_size, true)); |
82 if (buffer == NULL) return stub; | 83 if (buffer == NULL) return stub; |
83 | 84 |
84 // This code assumes that cache lines are 32 bytes and if the cache line is | 85 // This code assumes that cache lines are 32 bytes and if the cache line is |
85 // larger it will not work correctly. | 86 // larger it will not work correctly. |
86 MacroAssembler masm(NULL, buffer, static_cast<int>(actual_size)); | 87 MacroAssembler masm(NULL, buffer, static_cast<int>(actual_size)); |
(...skipping 1155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1242 patcher.masm()->nop(); // Pad the empty space. | 1243 patcher.masm()->nop(); // Pad the empty space. |
1243 } | 1244 } |
1244 } | 1245 } |
1245 | 1246 |
1246 | 1247 |
1247 #undef __ | 1248 #undef __ |
1248 | 1249 |
1249 } } // namespace v8::internal | 1250 } } // namespace v8::internal |
1250 | 1251 |
1251 #endif // V8_TARGET_ARCH_MIPS | 1252 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |