aboutsummaryrefslogtreecommitdiff
path: root/src/client/solaris/handler/minidump_generator.h
diff options
context:
space:
mode:
authormmentovai <mmentovai@4c0a9323-5329-0410-9bdc-e9ce6186880e>2007-09-26 18:28:05 +0000
committermmentovai <mmentovai@4c0a9323-5329-0410-9bdc-e9ce6186880e>2007-09-26 18:28:05 +0000
commitea2bba970675e01f9964f82d3f44960c1aad05dc (patch)
treed3d6744bf2ef136f9a89748c96ab4e5c465eb7ff /src/client/solaris/handler/minidump_generator.h
parentFix crash reason switching to allow proper behavior for Linux. Spotted by (diff)
downloadbreakpad-ea2bba970675e01f9964f82d3f44960c1aad05dc.tar.xz
Add SPARC/Solaris support to client handler and processor (#201, 200).
Patch by Michael shang <satisfy123>. r=me, r=Alfred Peng. http://groups.google.com/group/google-breakpad-discuss/browse_thread/thread/2fba07577f1fa35e git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@215 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/client/solaris/handler/minidump_generator.h')
-rw-r--r--src/client/solaris/handler/minidump_generator.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/client/solaris/handler/minidump_generator.h b/src/client/solaris/handler/minidump_generator.h
index 36b92716..82309936 100644
--- a/src/client/solaris/handler/minidump_generator.h
+++ b/src/client/solaris/handler/minidump_generator.h
@@ -32,6 +32,14 @@
#ifndef CLIENT_SOLARIS_HANDLER_MINIDUMP_GENERATOR_H__
#define CLIENT_SOLARIS_HANDLER_MINIDUMP_GENERATOR_H__
+#if defined(sparc) || defined(__sparc__)
+#define TARGET_CPU_SPARC 1
+#elif defined(i386) || defined(__i386__)
+#define TARGET_CPU_X86 1
+#else
+#error "cannot determine cpu type"
+#endif
+
#include "client/minidump_file_writer.h"
#include "client/solaris/handler/solaris_lwp.h"
#include "google_breakpad/common/breakpad_types.h"
@@ -69,8 +77,13 @@ class MinidumpGenerator {
MDMemoryDescriptor *loc);
// Write CPU context based on provided registers.
+#if TARGET_CPU_SPARC
+ bool WriteContext(MDRawContextSPARC *context, prgregset_t regs,
+ prfpregset_t *fp_regs);
+#elif TARGET_CPU_X86
bool WriteContext(MDRawContextX86 *context, prgregset_t regs,
prfpregset_t *fp_regs);
+#endif /* TARGET_CPU_XXX */
// Write information about a lwp.
// Only processes lwp running normally at the crash.