Apply and restore batch size in more cases.
Restore batch size and hexl mode in case of failed search or occur.
Change vlf-tune-get-optimal to optimize on total time of primitive
operations, also fix hexl timing functions not to book in cases where
hexl is already (not) active.