[LLVMbugs] [Bug 588] NEW: Error in optimization: ( A || A ) << B

bugzilla-daemon at cs.uiuc.edu bugzilla-daemon at cs.uiuc.edu
Sat Jun 25 14:52:35 PDT 2005


http://llvm.cs.uiuc.edu/bugs/show_bug.cgi?id=588

           Summary: Error in optimization: ( A || A ) << B
           Product: tools
           Version: 1.5
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: llvm-gcc
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: bryan.turner at pobox.com


Back from vacation.  Working through the group of optimizer errors.  This is the
reduced version.

Diff the output from this program when compiled in Optimized mode vs Debug mode.
 The assumption is that there should be no differences if the compiler optimized
correctly.

/*
// --- RANDOMLY GENERATED PROGRAM ---
// Program Generator by Bryan Turner (bryan.turner at pobox.com)
*/

#include <stdio.h>
unsigned long context = 0;
unsigned long DEPTH = 0;
void DumbHash( unsigned long value, unsigned int len )
{
  context += value;
  context ^= 0xA50F5AF0;
  printf( "%d\n", context );
}
/* --- GLOBAL VARIABLES --- */
unsigned short g_70300438 = 0xE7CA;


/* --- MAIN --- */
/* ------------------------------------------ */
int main(  )
{
  unsigned char l_94663863 = 0xF6;
  long l_03324849 = 0x9A7215CB;
  long l_99194556 = 0xE4255F06;
  if ( ( ( g_70300438 || g_70300438 )  << l_94663863 )  )
  {
        l_03324849 = l_99194556;
  }
  DumbHash( l_03324849, 4 );
}



------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.




More information about the llvm-bugs mailing list