>>Why global variables are not replaced by temporaries? 
global variables be allocated in linker, it's address not changed, and it's live time even before main() entry until the program exit.  
>>Do they attend live range analysis? 
so, you can see global variables will not involve live range analysis.
>>Can they be in regiesters temporarily without memory writeback before their final values are determined? 
temporarily register may be represent a expression's value,and is rvalue but not lvalue.


2013/12/30 Ben Shi <powerstudio1st@163.com>
Hello,

I am reading the manual "SDCC 3.3.2 $Date:: 2013-12-27 #$ $Revision: 8929 $", and have several questions.

1. Page 113

>> Note that local variables
>> and parameters are replaced by compiler generated temporaries. Live ranges are computed only for temporaries
>> (i.e. live ranges are not computed for global variables). Registers are allocated for temporaries only.

Why global variables are not replaced by temporaries? Do they attend live range analysis? Can they be in regiesters temporarily without memory writeback before their final values are determined?

2. Page 113
>> The compiler does not change the multiplication in
>> line 17 however since the processor does support an 8 * 8 bit multiplication

But it still can be optimized to addition as strength reduction. I can not understand why 8 * 8 bit multiplication affect ?

Ben



------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk
_______________________________________________
sdcc-devel mailing list
sdcc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-devel




--
زµ¾«سعاع,»ؤسعوز..