Yes, you can specify the path where you want to create the xml file.
e.g
smpolicysrv -publish <optional file_name>
Specify a Location for Published Information
Published information is written in XML format to a specified file. The specified file name is saved in the following registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Netegrity\SiteMinder\CurrentVersion\ Publish
This key is located in the system registry on Windows systems, and in the install_dir/registry/sm.registry file on UNIX. The default value of the registry setting is:
policy_server_install_dir>\log\smpublish.xml
If you execute smpolicysrv -publish from a command line, and you do not supply a path and file name, the value of the registry setting determines the location of the published XML file.
Note: On Windows systems, do not run the smpolicysrv command from a remote desktop or Terminal Services window. The smpolicysrv command depends on inter-process communications that do not work if you run the smpolicysrv process from a remote desktop or Terminal Services window.
Publishing Diagnostic Information - CA Single Sign-On - 12.52 SP1 - CA Technologies Documentation