optimize smatrix_lock_{incr,decr}ref