Tool profile value to variable

Hi all, is there a way to get some value from /tool profile cpu=all to variable via script ?
Thanks in advance!