[Linux-Biella] #if 0

Paolo Ciarrocchi paolo.ciarrocchi a gmail.com
Lun 28 Gen 2008 00:01:08 CET


Il codice contentuto all'interno di
#if 0
#endif
Non dovrebbe essere ignorato dal compilatore?

md5sum di relativo .o di file originale e file con la seguente patch
differiscono...

-#if 0
-void Un_impl(void)
-{
-  u_char byte1, FPU_modrm;
-  unsigned long address = FPU_ORIG_EIP;
-
-  RE_ENTRANT_CHECK_OFF;
-  /* No need to check access_ok(), we have previously fetched these bytes. */
-  printk("Unimplemented FPU Opcode at eip=%p : ", (void __user *) address);
-  if ( FPU_CS == __USER_CS )
-    {
-      while ( 1 )
-       {
-         FPU_get_user(byte1, (u_char __user *) address);
-         if ( (byte1 & 0xf8) == 0xd8 ) break;
-         printk("[%02x]", byte1);
-         address++;
-       }
-      printk("%02x ", byte1);
-      FPU_get_user(FPU_modrm, 1 + (u_char __user *) address);
-
-      if (FPU_modrm >= 0300)
-       printk("%02x (%02x+%d)\n", FPU_modrm, FPU_modrm & 0xf8, FPU_modrm & 7);
-      else
-       printk("/%d\n", (FPU_modrm >> 3) & 7);
-    }
-  else
-    {
-      printk("cs selector = %04x\n", FPU_CS);
-    }
-
-  RE_ENTRANT_CHECK_ON;
-
-  EXCEPTION(EX_Invalid);
-
-}
-#endif  /*  0  */


-- 
Paolo
http://paolo.ciarrocchi.googlepages.com/


Maggiori informazioni sulla lista Linux