Sun WorkShop Compiler C 5.0 User's Guide

-xrestrict=f

(SPARC) Treats pointer-valued function parameters as restricted pointers. f is a comma-separated list that consists of one or more function parameters, %all, or %none.

If a function list is specified with this option, pointer parameters in the specified functions are treated as restricted; if -xrestrict=%all is specified, all pointer parameters in the entire C file are treated as restricted. Refer to "_Restrict Keyword", for more information.

This command-line option can be used on its own, but it is best used with optimization. For example, the command:

%cc -xO3 -xrestrict=%all prog.c

treats all pointer parameters in the file prog.c as restricted pointers. The command:

%cc -xO3 -xrestrict=agc prog.c

treats all pointer parameters in the function agc in the file prog.c as restricted pointers.

The default is %none; specifying -xrestrict is equivalent to specifying -xrestrict=%all.