US, Pakistan trade barbs over failures in Afghanistan