aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoshua Peraza <jperaza@chromium.org>2018-07-31 13:30:11 -0700
committerJoshua Peraza <jperaza@chromium.org>2018-08-01 19:26:38 +0000
commit627ef0cb9c705444da6ca7515bc5ca6b3169e1aa (patch)
tree1950e4f4d7d890fd8171689cb886297241c54691
parentmac: Fix broken xcode projects (diff)
downloadbreakpad-627ef0cb9c705444da6ca7515bc5ca6b3169e1aa.tar.xz
Rename MDRawContextARM64 and its context flags
This makes way for the addition of a struct matching Microsoft's layout for ARM64. Change-Id: I115f25290863e7438852691d1ec3c9324a42f7a5 Reviewed-on: https://chromium-review.googlesource.com/1152158 Reviewed-by: Mark Mentovai <mark@chromium.org> Reviewed-by: Mike Frysinger <vapier@chromium.org>
-rw-r--r--src/client/ios/handler/ios_exception_minidump_generator.mm6
-rw-r--r--src/client/linux/dump_writer_common/raw_context_cpu.h2
-rw-r--r--src/client/linux/dump_writer_common/thread_info.cc2
-rw-r--r--src/client/linux/dump_writer_common/ucontext_reader.cc2
-rw-r--r--src/client/linux/minidump_writer/minidump_writer.cc2
-rw-r--r--src/client/mac/handler/minidump_generator.cc8
-rw-r--r--src/google_breakpad/common/minidump_cpu_arm64.h24
-rw-r--r--src/google_breakpad/common/minidump_format.h2
-rw-r--r--src/google_breakpad/processor/dump_context.h6
-rw-r--r--src/google_breakpad/processor/microdump.h2
-rw-r--r--src/google_breakpad/processor/stack_frame_cpu.h2
-rw-r--r--src/processor/dump_context.cc22
-rw-r--r--src/processor/microdump.cc10
-rw-r--r--src/processor/minidump.cc26
-rw-r--r--src/processor/minidump_processor.cc8
-rw-r--r--src/processor/stackwalker.cc2
-rw-r--r--src/processor/stackwalker_arm64.cc2
-rw-r--r--src/processor/stackwalker_arm64.h4
-rw-r--r--src/processor/stackwalker_arm64_unittest.cc6
-rw-r--r--src/tools/linux/md2core/minidump-2-core.cc4
20 files changed, 71 insertions, 71 deletions
diff --git a/src/client/ios/handler/ios_exception_minidump_generator.mm b/src/client/ios/handler/ios_exception_minidump_generator.mm
index 82ea5bb5..f57bdf21 100644
--- a/src/client/ios/handler/ios_exception_minidump_generator.mm
+++ b/src/client/ios/handler/ios_exception_minidump_generator.mm
@@ -108,13 +108,13 @@ bool IosExceptionMinidumpGenerator::WriteCrashingContextARM(
#ifdef HAS_ARM64_SUPPORT
bool IosExceptionMinidumpGenerator::WriteCrashingContextARM64(
MDLocationDescriptor *register_location) {
- TypedMDRVA<MDRawContextARM64> context(&writer_);
+ TypedMDRVA<MDRawContextARM64_Old> context(&writer_);
if (!context.Allocate())
return false;
*register_location = context.location();
- MDRawContextARM64 *context_ptr = context.get();
+ MDRawContextARM64_Old *context_ptr = context.get();
memset(context_ptr, 0, sizeof(*context_ptr));
- context_ptr->context_flags = MD_CONTEXT_ARM64_FULL;
+ context_ptr->context_flags = MD_CONTEXT_ARM64_FULL_OLD;
context_ptr->iregs[MD_CONTEXT_ARM64_REG_FP] = kExpectedFinalFp; // FP
context_ptr->iregs[MD_CONTEXT_ARM64_REG_SP] = kExpectedFinalSp; // SP
context_ptr->iregs[MD_CONTEXT_ARM64_REG_LR] = GetLRFromException(); // LR
diff --git a/src/client/linux/dump_writer_common/raw_context_cpu.h b/src/client/linux/dump_writer_common/raw_context_cpu.h
index e2ef45df..07d9171a 100644
--- a/src/client/linux/dump_writer_common/raw_context_cpu.h
+++ b/src/client/linux/dump_writer_common/raw_context_cpu.h
@@ -41,7 +41,7 @@ typedef MDRawContextAMD64 RawContextCPU;
#elif defined(__ARM_EABI__)
typedef MDRawContextARM RawContextCPU;
#elif defined(__aarch64__)
-typedef MDRawContextARM64 RawContextCPU;
+typedef MDRawContextARM64_Old RawContextCPU;
#elif defined(__mips__)
typedef MDRawContextMIPS RawContextCPU;
#else
diff --git a/src/client/linux/dump_writer_common/thread_info.cc b/src/client/linux/dump_writer_common/thread_info.cc
index 0a1041d6..aae1dc13 100644
--- a/src/client/linux/dump_writer_common/thread_info.cc
+++ b/src/client/linux/dump_writer_common/thread_info.cc
@@ -214,7 +214,7 @@ uintptr_t ThreadInfo::GetInstructionPointer() const {
}
void ThreadInfo::FillCPUContext(RawContextCPU* out) const {
- out->context_flags = MD_CONTEXT_ARM64_FULL;
+ out->context_flags = MD_CONTEXT_ARM64_FULL_OLD;
out->cpsr = static_cast<uint32_t>(regs.pstate);
for (int i = 0; i < MD_CONTEXT_ARM64_REG_SP; ++i)
diff --git a/src/client/linux/dump_writer_common/ucontext_reader.cc b/src/client/linux/dump_writer_common/ucontext_reader.cc
index 052ce37c..6ee6cc1e 100644
--- a/src/client/linux/dump_writer_common/ucontext_reader.cc
+++ b/src/client/linux/dump_writer_common/ucontext_reader.cc
@@ -194,7 +194,7 @@ uintptr_t UContextReader::GetInstructionPointer(const ucontext_t* uc) {
void UContextReader::FillCPUContext(RawContextCPU *out, const ucontext_t *uc,
const struct fpsimd_context* fpregs) {
- out->context_flags = MD_CONTEXT_ARM64_FULL;
+ out->context_flags = MD_CONTEXT_ARM64_FULL_OLD;
out->cpsr = static_cast<uint32_t>(uc->uc_mcontext.pstate);
for (int i = 0; i < MD_CONTEXT_ARM64_REG_SP; ++i)
diff --git a/src/client/linux/minidump_writer/minidump_writer.cc b/src/client/linux/minidump_writer/minidump_writer.cc
index cdf4bf65..31e7bd62 100644
--- a/src/client/linux/minidump_writer/minidump_writer.cc
+++ b/src/client/linux/minidump_writer/minidump_writer.cc
@@ -1042,7 +1042,7 @@ class MinidumpWriter {
// processor_architecture should always be set, do this first
sys_info->processor_architecture =
#if defined(__aarch64__)
- MD_CPU_ARCHITECTURE_ARM64;
+ MD_CPU_ARCHITECTURE_ARM64_OLD;
#else
MD_CPU_ARCHITECTURE_ARM;
#endif
diff --git a/src/client/mac/handler/minidump_generator.cc b/src/client/mac/handler/minidump_generator.cc
index 48cd2e99..8c796243 100644
--- a/src/client/mac/handler/minidump_generator.cc
+++ b/src/client/mac/handler/minidump_generator.cc
@@ -545,7 +545,7 @@ bool
MinidumpGenerator::WriteContextARM64(breakpad_thread_state_data_t state,
MDLocationDescriptor *register_location)
{
- TypedMDRVA<MDRawContextARM64> context(&writer_);
+ TypedMDRVA<MDRawContextARM64_Old> context(&writer_);
arm_thread_state64_t *machine_state =
reinterpret_cast<arm_thread_state64_t *>(state);
@@ -553,8 +553,8 @@ MinidumpGenerator::WriteContextARM64(breakpad_thread_state_data_t state,
return false;
*register_location = context.location();
- MDRawContextARM64 *context_ptr = context.get();
- context_ptr->context_flags = MD_CONTEXT_ARM64_FULL;
+ MDRawContextARM64_Old *context_ptr = context.get();
+ context_ptr->context_flags = MD_CONTEXT_ARM64_FULL_OLD;
#define AddGPR(a) context_ptr->iregs[a] = \
REGISTER_FROM_THREADSTATE(machine_state, x[a])
@@ -1191,7 +1191,7 @@ bool MinidumpGenerator::WriteSystemInfoStream(
#endif
#ifdef HAS_ARM64_SUPPORT
case CPU_TYPE_ARM64:
- info_ptr->processor_architecture = MD_CPU_ARCHITECTURE_ARM64;
+ info_ptr->processor_architecture = MD_CPU_ARCHITECTURE_ARM64_OLD;
break;
#endif
#ifdef HAS_PPC_SUPPORT
diff --git a/src/google_breakpad/common/minidump_cpu_arm64.h b/src/google_breakpad/common/minidump_cpu_arm64.h
index 5ace0d9d..e146ec99 100644
--- a/src/google_breakpad/common/minidump_cpu_arm64.h
+++ b/src/google_breakpad/common/minidump_cpu_arm64.h
@@ -74,7 +74,7 @@ typedef struct {
/* 32 128-bit floating point registers, d0 .. d31. */
uint128_struct regs[MD_FLOATINGSAVEAREA_ARM64_FPR_COUNT];
-} MDFloatingSaveAreaARM64;
+} MDFloatingSaveAreaARM64_Old;
#define MD_CONTEXT_ARM64_GPR_COUNT 33
@@ -107,9 +107,9 @@ typedef struct {
uint32_t cpsr;
/* The next field is included with MD_CONTEXT64_ARM_FLOATING_POINT */
- MDFloatingSaveAreaARM64 float_save;
+ MDFloatingSaveAreaARM64_Old float_save;
-} MDRawContextARM64;
+} MDRawContextARM64_Old;
#pragma pack(pop)
@@ -123,18 +123,18 @@ enum MDARM64RegisterNumbers {
MD_CONTEXT_ARM64_REG_PC = 32
};
-/* For (MDRawContextARM64).context_flags. These values indicate the type of
- * context stored in the structure. MD_CONTEXT_ARM64 is Breakpad-defined.
+/* For (MDRawContextARM64_Old).context_flags. These values indicate the type of
+ * context stored in the structure. MD_CONTEXT_ARM64_OLD is Breakpad-defined.
* This value was chosen to avoid likely conflicts with MD_CONTEXT_*
* for other CPUs. */
-#define MD_CONTEXT_ARM64 0x80000000
-#define MD_CONTEXT_ARM64_INTEGER (MD_CONTEXT_ARM64 | 0x00000002)
-#define MD_CONTEXT_ARM64_FLOATING_POINT (MD_CONTEXT_ARM64 | 0x00000004)
+#define MD_CONTEXT_ARM64_OLD 0x80000000
+#define MD_CONTEXT_ARM64_INTEGER_OLD (MD_CONTEXT_ARM64_OLD | 0x00000002)
+#define MD_CONTEXT_ARM64_FLOATING_POINT_OLD (MD_CONTEXT_ARM64_OLD | 0x00000004)
-#define MD_CONTEXT_ARM64_FULL (MD_CONTEXT_ARM64_INTEGER | \
- MD_CONTEXT_ARM64_FLOATING_POINT)
+#define MD_CONTEXT_ARM64_FULL_OLD (MD_CONTEXT_ARM64_INTEGER_OLD | \
+ MD_CONTEXT_ARM64_FLOATING_POINT_OLD)
-#define MD_CONTEXT_ARM64_ALL (MD_CONTEXT_ARM64_INTEGER | \
- MD_CONTEXT_ARM64_FLOATING_POINT)
+#define MD_CONTEXT_ARM64_ALL_OLD (MD_CONTEXT_ARM64_INTEGER_OLD | \
+ MD_CONTEXT_ARM64_FLOATING_POINT_OLD)
#endif /* GOOGLE_BREAKPAD_COMMON_MINIDUMP_CPU_ARM64_H__ */
diff --git a/src/google_breakpad/common/minidump_format.h b/src/google_breakpad/common/minidump_format.h
index 225433bb..9db7049a 100644
--- a/src/google_breakpad/common/minidump_format.h
+++ b/src/google_breakpad/common/minidump_format.h
@@ -656,7 +656,7 @@ typedef enum {
/* PROCESSOR_ARCHITECTURE_IA32_ON_WIN64 (WoW64) */
MD_CPU_ARCHITECTURE_SPARC = 0x8001, /* Breakpad-defined value for SPARC */
MD_CPU_ARCHITECTURE_PPC64 = 0x8002, /* Breakpad-defined value for PPC64 */
- MD_CPU_ARCHITECTURE_ARM64 = 0x8003, /* Breakpad-defined value for ARM64 */
+ MD_CPU_ARCHITECTURE_ARM64_OLD = 0x8003, /* Breakpad-defined value for ARM64 */
MD_CPU_ARCHITECTURE_MIPS64 = 0x8004, /* Breakpad-defined value for MIPS64 */
MD_CPU_ARCHITECTURE_UNKNOWN = 0xffff /* PROCESSOR_ARCHITECTURE_UNKNOWN */
} MDCPUArchitecture;
diff --git a/src/google_breakpad/processor/dump_context.h b/src/google_breakpad/processor/dump_context.h
index df80bf7e..455115e5 100644
--- a/src/google_breakpad/processor/dump_context.h
+++ b/src/google_breakpad/processor/dump_context.h
@@ -56,7 +56,7 @@ class DumpContext : public DumpObject {
// context data does not match the CPU type or does not exist, returns NULL.
const MDRawContextAMD64* GetContextAMD64() const;
const MDRawContextARM* GetContextARM() const;
- const MDRawContextARM64* GetContextARM64() const;
+ const MDRawContextARM64_Old* GetContextARM64() const;
const MDRawContextMIPS* GetContextMIPS() const;
const MDRawContextPPC* GetContextPPC() const;
const MDRawContextPPC64* GetContextPPC64() const;
@@ -85,7 +85,7 @@ class DumpContext : public DumpObject {
void SetContextAMD64(MDRawContextAMD64* amd64);
void SetContextSPARC(MDRawContextSPARC* ctx_sparc);
void SetContextARM(MDRawContextARM* arm);
- void SetContextARM64(MDRawContextARM64* arm64);
+ void SetContextARM64(MDRawContextARM64_Old* arm64);
void SetContextMIPS(MDRawContextMIPS* ctx_mips);
// Free the CPU-specific context structure.
@@ -103,7 +103,7 @@ class DumpContext : public DumpObject {
// so variables can NOT be named as sparc
MDRawContextSPARC* ctx_sparc;
MDRawContextARM* arm;
- MDRawContextARM64* arm64;
+ MDRawContextARM64_Old* arm64_old;
MDRawContextMIPS* ctx_mips;
} context_;
diff --git a/src/google_breakpad/processor/microdump.h b/src/google_breakpad/processor/microdump.h
index 02ebdcd7..496f83ce 100644
--- a/src/google_breakpad/processor/microdump.h
+++ b/src/google_breakpad/processor/microdump.h
@@ -68,7 +68,7 @@ class MicrodumpModules : public BasicCodeModules {
class MicrodumpContext : public DumpContext {
public:
virtual void SetContextARM(MDRawContextARM* arm);
- virtual void SetContextARM64(MDRawContextARM64* arm64);
+ virtual void SetContextARM64(MDRawContextARM64_Old* arm64);
virtual void SetContextX86(MDRawContextX86* x86);
virtual void SetContextMIPS(MDRawContextMIPS* mips32);
virtual void SetContextMIPS64(MDRawContextMIPS* mips64);
diff --git a/src/google_breakpad/processor/stack_frame_cpu.h b/src/google_breakpad/processor/stack_frame_cpu.h
index dc5d8ae6..3b2551b5 100644
--- a/src/google_breakpad/processor/stack_frame_cpu.h
+++ b/src/google_breakpad/processor/stack_frame_cpu.h
@@ -327,7 +327,7 @@ struct StackFrameARM64 : public StackFrame {
// stack. In other frames, the values of nonvolatile registers may be
// present, given sufficient debugging information. Refer to
// context_validity.
- MDRawContextARM64 context;
+ MDRawContextARM64_Old context;
// For each register in context whose value has been recovered, we set
// the corresponding CONTEXT_VALID_ bit in context_validity.
diff --git a/src/processor/dump_context.cc b/src/processor/dump_context.cc
index 8dd671e6..198b9501 100644
--- a/src/processor/dump_context.cc
+++ b/src/processor/dump_context.cc
@@ -121,13 +121,13 @@ const MDRawContextARM* DumpContext::GetContextARM() const {
return context_.arm;
}
-const MDRawContextARM64* DumpContext::GetContextARM64() const {
- if (GetContextCPU() != MD_CONTEXT_ARM64) {
+const MDRawContextARM64_Old* DumpContext::GetContextARM64() const {
+ if (GetContextCPU() != MD_CONTEXT_ARM64_OLD) {
BPLOG(ERROR) << "DumpContext cannot get arm64 context";
return NULL;
}
- return context_.arm64;
+ return context_.arm64_old;
}
const MDRawContextMIPS* DumpContext::GetContextMIPS() const {
@@ -157,7 +157,7 @@ bool DumpContext::GetInstructionPointer(uint64_t* ip) const {
case MD_CONTEXT_ARM:
*ip = GetContextARM()->iregs[MD_CONTEXT_ARM_REG_PC];
break;
- case MD_CONTEXT_ARM64:
+ case MD_CONTEXT_ARM64_OLD:
*ip = GetContextARM64()->iregs[MD_CONTEXT_ARM64_REG_PC];
break;
case MD_CONTEXT_PPC:
@@ -201,7 +201,7 @@ bool DumpContext::GetStackPointer(uint64_t* sp) const {
case MD_CONTEXT_ARM:
*sp = GetContextARM()->iregs[MD_CONTEXT_ARM_REG_SP];
break;
- case MD_CONTEXT_ARM64:
+ case MD_CONTEXT_ARM64_OLD:
*sp = GetContextARM64()->iregs[MD_CONTEXT_ARM64_REG_SP];
break;
case MD_CONTEXT_PPC:
@@ -256,8 +256,8 @@ void DumpContext::SetContextARM(MDRawContextARM* arm) {
context_.arm = arm;
}
-void DumpContext::SetContextARM64(MDRawContextARM64* arm64) {
- context_.arm64 = arm64;
+void DumpContext::SetContextARM64(MDRawContextARM64_Old* arm64) {
+ context_.arm64_old = arm64;
}
void DumpContext::SetContextMIPS(MDRawContextMIPS* ctx_mips) {
@@ -290,8 +290,8 @@ void DumpContext::FreeContext() {
delete context_.arm;
break;
- case MD_CONTEXT_ARM64:
- delete context_.arm64;
+ case MD_CONTEXT_ARM64_OLD:
+ delete context_.arm64_old;
break;
case MD_CONTEXT_MIPS:
@@ -581,8 +581,8 @@ void DumpContext::Print() {
break;
}
- case MD_CONTEXT_ARM64: {
- const MDRawContextARM64* context_arm64 = GetContextARM64();
+ case MD_CONTEXT_ARM64_OLD: {
+ const MDRawContextARM64_Old* context_arm64 = GetContextARM64();
printf("MDRawContextARM64\n");
printf(" context_flags = 0x%" PRIx64 "\n",
context_arm64->context_flags);
diff --git a/src/processor/microdump.cc b/src/processor/microdump.cc
index 2473c35c..b100f765 100644
--- a/src/processor/microdump.cc
+++ b/src/processor/microdump.cc
@@ -125,8 +125,8 @@ void MicrodumpContext::SetContextARM(MDRawContextARM* arm) {
valid_ = true;
}
-void MicrodumpContext::SetContextARM64(MDRawContextARM64* arm64) {
- DumpContext::SetContextFlags(MD_CONTEXT_ARM64);
+void MicrodumpContext::SetContextARM64(MDRawContextARM64_Old* arm64) {
+ DumpContext::SetContextFlags(MD_CONTEXT_ARM64_OLD);
DumpContext::SetContextARM64(arm64);
valid_ = true;
}
@@ -311,13 +311,13 @@ Microdump::Microdump(const string& contents)
memcpy(arm, &cpu_state_raw[0], cpu_state_raw.size());
context_->SetContextARM(arm);
} else if (strcmp(arch.c_str(), kArm64Architecture) == 0) {
- if (cpu_state_raw.size() != sizeof(MDRawContextARM64)) {
+ if (cpu_state_raw.size() != sizeof(MDRawContextARM64_Old)) {
std::cerr << "Malformed CPU context. Got " << cpu_state_raw.size()
- << " bytes instead of " << sizeof(MDRawContextARM64)
+ << " bytes instead of " << sizeof(MDRawContextARM64_Old)
<< std::endl;
continue;
}
- MDRawContextARM64* arm = new MDRawContextARM64();
+ MDRawContextARM64_Old* arm = new MDRawContextARM64_Old();
memcpy(arm, &cpu_state_raw[0], cpu_state_raw.size());
context_->SetContextARM64(arm);
} else if (strcmp(arch.c_str(), kX86Architecture) == 0) {
diff --git a/src/processor/minidump.cc b/src/processor/minidump.cc
index 606a5ddd..020b95d3 100644
--- a/src/processor/minidump.cc
+++ b/src/processor/minidump.cc
@@ -104,7 +104,7 @@ bool IsContextSizeUnique(uint32_t context_size) {
num_matching_contexts++;
if (context_size == sizeof(MDRawContextARM))
num_matching_contexts++;
- if (context_size == sizeof(MDRawContextARM64))
+ if (context_size == sizeof(MDRawContextARM64_Old))
num_matching_contexts++;
if (context_size == sizeof(MDRawContextMIPS))
num_matching_contexts++;
@@ -471,8 +471,8 @@ bool MinidumpContext::Read(uint32_t expected_size) {
<< "other raw context";
return false;
}
- if (!IsContextSizeUnique(sizeof(MDRawContextARM64))) {
- BPLOG(ERROR) << "sizeof(MDRawContextARM64) cannot match the size of any "
+ if (!IsContextSizeUnique(sizeof(MDRawContextARM64_Old))) {
+ BPLOG(ERROR) << "sizeof(MDRawContextARM64_Old) cannot match the size of any "
<< "other raw context";
return false;
}
@@ -678,8 +678,8 @@ bool MinidumpContext::Read(uint32_t expected_size) {
}
SetContextPPC64(context_ppc64.release());
- } else if (expected_size == sizeof(MDRawContextARM64)) {
- // |context_flags| of MDRawContextARM64 is 64 bits, but other MDRawContext
+ } else if (expected_size == sizeof(MDRawContextARM64_Old)) {
+ // |context_flags| of MDRawContextARM64_Old is 64 bits, but other MDRawContext
// in the else case have 32 bits |context_flags|, so special case it here.
uint64_t context_flags;
@@ -692,7 +692,7 @@ bool MinidumpContext::Read(uint32_t expected_size) {
if (minidump_->swap())
Swap(&context_flags);
- scoped_ptr<MDRawContextARM64> context_arm64(new MDRawContextARM64());
+ scoped_ptr<MDRawContextARM64_Old> context_arm64(new MDRawContextARM64_Old());
uint32_t cpu_type = context_flags & MD_CONTEXT_CPU_MASK;
if (cpu_type == 0) {
@@ -704,7 +704,7 @@ bool MinidumpContext::Read(uint32_t expected_size) {
}
}
- if (cpu_type != MD_CONTEXT_ARM64) {
+ if (cpu_type != MD_CONTEXT_ARM64_OLD) {
// TODO: Fall through to switch below.
// https://bugs.chromium.org/p/google-breakpad/issues/detail?id=550
BPLOG(ERROR) << "MinidumpContext not actually arm64 context";
@@ -720,7 +720,7 @@ bool MinidumpContext::Read(uint32_t expected_size) {
uint8_t* context_after_flags =
reinterpret_cast<uint8_t*>(context_arm64.get()) + flags_size;
if (!minidump_->ReadBytes(context_after_flags,
- sizeof(MDRawContextARM64) - flags_size)) {
+ sizeof(MDRawContextARM64_Old) - flags_size)) {
BPLOG(ERROR) << "MinidumpContext could not read arm64 context";
return false;
}
@@ -1199,8 +1199,8 @@ bool MinidumpContext::CheckAgainstSystemInfo(uint32_t context_cpu_type) {
return_value = true;
break;
- case MD_CONTEXT_ARM64:
- if (system_info_cpu_type == MD_CPU_ARCHITECTURE_ARM64)
+ case MD_CONTEXT_ARM64_OLD:
+ if (system_info_cpu_type == MD_CPU_ARCHITECTURE_ARM64_OLD)
return_value = true;
break;
@@ -3487,7 +3487,7 @@ string MinidumpSystemInfo::GetCPU() {
cpu = "arm";
break;
- case MD_CPU_ARCHITECTURE_ARM64:
+ case MD_CPU_ARCHITECTURE_ARM64_OLD:
cpu = "arm64";
break;
@@ -5086,8 +5086,8 @@ bool Minidump::GetContextCPUFlagsFromSystemInfo(uint32_t *context_cpu_flags) {
case MD_CPU_ARCHITECTURE_ARM:
*context_cpu_flags = MD_CONTEXT_ARM;
break;
- case MD_CPU_ARCHITECTURE_ARM64:
- *context_cpu_flags = MD_CONTEXT_ARM64;
+ case MD_CPU_ARCHITECTURE_ARM64_OLD:
+ *context_cpu_flags = MD_CONTEXT_ARM64_OLD;
break;
case MD_CPU_ARCHITECTURE_IA64:
*context_cpu_flags = MD_CONTEXT_IA64;
diff --git a/src/processor/minidump_processor.cc b/src/processor/minidump_processor.cc
index 2fe4fee7..431a2811 100644
--- a/src/processor/minidump_processor.cc
+++ b/src/processor/minidump_processor.cc
@@ -535,7 +535,7 @@ bool MinidumpProcessor::GetCPUInfo(Minidump *dump, SystemInfo *info) {
break;
}
- case MD_CPU_ARCHITECTURE_ARM64: {
+ case MD_CPU_ARCHITECTURE_ARM64_OLD: {
info->cpu = "arm64";
break;
}
@@ -735,7 +735,7 @@ string MinidumpProcessor::GetCrashReason(Minidump *dump, uint64_t *address) {
if (raw_system_info->processor_architecture ==
MD_CPU_ARCHITECTURE_ARM ||
raw_system_info->processor_architecture ==
- MD_CPU_ARCHITECTURE_ARM64) {
+ MD_CPU_ARCHITECTURE_ARM64_OLD) {
switch (exception_flags) {
case MD_EXCEPTION_CODE_MAC_ARM_DA_ALIGN:
reason.append("EXC_ARM_DA_ALIGN");
@@ -789,7 +789,7 @@ string MinidumpProcessor::GetCrashReason(Minidump *dump, uint64_t *address) {
reason = "EXC_BAD_INSTRUCTION / ";
switch (raw_system_info->processor_architecture) {
case MD_CPU_ARCHITECTURE_ARM:
- case MD_CPU_ARCHITECTURE_ARM64: {
+ case MD_CPU_ARCHITECTURE_ARM64_OLD: {
switch (exception_flags) {
case MD_EXCEPTION_CODE_MAC_ARM_UNDEFINED:
reason.append("EXC_ARM_UNDEFINED");
@@ -972,7 +972,7 @@ string MinidumpProcessor::GetCrashReason(Minidump *dump, uint64_t *address) {
reason = "EXC_BREAKPOINT / ";
switch (raw_system_info->processor_architecture) {
case MD_CPU_ARCHITECTURE_ARM:
- case MD_CPU_ARCHITECTURE_ARM64: {
+ case MD_CPU_ARCHITECTURE_ARM64_OLD: {
switch (exception_flags) {
case MD_EXCEPTION_CODE_MAC_ARM_DA_ALIGN:
reason.append("EXC_ARM_DA_ALIGN");
diff --git a/src/processor/stackwalker.cc b/src/processor/stackwalker.cc
index 4988ef1e..c7634ff0 100644
--- a/src/processor/stackwalker.cc
+++ b/src/processor/stackwalker.cc
@@ -259,7 +259,7 @@ Stackwalker* Stackwalker::StackwalkerForCPU(
break;
}
- case MD_CONTEXT_ARM64:
+ case MD_CONTEXT_ARM64_OLD:
cpu_stackwalker = new StackwalkerARM64(system_info,
context->GetContextARM64(),
memory, modules,
diff --git a/src/processor/stackwalker_arm64.cc b/src/processor/stackwalker_arm64.cc
index f9660112..042fd089 100644
--- a/src/processor/stackwalker_arm64.cc
+++ b/src/processor/stackwalker_arm64.cc
@@ -48,7 +48,7 @@ namespace google_breakpad {
StackwalkerARM64::StackwalkerARM64(const SystemInfo* system_info,
- const MDRawContextARM64* context,
+ const MDRawContextARM64_Old* context,
MemoryRegion* memory,
const CodeModules* modules,
StackFrameSymbolizer* resolver_helper)
diff --git a/src/processor/stackwalker_arm64.h b/src/processor/stackwalker_arm64.h
index 121e8246..1b01f21e 100644
--- a/src/processor/stackwalker_arm64.h
+++ b/src/processor/stackwalker_arm64.h
@@ -55,7 +55,7 @@ class StackwalkerARM64 : public Stackwalker {
// included in the stack. The other arguments are passed directly through
// to the base Stackwalker constructor.
StackwalkerARM64(const SystemInfo* system_info,
- const MDRawContextARM64* context,
+ const MDRawContextARM64_Old* context,
MemoryRegion* memory,
const CodeModules* modules,
StackFrameSymbolizer* frame_symbolizer);
@@ -89,7 +89,7 @@ class StackwalkerARM64 : public Stackwalker {
// Stores the CPU context corresponding to the youngest stack frame, to
// be returned by GetContextFrame.
- const MDRawContextARM64* context_;
+ const MDRawContextARM64_Old* context_;
// Validity mask for youngest stack frame. This is always
// CONTEXT_VALID_ALL in real use; it is only changeable for the sake of
diff --git a/src/processor/stackwalker_arm64_unittest.cc b/src/processor/stackwalker_arm64_unittest.cc
index f9d18cea..fff70744 100644
--- a/src/processor/stackwalker_arm64_unittest.cc
+++ b/src/processor/stackwalker_arm64_unittest.cc
@@ -122,14 +122,14 @@ class StackwalkerARM64Fixture {
}
// Fill RAW_CONTEXT with pseudo-random data, for round-trip checking.
- void BrandContext(MDRawContextARM64 *raw_context) {
+ void BrandContext(MDRawContextARM64_Old *raw_context) {
uint8_t x = 173;
for (size_t i = 0; i < sizeof(*raw_context); i++)
reinterpret_cast<uint8_t *>(raw_context)[i] = (x += 17);
}
SystemInfo system_info;
- MDRawContextARM64 raw_context;
+ MDRawContextARM64_Old raw_context;
Section stack_section;
MockMemoryRegion stack_region;
MockCodeModule module1;
@@ -688,7 +688,7 @@ struct CFIFixture: public StackwalkerARM64Fixture {
}
// The values we expect to find for the caller's registers.
- MDRawContextARM64 expected;
+ MDRawContextARM64_Old expected;
// The validity mask for expected.
uint64_t expected_validity;
diff --git a/src/tools/linux/md2core/minidump-2-core.cc b/src/tools/linux/md2core/minidump-2-core.cc
index 8cc07a6e..cf9648f6 100644
--- a/src/tools/linux/md2core/minidump-2-core.cc
+++ b/src/tools/linux/md2core/minidump-2-core.cc
@@ -480,7 +480,7 @@ ParseThreadRegisters(CrashedProcess::Thread* thread,
static void
ParseThreadRegisters(CrashedProcess::Thread* thread,
const MinidumpMemoryRange& range) {
- const MDRawContextARM64* rawregs = range.GetData<MDRawContextARM64>(0);
+ const MDRawContextARM64_Old* rawregs = range.GetData<MDRawContextARM64_Old>(0);
for (int i = 0; i < 31; ++i)
thread->regs.regs[i] = rawregs->iregs[i];
@@ -590,7 +590,7 @@ ParseSystemInfo(const Options& options, CrashedProcess* crashinfo,
exit(1);
}
#elif defined(__aarch64__)
- if (sysinfo->processor_architecture != MD_CPU_ARCHITECTURE_ARM64) {
+ if (sysinfo->processor_architecture != MD_CPU_ARCHITECTURE_ARM64_OLD) {
fprintf(stderr,
"This version of minidump-2-core only supports ARM (64bit).\n");
exit(1);