modify elapsed_ms return type to long long