count smart ptr