diff options
author | thestig@chromium.org <thestig@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2013-12-14 19:17:42 +0000 |
---|---|---|
committer | thestig@chromium.org <thestig@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2013-12-14 19:17:42 +0000 |
commit | 3c613e7bdb56b6c7527acedc94e21db13adb06e4 (patch) | |
tree | 702215fd600e18276f20eaf8ae3bd64b9cebd9e3 /src/client/linux/minidump_writer | |
parent | Misc Android-related fixes. (diff) | |
download | breakpad-3c613e7bdb56b6c7527acedc94e21db13adb06e4.tar.xz |
Fix gcc vs clang cpuid.h discrepency.
For r1254, gcc defines bit_FXSAVE while clang defines bit_FXSR.
R=mark@chromium.org
Review URL: https://breakpad.appspot.com/924002
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1260 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/client/linux/minidump_writer')
-rw-r--r-- | src/client/linux/minidump_writer/linux_ptrace_dumper.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/client/linux/minidump_writer/linux_ptrace_dumper.cc b/src/client/linux/minidump_writer/linux_ptrace_dumper.cc index 5ea3bd54..8b96037e 100644 --- a/src/client/linux/minidump_writer/linux_ptrace_dumper.cc +++ b/src/client/linux/minidump_writer/linux_ptrace_dumper.cc @@ -195,6 +195,9 @@ bool LinuxPtraceDumper::GetThreadInfoByIndex(size_t index, ThreadInfo* info) { } #if defined(__i386) +#if !defined(bit_FXSAVE) // e.g. Clang +#define bit_FXSAVE bit_FXSR +#endif // Detect if the CPU supports the FXSAVE/FXRSTOR instructions int eax, ebx, ecx, edx; __cpuid(1, eax, ebx, ecx, edx); @@ -205,7 +208,7 @@ bool LinuxPtraceDumper::GetThreadInfoByIndex(size_t index, ThreadInfo* info) { } else { memset(&info->fpxregs, 0, sizeof(info->fpxregs)); } -#endif +#endif // defined(__i386) #if defined(__i386) || defined(__x86_64) for (unsigned i = 0; i < ThreadInfo::kNumDebugRegisters; ++i) { |