performance improve

Do these things

* use `auto&` instead of `auto` if possible
* correct some coding style
* initialize an object in constructor to remove unneeded assign operation
* remove unneeded temple object