Analyzing Program Performance With Sun WorkShop

save

save has the following syntax:


save description

Saves the current state of the tool on a stack. The user-specified description is attached to the state. Saved states form a LIFO (Last-In-First-Out) stack, so that the last state saved is the first one restored.

This subcommand is commonly used to save the state of the tool before running the analyze subcommand, which can be run only once on a given state. For example, you can do the following:


%: lock_lint load *.ll
%: lock_lint save Before Analysis
%: lock_lint analyze
	<output from analyze>
%: lock_lint vars -h | grep \*
	<apparent members of struct foo are not consistently protected>
%: lock_lint refresh Before Analysis
%: lock_lint assert lock1 protects `lock_lint members foo`
%: lock_lint analyze
	<output now contains info about where the assertion is violated>