Mass renaming. I love clang-format.
This commit is contained in:
@@ -57,18 +57,18 @@ PPCFrontend::~PPCFrontend() {
|
||||
|
||||
Memory* PPCFrontend::memory() const { return processor_->memory(); }
|
||||
|
||||
void CheckGlobalLock(PPCContext* ppc_state, void* arg0, void* arg1) {
|
||||
ppc_state->scratch = 0x8000;
|
||||
void CheckGlobalLock(PPCContext* ppc_context, void* arg0, void* arg1) {
|
||||
ppc_context->scratch = 0x8000;
|
||||
}
|
||||
void HandleGlobalLock(PPCContext* ppc_state, void* arg0, void* arg1) {
|
||||
void HandleGlobalLock(PPCContext* ppc_context, void* arg0, void* arg1) {
|
||||
auto global_lock = reinterpret_cast<xe::mutex*>(arg0);
|
||||
volatile bool* global_lock_taken = reinterpret_cast<bool*>(arg1);
|
||||
uint64_t value = ppc_state->scratch;
|
||||
uint64_t value = ppc_context->scratch;
|
||||
if (value == 0x8000) {
|
||||
global_lock->lock();
|
||||
*global_lock_taken = false;
|
||||
global_lock->unlock();
|
||||
} else if (value == ppc_state->r[13]) {
|
||||
} else if (value == ppc_context->r[13]) {
|
||||
global_lock->lock();
|
||||
*global_lock_taken = true;
|
||||
global_lock->unlock();
|
||||
|
||||
@@ -233,13 +233,13 @@ class TestRunner {
|
||||
}
|
||||
|
||||
bool SetupTestState(TestCase& test_case) {
|
||||
auto ppc_state = thread_state->context();
|
||||
auto ppc_context = thread_state->context();
|
||||
for (auto& it : test_case.annotations) {
|
||||
if (it.first == "REGISTER_IN") {
|
||||
size_t space_pos = it.second.find(" ");
|
||||
auto reg_name = it.second.substr(0, space_pos);
|
||||
auto reg_value = it.second.substr(space_pos + 1);
|
||||
ppc_state->SetRegFromString(reg_name.c_str(), reg_value.c_str());
|
||||
ppc_context->SetRegFromString(reg_name.c_str(), reg_value.c_str());
|
||||
} else if (it.first == "MEMORY_IN") {
|
||||
size_t space_pos = it.second.find(" ");
|
||||
auto address_str = it.second.substr(0, space_pos);
|
||||
@@ -264,7 +264,7 @@ class TestRunner {
|
||||
}
|
||||
|
||||
bool CheckTestResults(TestCase& test_case) {
|
||||
auto ppc_state = thread_state->context();
|
||||
auto ppc_context = thread_state->context();
|
||||
|
||||
char actual_value[2048];
|
||||
|
||||
@@ -274,9 +274,9 @@ class TestRunner {
|
||||
size_t space_pos = it.second.find(" ");
|
||||
auto reg_name = it.second.substr(0, space_pos);
|
||||
auto reg_value = it.second.substr(space_pos + 1);
|
||||
if (!ppc_state->CompareRegWithString(reg_name.c_str(),
|
||||
reg_value.c_str(), actual_value,
|
||||
xe::countof(actual_value))) {
|
||||
if (!ppc_context->CompareRegWithString(reg_name.c_str(),
|
||||
reg_value.c_str(), actual_value,
|
||||
xe::countof(actual_value))) {
|
||||
any_failed = true;
|
||||
printf("Register %s assert failed:\n", reg_name.c_str());
|
||||
printf(" Expected: %s == %s\n", reg_name.c_str(), reg_value.c_str());
|
||||
|
||||
Reference in New Issue
Block a user