initialized globals

Stone, Joshua I joshua.i.stone@intel.com
Wed Sep 6 20:23:00 GMT 2006


On Wednesday, September 06, 2006 11:46 AM, Frank Ch. Eigler wrote:
> Hi -
> 
>> The next steps I see for this:
>> * Allow global constants -- no need for read locks, and enables
>> optimizations like value propagation.
> 
> Technically, these are independent things, but yes: bug #2341.

Yes, that's close, but read-mostly is not as strong as a constant.  With
a constant, we could propagate the literal value at code-generation
time, optimizing the variable out.

>> * Allow importing macro values as global constants -- avoid errors
>> in "transcribing".
> 
> That unfortunately depends on the kernel being compiled with
> not just -g but -g2.

The -g2 is only needed if you want the parser to understand the macro,
right?  It seems like we could just assume that the macro exists (maybe
requiring guru mode), and then pass-4 will fail if the macro was
specified incorrectly.

I just looked through the archives and realized that we've discussed
this before, so I won't hash on it too much.  I still think it has merit
though, and may be possible without -g2 information.


Josh



More information about the Systemtap mailing list