Optimizing code written in C for POWER2 architechture.

ITEM: RTA000064441



Using the xlC command with the flags: -qarch and -qtune, you specify            
the platform on which the executable will run and optimized.                    
Nevertheless I would like to optimize the code itself to have better            
performance. Can you explain me How to optimize the following pieces            
of code for the POWER2 architecture:                                            
(assuming I use the flags -qarch=PWRX -qtune=PWRX)                              
                                                                                
1. in a loop on i:                                                              
     x.i.+=temp*vm.i.;                                                          
                                                                                
2. for(i=v.num..0.;i<=v.num..1.;i++)                                            
       ar.i..x.i.>b.++;                                                         
                                                                                
3. for(i=0;i<=LEN;i++)                                                          
       for(j=LEN;j