[deleted]
Most of the studies that have looked at this question confirm your intuition, which is that terrorism is more common in democracies than nondemocracies. Some interesting results come in when we break down regime types further. Wilson and Piazza 2013 distinguish between different kinds of authoritarian regimes and find that lower terrorism incidence is particular to single-party regimes (like the Soviet example you mentioned) and not shared by more ad hoc dictatorships. In their model, democratic regimes are restrained in the amount of force they can use to solve problems, while military or personal regimes are usually weak states that can barely use anything *but* force, and that in a fairly sporadic and disorganized manner. Single-party regimes have democracies' institutional coherence and state capacity without its bad conscience about knocking heads, so they're able to employ both carrots to reduce tensions and sticks to dissuade violent responses. Aksoy et al. 2012 find that "terrorist groups are most likely to emerge in dictatorships with opposition political parties but no elected legislature." Li 2005 divides regimes up differently and finds an advantage in proportional representative systems over authoritarian or majoritarian systems, possibly because those are better at compromise.
So ideally (at least looking at dissuading terrorism alone) you probably want a state that is responsive enough to respond to the grievances that generate terrorism, ruthless enough to ignore civil liberties, and strong and institutionalized enough to effectively do either.