340 Chugging instead of Reving

Also have had a bad distributor that would idle fine but run like crap above 2500RPM