Taylor Fritz won a three-hour epic against Jiri Lehecka, reaching the quarter-finals of the Canadian Open.