Unsteady PDE-constrained optimization with spectral elements using PETSc and TAO