Sato-Tate groups of elliptic curves and abelian varieties