doing less work in local trace function

removed three function calls and a few attribute accesses on every round of the local trace function
Merge pull request #10 from doublereedkurt/master

sorry for the drive-by pull request, but localtrace could use some optimization