This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Help restricting args of an intrinsic function



On Jan 30, 2004, at 4:54 PM, Diego Novillo wrote:


On Fri, 2004-01-30 at 19:46, Syd Polk wrote:

How can I safely:
	- Determine if a value is really a compile-time constant?
	- Get the value of that constant?

If you could wait a little while until tree-ssa is merged in mainline,
this would be relatively simple to implement inside the tree optimizers.


So, if the compiler cannot assert that the arguments are compile-time
constants, you want to emit an error?

Not only that, but compile-time constants in a certain range.


__builtin_prefetch does something similar, but only supports actual integers in the source code; it has the same characteristics as my original implementation.



Diego.


Syd Polk
Apple Computer
Technology EPM, Mac OS X Development Tools
+1 408 974-0577


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]