Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(24)

Unified Diff: gcc/gcc/config/i386/linux-unwind.h

Issue 3050029: [gcc] GCC 4.5.0=>4.5.1 (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/nacl-toolchain.git
Patch Set: Created 10 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gcc/gcc/config/i386/libgcc-glibc.ver ('k') | gcc/gcc/config/i386/mingw32.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gcc/gcc/config/i386/linux-unwind.h
diff --git a/gcc/gcc/config/i386/linux-unwind.h b/gcc/gcc/config/i386/linux-unwind.h
index 89f238a6ea17840ce184585315715008e4bc050b..36ee3709261777e867d21322d1d2889e719b4c41 100644
--- a/gcc/gcc/config/i386/linux-unwind.h
+++ b/gcc/gcc/config/i386/linux-unwind.h
@@ -172,6 +172,25 @@ x86_fallback_frame_state (struct _Unwind_Context *context,
fs->signal_frame = 1;
return _URC_NO_REASON;
}
+
+#define MD_FROB_UPDATE_CONTEXT x86_frob_update_context
+
+/* Fix up for kernels that have vDSO, but don't have S flag in it. */
+
+static void
+x86_frob_update_context (struct _Unwind_Context *context,
+ _Unwind_FrameState *fs ATTRIBUTE_UNUSED)
+{
+ unsigned char *pc = context->ra;
+
+ /* movl $__NR_rt_sigreturn,%eax ; {int $0x80 | syscall} */
+ if (*(unsigned char *)(pc+0) == 0xb8
+ && *(unsigned int *)(pc+1) == 173
+ && (*(unsigned short *)(pc+5) == 0x80cd
+ || *(unsigned short *)(pc+5) == 0x050f))
+ _Unwind_SetSignalFrame (context, 1);
+}
+
#endif /* not glibc 2.0 */
#endif /* ifdef __x86_64__ */
#endif /* ifdef inhibit_libc */
« no previous file with comments | « gcc/gcc/config/i386/libgcc-glibc.ver ('k') | gcc/gcc/config/i386/mingw32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698