krytarowski created this revision. krytarowski added a reviewer: joerg. krytarowski added a subscriber: lldb-commits. krytarowski set the repository for this revision to rL LLVM. Herald added a subscriber: emaste.
Linux and FreeBSD occasionally send SI_KERNEL codes, nonexistent on other platforms. Problem caught on NetBSD. Repository: rL LLVM http://reviews.llvm.org/D12659 Files: source/Plugins/Process/POSIX/CrashReason.cpp Index: source/Plugins/Process/POSIX/CrashReason.cpp =================================================================== --- source/Plugins/Process/POSIX/CrashReason.cpp +++ source/Plugins/Process/POSIX/CrashReason.cpp @@ -28,11 +28,13 @@ switch (info.si_code) { +#ifdef SI_KERNEL case SI_KERNEL: // Linux will occasionally send spurious SI_KERNEL codes. // (this is poorly documented in sigaction) // One way to get this is via unaligned SIMD loads. return CrashReason::eInvalidAddress; // for lack of anything better +#endif case SEGV_MAPERR: return CrashReason::eInvalidAddress; case SEGV_ACCERR:
Index: source/Plugins/Process/POSIX/CrashReason.cpp =================================================================== --- source/Plugins/Process/POSIX/CrashReason.cpp +++ source/Plugins/Process/POSIX/CrashReason.cpp @@ -28,11 +28,13 @@ switch (info.si_code) { +#ifdef SI_KERNEL case SI_KERNEL: // Linux will occasionally send spurious SI_KERNEL codes. // (this is poorly documented in sigaction) // One way to get this is via unaligned SIMD loads. return CrashReason::eInvalidAddress; // for lack of anything better +#endif case SEGV_MAPERR: return CrashReason::eInvalidAddress; case SEGV_ACCERR:
_______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits