I've hunted/culled hundreds of feral pigs over the last 30 years using pistol, shotgun & rifle. I always prefer a centerfire rifle, since you often encounter pigs in groups. Once you've dispatched the first pig, the remainder of the group gets out of range pretty quick if all youre using is a shotgun or pistol.
Id take the AK, although I still prefer a scoped centerfire rifle for my hunting, even in the thick stuff.