The study of polycrystalline materials requires theoretical and computational techniques enabling multiscale investigations. The amplitude expansion of the phase field crystal model (APFC) allows for describing crystal lattice properties on diffusive timescales by focusing on continuous fields varying on length scales larger than the atomic spacing. Thus, it allows for the simulation of large systems still retaining details of the crystal lattice. Fostered by the applications of this approach, we present here an efficient numerical framework to solve its equations. In particular, we consider a real space approach exploiting the finite element method. An optimized preconditioner is developed in order to improve the convergence of the linear solver. Moreover, a mesh adaptivity criterion based on the local rotation of the polycrystal is used. This results in an unprecedented capability of simulating large, three-dimensional systems including the dynamical description of the microstructures in polycrystalline materials together with their dislocation networks.