Weak Dirichlet processes with a stochastic control perspective