summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Ulya Trafimovich <skvadrik@google.com> 2023-02-20 15:08:36 +0000
committer Ulya Trofimovich <skvadrik@google.com> 2023-03-07 17:26:30 +0000
commit8c33e973af8a5cfcd3aa520e7475f53ab9e4831b (patch)
tree6e9882aa866b99cc94d26a04ac7082d3dcbc5947
parent9e8a95c5fcdb755bb9d99a02dd26ddcf67cf5f5c (diff)
Clean up unnecessary qualifications for class members in class methods.
Test: treehugger Change-Id: Idf970cad3088cef718482cffff7d884bce719b18
-rw-r--r--runtime/arch/arm/context_arm.cc8
-rw-r--r--runtime/arch/arm64/context_arm64.cc8
-rw-r--r--runtime/arch/riscv64/context_riscv64.cc8
-rw-r--r--runtime/arch/x86/context_x86.cc8
-rw-r--r--runtime/arch/x86_64/context_x86_64.cc8
5 files changed, 20 insertions, 20 deletions
diff --git a/runtime/arch/arm/context_arm.cc b/runtime/arch/arm/context_arm.cc
index 711452cffb..e118daa300 100644
--- a/runtime/arch/arm/context_arm.cc
+++ b/runtime/arch/arm/context_arm.cc
@@ -33,8 +33,8 @@ void ArmContext::Reset() {
gprs_[PC] = &pc_;
gprs_[R0] = &arg0_;
// Initialize registers with easy to spot debug values.
- sp_ = ArmContext::kBadGprBase + SP;
- pc_ = ArmContext::kBadGprBase + PC;
+ sp_ = kBadGprBase + SP;
+ pc_ = kBadGprBase + PC;
arg0_ = 0;
}
@@ -103,10 +103,10 @@ void ArmContext::DoLongJump() {
uintptr_t gprs[kNumberOfCoreRegisters];
uint32_t fprs[kNumberOfSRegisters];
for (size_t i = 0; i < kNumberOfCoreRegisters; ++i) {
- gprs[i] = gprs_[i] != nullptr ? *gprs_[i] : ArmContext::kBadGprBase + i;
+ gprs[i] = gprs_[i] != nullptr ? *gprs_[i] : kBadGprBase + i;
}
for (size_t i = 0; i < kNumberOfSRegisters; ++i) {
- fprs[i] = fprs_[i] != nullptr ? *fprs_[i] : ArmContext::kBadFprBase + i;
+ fprs[i] = fprs_[i] != nullptr ? *fprs_[i] : kBadFprBase + i;
}
// Ensure the Thread Register contains the address of the current thread.
DCHECK_EQ(reinterpret_cast<uintptr_t>(Thread::Current()), gprs[TR]);
diff --git a/runtime/arch/arm64/context_arm64.cc b/runtime/arch/arm64/context_arm64.cc
index 569457a47a..82dd22b692 100644
--- a/runtime/arch/arm64/context_arm64.cc
+++ b/runtime/arch/arm64/context_arm64.cc
@@ -45,8 +45,8 @@ void Arm64Context::Reset() {
gprs_[kPC] = &pc_;
gprs_[X0] = &arg0_;
// Initialize registers with easy to spot debug values.
- sp_ = Arm64Context::kBadGprBase + SP;
- pc_ = Arm64Context::kBadGprBase + kPC;
+ sp_ = kBadGprBase + SP;
+ pc_ = kBadGprBase + kPC;
arg0_ = 0;
}
@@ -156,10 +156,10 @@ __attribute__((no_sanitize("memtag"))) void Arm64Context::DoLongJump() {
DCHECK_EQ(SP, 31);
for (size_t i = 0; i < arraysize(gprs_); ++i) {
- gprs[i] = gprs_[i] != nullptr ? *gprs_[i] : Arm64Context::kBadGprBase + i;
+ gprs[i] = gprs_[i] != nullptr ? *gprs_[i] : kBadGprBase + i;
}
for (size_t i = 0; i < kNumberOfDRegisters; ++i) {
- fprs[i] = fprs_[i] != nullptr ? *fprs_[i] : Arm64Context::kBadFprBase + i;
+ fprs[i] = fprs_[i] != nullptr ? *fprs_[i] : kBadFprBase + i;
}
// Ensure the Thread Register contains the address of the current thread.
DCHECK_EQ(reinterpret_cast<uintptr_t>(Thread::Current()), gprs[TR]);
diff --git a/runtime/arch/riscv64/context_riscv64.cc b/runtime/arch/riscv64/context_riscv64.cc
index b7683f445e..84bd963d95 100644
--- a/runtime/arch/riscv64/context_riscv64.cc
+++ b/runtime/arch/riscv64/context_riscv64.cc
@@ -41,8 +41,8 @@ void Riscv64Context::Reset() {
gprs_[kPC] = &pc_;
gprs_[A0] = &arg0_;
// Initialize registers with easy to spot debug values.
- sp_ = Riscv64Context::kBadGprBase + SP;
- pc_ = Riscv64Context::kBadGprBase + kPC;
+ sp_ = kBadGprBase + SP;
+ pc_ = kBadGprBase + kPC;
arg0_ = 0;
}
@@ -134,10 +134,10 @@ void Riscv64Context::DoLongJump() {
DCHECK_EQ(SP, 2);
for (size_t i = 0; i < arraysize(gprs_); ++i) {
- gprs[i] = gprs_[i] != nullptr ? *gprs_[i] : Riscv64Context::kBadGprBase + i;
+ gprs[i] = gprs_[i] != nullptr ? *gprs_[i] : kBadGprBase + i;
}
for (size_t i = 0; i < kNumberOfFRegisters; ++i) {
- fprs[i] = fprs_[i] != nullptr ? *fprs_[i] : Riscv64Context::kBadFprBase + i;
+ fprs[i] = fprs_[i] != nullptr ? *fprs_[i] : kBadFprBase + i;
}
// Fill in TR (the ART Thread Register) with the address of the current thread.
diff --git a/runtime/arch/x86/context_x86.cc b/runtime/arch/x86/context_x86.cc
index 5c3171299c..cff3d7fc75 100644
--- a/runtime/arch/x86/context_x86.cc
+++ b/runtime/arch/x86/context_x86.cc
@@ -32,8 +32,8 @@ void X86Context::Reset() {
gprs_[ESP] = &esp_;
gprs_[EAX] = &arg0_;
// Initialize registers with easy to spot debug values.
- esp_ = X86Context::kBadGprBase + ESP;
- eip_ = X86Context::kBadGprBase + kNumberOfCpuRegisters;
+ esp_ = kBadGprBase + ESP;
+ eip_ = kBadGprBase + kNumberOfCpuRegisters;
arg0_ = 0;
}
@@ -94,11 +94,11 @@ void X86Context::DoLongJump() {
// the top for the stack pointer that doesn't get popped in a pop-all.
volatile uintptr_t gprs[kNumberOfCpuRegisters + 1];
for (size_t i = 0; i < kNumberOfCpuRegisters; ++i) {
- gprs[kNumberOfCpuRegisters - i - 1] = gprs_[i] != nullptr ? *gprs_[i] : X86Context::kBadGprBase + i;
+ gprs[kNumberOfCpuRegisters - i - 1] = gprs_[i] != nullptr ? *gprs_[i] : kBadGprBase + i;
}
uint32_t fprs[kNumberOfFloatRegisters];
for (size_t i = 0; i < kNumberOfFloatRegisters; ++i) {
- fprs[i] = fprs_[i] != nullptr ? *fprs_[i] : X86Context::kBadFprBase + i;
+ fprs[i] = fprs_[i] != nullptr ? *fprs_[i] : kBadFprBase + i;
}
// We want to load the stack pointer one slot below so that the ret will pop eip.
uintptr_t esp = gprs[kNumberOfCpuRegisters - ESP - 1] - sizeof(intptr_t);
diff --git a/runtime/arch/x86_64/context_x86_64.cc b/runtime/arch/x86_64/context_x86_64.cc
index a4db223b1a..ab3b2c50cb 100644
--- a/runtime/arch/x86_64/context_x86_64.cc
+++ b/runtime/arch/x86_64/context_x86_64.cc
@@ -31,8 +31,8 @@ void X86_64Context::Reset() {
gprs_[RSP] = &rsp_;
gprs_[RDI] = &arg0_;
// Initialize registers with easy to spot debug values.
- rsp_ = X86_64Context::kBadGprBase + RSP;
- rip_ = X86_64Context::kBadGprBase + kNumberOfCpuRegisters;
+ rsp_ = kBadGprBase + RSP;
+ rip_ = kBadGprBase + kNumberOfCpuRegisters;
arg0_ = 0;
}
@@ -108,10 +108,10 @@ void X86_64Context::DoLongJump() {
uintptr_t fprs[kNumberOfFloatRegisters];
for (size_t i = 0; i < kNumberOfCpuRegisters; ++i) {
- gprs[kNumberOfCpuRegisters - i - 1] = gprs_[i] != nullptr ? *gprs_[i] : X86_64Context::kBadGprBase + i;
+ gprs[kNumberOfCpuRegisters - i - 1] = gprs_[i] != nullptr ? *gprs_[i] : kBadGprBase + i;
}
for (size_t i = 0; i < kNumberOfFloatRegisters; ++i) {
- fprs[i] = fprs_[i] != nullptr ? *fprs_[i] : X86_64Context::kBadFprBase + i;
+ fprs[i] = fprs_[i] != nullptr ? *fprs_[i] : kBadFprBase + i;
}
// We want to load the stack pointer one slot below so that the ret will pop eip.