optimize the performance

add the programe execute time
use re.compile