Re: regarding optimization options in phase ordering

2009-08-10 Thread Ian Lance Taylor
pms writes: > My question is as follwos > > We've a problem here. we were trying to use cc1 with & without -O option to > verify the optimizations happening in our sample code. > the sample code is given below > file name : 1.c > #include > int main() > { int a=5; > int b; > b=a; > printf(

Re: regarding optimization options in phase ordering

2009-08-10 Thread pms
ebp > andl$-16, %esp > subl$16, %esp > movl$5, 4(%esp) > movl$.LC0, (%esp) > callprintf The first four statements set up the stack. The last three do the printf statement. What is your real question? Ian -- View this message

Re: regarding optimization options in phase ordering

2009-08-10 Thread Ian Lance Taylor
pms writes: > thanks, But b=a is a assignment statement. It is doing some memory operations > isn't it. Assuming b=a is a dead statement, how r the following i386 > assembly statements generated > pushl %ebp > movl%esp, %ebp > andl$-16, %esp > subl$16, %esp

Re: regarding optimization options in phase ordering

2009-08-07 Thread pms
ain (main) >> >> main () >> { >>  int b; >>  int a; >> >> : >>  a_2 = b_1(D); >>  return; >> >> } >> but in 1.c.027t.ccp1, the output doesnot contain the actual assignment >> b=a. >> ;; Function main (main) &g

Re: regarding optimization options in phase ordering

2009-08-07 Thread Richard Guenther
 a_2 = b_1(D); >  return; > > } > but in 1.c.027t.ccp1, the output doesnot contain the actual assignment b=a. > ;; Function main (main) > > main () > { >  int b; >  int a; > > : >  return; > > } > > We want to know, without b=a, how is it generati

regarding optimization options in phase ordering

2009-08-07 Thread pms
contain the actual assignment b=a. ;; Function main (main) main () { int b; int a; : return; } We want to know, without b=a, how is it generating the final code for b=a Kindly help -- View this message in context: http://www.nabble.com/regarding-optimization-options-in-phase-ordering-