Improve build error output.
Set invalid time for invalid result.
Optimize interpolation computation.
Inline interpolation and index computation.
Remove unneeded method.
Remove unneccesarry variable.
Remove unneeded variables and constants.