The presented approach aims at solving an equality constrained, finite-dimensional optimization problem, where the constraints arise from the discretization of some partial differential equation (PDE) on a given space grid. For this purpose, a stationary point of the Lagrangian is computed using Newton's method, which requires the repeated solution of KKT systems. The proposed algorithm focuses on two topics: Firstly, Algorithmic Differentiation (AD) will be used to evaluate the necessary computations of gradients, Jacobian-vector products, and Hessian-vector products, so that only the objective f (y, u) and the PDE constraint e(y, u) = 0 have to be specified by the user. Secondly, we solve the KKT system iteratively using the QMR algorithm, with preconditioning provided by a multigrid approach. We wish to explore whether the Jacobian-vector products provided by AD are sufficient to construct suitable multigrid preconditioners. Our approach is then embedded into a globalized optimization routine. Numerical results for optimization problems involving a nonlinear reaction-diffusion model will be given.