  We establish P=W and PI=WI conjectures for character varieties with
structural group $\mathrm{GL}_n$ and $\mathrm{SL}_n$ which admit a symplectic
resolution, i.e. for genus 1 and arbitrary rank, and genus 2 and rank 2. We
formulate the P=W conjecture for resolution, and prove it for symplectic
resolutions. We exploit the topology of birational and quasi-\'{e}tale
modifications of Dolbeault moduli spaces of Higgs bundles. To this end, we
prove auxiliary results of independent interest, like the construction of a
relative compactification of the Hodge moduli space for reductive algebraic
groups, and the projectivity of the compactification of the de Rham moduli
space. In particular, we study in detail a Dolbeault moduli space which is
specialization of the singular irreducible holomorphic symplectic variety of
type O'Grady 6.
