Make MAXTL dynamic, bounds check tl when indexing