OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 <stdlib.h> | 5 #include <stdlib.h> |
6 #include <cmath> | 6 #include <cmath> |
7 #include <cstdarg> | 7 #include <cstdarg> |
8 | 8 |
9 #if V8_TARGET_ARCH_ARM64 | 9 #if V8_TARGET_ARCH_ARM64 |
10 | 10 |
(...skipping 1944 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1955 void Simulator::VisitLoadStoreAcquireRelease(Instruction* instr) { | 1955 void Simulator::VisitLoadStoreAcquireRelease(Instruction* instr) { |
1956 unsigned rs = instr->Rs(); | 1956 unsigned rs = instr->Rs(); |
1957 unsigned rt = instr->Rt(); | 1957 unsigned rt = instr->Rt(); |
1958 unsigned rn = instr->Rn(); | 1958 unsigned rn = instr->Rn(); |
1959 LoadStoreAcquireReleaseOp op = static_cast<LoadStoreAcquireReleaseOp>( | 1959 LoadStoreAcquireReleaseOp op = static_cast<LoadStoreAcquireReleaseOp>( |
1960 instr->Mask(LoadStoreAcquireReleaseMask)); | 1960 instr->Mask(LoadStoreAcquireReleaseMask)); |
1961 int32_t is_acquire_release = instr->LoadStoreXAcquireRelease(); | 1961 int32_t is_acquire_release = instr->LoadStoreXAcquireRelease(); |
1962 int32_t is_not_exclusive = instr->LoadStoreXNotExclusive(); | 1962 int32_t is_not_exclusive = instr->LoadStoreXNotExclusive(); |
1963 int32_t is_load = instr->LoadStoreXLoad(); | 1963 int32_t is_load = instr->LoadStoreXLoad(); |
1964 int32_t is_pair = instr->LoadStoreXPair(); | 1964 int32_t is_pair = instr->LoadStoreXPair(); |
| 1965 USE(is_acquire_release); |
| 1966 USE(is_not_exclusive); |
| 1967 USE(is_pair); |
1965 DCHECK_NE(is_acquire_release, 0); | 1968 DCHECK_NE(is_acquire_release, 0); |
1966 DCHECK_EQ(is_not_exclusive, 0); // Non exclusive unimplemented. | 1969 DCHECK_EQ(is_not_exclusive, 0); // Non exclusive unimplemented. |
1967 DCHECK_EQ(is_pair, 0); // Pair unimplemented. | 1970 DCHECK_EQ(is_pair, 0); // Pair unimplemented. |
1968 unsigned access_size = 1 << instr->LoadStoreXSizeLog2(); | 1971 unsigned access_size = 1 << instr->LoadStoreXSizeLog2(); |
1969 uintptr_t address = LoadStoreAddress(rn, 0, AddrMode::Offset); | 1972 uintptr_t address = LoadStoreAddress(rn, 0, AddrMode::Offset); |
1970 DCHECK(address % access_size == 0); | 1973 DCHECK(address % access_size == 0); |
1971 base::LockGuard<base::Mutex> lock_guard(&global_monitor_.Pointer()->mutex); | 1974 base::LockGuard<base::Mutex> lock_guard(&global_monitor_.Pointer()->mutex); |
1972 if (is_load != 0) { | 1975 if (is_load != 0) { |
1973 local_monitor_.NotifyLoadExcl(address, get_transaction_size(access_size)); | 1976 local_monitor_.NotifyLoadExcl(address, get_transaction_size(access_size)); |
1974 global_monitor_.Pointer()->NotifyLoadExcl_Locked( | 1977 global_monitor_.Pointer()->NotifyLoadExcl_Locked( |
(...skipping 2185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4160 processor->prev_ = nullptr; | 4163 processor->prev_ = nullptr; |
4161 processor->next_ = nullptr; | 4164 processor->next_ = nullptr; |
4162 } | 4165 } |
4163 | 4166 |
4164 #endif // USE_SIMULATOR | 4167 #endif // USE_SIMULATOR |
4165 | 4168 |
4166 } // namespace internal | 4169 } // namespace internal |
4167 } // namespace v8 | 4170 } // namespace v8 |
4168 | 4171 |
4169 #endif // V8_TARGET_ARCH_ARM64 | 4172 #endif // V8_TARGET_ARCH_ARM64 |
OLD | NEW |