]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Complain about NVidia's libGL.so also when an 0x8C opcode is encountered.
authorJulian Seward <jseward@acm.org>
Wed, 8 May 2002 01:58:18 +0000 (01:58 +0000)
committerJulian Seward <jseward@acm.org>
Wed, 8 May 2002 01:58:18 +0000 (01:58 +0000)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@235

coregrind/vg_include.h
coregrind/vg_main.c
coregrind/vg_to_ucode.c
vg_include.h
vg_main.c
vg_syscall_mem.c
vg_to_ucode.c

index b7302549564c89881ff2510c62d86adcc52589ad..4794cd0dc5594aed98048c5f1116d7849f0ed620 100644 (file)
@@ -1289,6 +1289,7 @@ extern void VG_(copy_m_state_static_to_baseBlock) ( void );
 /* Called when some unhandleable client behaviour is detected.
    Prints a msg and aborts. */
 extern void VG_(unimplemented) ( Char* msg );
+extern void VG_(nvidia_moan) ( void );
 
 /* The stack on which Valgrind runs.  We can't use the same stack as the
    simulatee -- that's an important design decision.  */
index 8397698bca7d976bbc4c11982bacf90e0204542e..06b649814f5d5ed709f2f7985efe76e6981f2698 100644 (file)
@@ -1204,7 +1204,7 @@ extern void VG_(start_GDB_whilst_on_client_stack) ( void )
 
 /* Print some helpful-ish text about unimplemented things, and give
    up. */
-extern void VG_(unimplemented) ( Char* msg )
+void VG_(unimplemented) ( Char* msg )
 {
    VG_(message)(Vg_UserMsg, "");
    VG_(message)(Vg_UserMsg, 
@@ -1231,6 +1231,15 @@ extern void VG_(unimplemented) ( Char* msg )
 }
 
 
+void VG_(nvidia_moan) ( void) 
+{
+   VG_(message)(Vg_UserMsg,
+      "The following failure _might_ be caused by linking to NVidia's\n   "
+      "libGL.so, so avoiding it, if you can, _might_ help you.  For example,\n   "
+      "re-build any Qt libraries you are using without OpenGL support.");
+}
+
+
 /*--------------------------------------------------------------------*/
 /*--- end                                                vg_main.c ---*/
 /*--------------------------------------------------------------------*/
index 9f29229c676068135b4755752fc704e96a2000ca..de1c066ad286a56c51ef33ab1880e4a85025cad7 100644 (file)
@@ -4491,6 +4491,8 @@ static Addr disInstr ( UCodeBlock* cb, Addr eip, Bool* isEnd )
    default:
       VG_(printf)("disInstr: unhandled opcode 0x%x then 0x%x\n", 
                   (UInt)opc, (UInt)getUChar(eip));
+      if (opc == 0x8C)
+         VG_(nvidia_moan)();
       VG_(panic)("unhandled x86 opcode");
    }
 
index b7302549564c89881ff2510c62d86adcc52589ad..4794cd0dc5594aed98048c5f1116d7849f0ed620 100644 (file)
@@ -1289,6 +1289,7 @@ extern void VG_(copy_m_state_static_to_baseBlock) ( void );
 /* Called when some unhandleable client behaviour is detected.
    Prints a msg and aborts. */
 extern void VG_(unimplemented) ( Char* msg );
+extern void VG_(nvidia_moan) ( void );
 
 /* The stack on which Valgrind runs.  We can't use the same stack as the
    simulatee -- that's an important design decision.  */
index 8397698bca7d976bbc4c11982bacf90e0204542e..06b649814f5d5ed709f2f7985efe76e6981f2698 100644 (file)
--- a/vg_main.c
+++ b/vg_main.c
@@ -1204,7 +1204,7 @@ extern void VG_(start_GDB_whilst_on_client_stack) ( void )
 
 /* Print some helpful-ish text about unimplemented things, and give
    up. */
-extern void VG_(unimplemented) ( Char* msg )
+void VG_(unimplemented) ( Char* msg )
 {
    VG_(message)(Vg_UserMsg, "");
    VG_(message)(Vg_UserMsg, 
@@ -1231,6 +1231,15 @@ extern void VG_(unimplemented) ( Char* msg )
 }
 
 
+void VG_(nvidia_moan) ( void) 
+{
+   VG_(message)(Vg_UserMsg,
+      "The following failure _might_ be caused by linking to NVidia's\n   "
+      "libGL.so, so avoiding it, if you can, _might_ help you.  For example,\n   "
+      "re-build any Qt libraries you are using without OpenGL support.");
+}
+
+
 /*--------------------------------------------------------------------*/
 /*--- end                                                vg_main.c ---*/
 /*--------------------------------------------------------------------*/
index ea83fbf9191117c451826fb0c9d7362b7757e73f..d5d541652209cbe5d4d4967c3fb9b93d93c08a4b 100644 (file)
@@ -410,11 +410,9 @@ void VG_(perform_assumed_nonblocking_syscall) ( ThreadId tid )
 
 #     if defined(__NR_modify_ldt)
       case __NR_modify_ldt:
+         VG_(nvidia_moan)();
          VG_(unimplemented)
-            ("modify_ldt(): I (JRS) haven't investigated this yet; sorry.\n   "
-             "This might be caused by linking to NVidia's libGL.so, so\n   "
-             "avoiding it, if you can, _might_ help you.  For example,\n   "
-             "re-build any Qt libraries you are using without OpenGL support.");
+            ("modify_ldt(): I (JRS) haven't investigated this yet; sorry.");
          break;
 #     endif
 
index 9f29229c676068135b4755752fc704e96a2000ca..de1c066ad286a56c51ef33ab1880e4a85025cad7 100644 (file)
@@ -4491,6 +4491,8 @@ static Addr disInstr ( UCodeBlock* cb, Addr eip, Bool* isEnd )
    default:
       VG_(printf)("disInstr: unhandled opcode 0x%x then 0x%x\n", 
                   (UInt)opc, (UInt)getUChar(eip));
+      if (opc == 0x8C)
+         VG_(nvidia_moan)();
       VG_(panic)("unhandled x86 opcode");
    }