1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 04:02:41 +01:00

[NFC] Fix typo and variable names

This commit is contained in:
Aditya Kumar 2020-08-15 08:51:48 -07:00
parent f6650786b0
commit d33455c31b

View File

@ -21,7 +21,7 @@
namespace llvm {
/// Atomic ordering for C11 / C++11's memody models.
/// Atomic ordering for C11 / C++11's memory models.
///
/// These values cannot change because they are shared with standard library
/// implementations as well as with other compilers.
@ -87,7 +87,7 @@ inline const char *toIRString(AtomicOrdering ao) {
/// Returns true if ao is stronger than other as defined by the AtomicOrdering
/// lattice, which is based on C++'s definition.
inline bool isStrongerThan(AtomicOrdering ao, AtomicOrdering other) {
inline bool isStrongerThan(AtomicOrdering AO, AtomicOrdering Other) {
static const bool lookup[8][8] = {
// NA UN RX CO AC RE AR SC
/* NotAtomic */ {false, false, false, false, false, false, false, false},
@ -99,10 +99,10 @@ inline bool isStrongerThan(AtomicOrdering ao, AtomicOrdering other) {
/* acq_rel */ { true, true, true, true, true, true, false, false},
/* seq_cst */ { true, true, true, true, true, true, true, false},
};
return lookup[static_cast<size_t>(ao)][static_cast<size_t>(other)];
return lookup[static_cast<size_t>(AO)][static_cast<size_t>(Other)];
}
inline bool isAtLeastOrStrongerThan(AtomicOrdering ao, AtomicOrdering other) {
inline bool isAtLeastOrStrongerThan(AtomicOrdering AO, AtomicOrdering Other) {
static const bool lookup[8][8] = {
// NA UN RX CO AC RE AR SC
/* NotAtomic */ { true, false, false, false, false, false, false, false},
@ -114,26 +114,26 @@ inline bool isAtLeastOrStrongerThan(AtomicOrdering ao, AtomicOrdering other) {
/* acq_rel */ { true, true, true, true, true, true, true, false},
/* seq_cst */ { true, true, true, true, true, true, true, true},
};
return lookup[static_cast<size_t>(ao)][static_cast<size_t>(other)];
return lookup[static_cast<size_t>(AO)][static_cast<size_t>(Other)];
}
inline bool isStrongerThanUnordered(AtomicOrdering ao) {
return isStrongerThan(ao, AtomicOrdering::Unordered);
inline bool isStrongerThanUnordered(AtomicOrdering AO) {
return isStrongerThan(AO, AtomicOrdering::Unordered);
}
inline bool isStrongerThanMonotonic(AtomicOrdering ao) {
return isStrongerThan(ao, AtomicOrdering::Monotonic);
inline bool isStrongerThanMonotonic(AtomicOrdering AO) {
return isStrongerThan(AO, AtomicOrdering::Monotonic);
}
inline bool isAcquireOrStronger(AtomicOrdering ao) {
return isAtLeastOrStrongerThan(ao, AtomicOrdering::Acquire);
inline bool isAcquireOrStronger(AtomicOrdering AO) {
return isAtLeastOrStrongerThan(AO, AtomicOrdering::Acquire);
}
inline bool isReleaseOrStronger(AtomicOrdering ao) {
return isAtLeastOrStrongerThan(ao, AtomicOrdering::Release);
inline bool isReleaseOrStronger(AtomicOrdering AO) {
return isAtLeastOrStrongerThan(AO, AtomicOrdering::Release);
}
inline AtomicOrderingCABI toCABI(AtomicOrdering ao) {
inline AtomicOrderingCABI toCABI(AtomicOrdering AO) {
static const AtomicOrderingCABI lookup[8] = {
/* NotAtomic */ AtomicOrderingCABI::relaxed,
/* Unordered */ AtomicOrderingCABI::relaxed,
@ -144,7 +144,7 @@ inline AtomicOrderingCABI toCABI(AtomicOrdering ao) {
/* acq_rel */ AtomicOrderingCABI::acq_rel,
/* seq_cst */ AtomicOrderingCABI::seq_cst,
};
return lookup[static_cast<size_t>(ao)];
return lookup[static_cast<size_t>(AO)];
}
} // end namespace llvm