moved timing to r12-r13 to preserve across external calls