Finite element analysis of stability of two-dimensional viscoelastic flows to three-dimensional perturbations