MostlyHarmless42
Adventurer
I think light weapons would be ok but I would be against doing it with others. GWM+sneak attack would break things pretty quickly. You could sneak attack with reach and +10 damage and then move away without needing to disengage. Even not counting the +10, with a greatsword you are also getting double the weapon damage of most finesse weapons. You are sneak attacking as rogue 2 levels higher ... but better yet you can get that extra d6 even when you don't have advantage or other sneak attack conditions.
You could even sneak attack with reach then dash as a bonus and be completely out of range for whoever you are fighting so the guy you are fighting can't retaliate. I know you can do that with swashbuckler already with a normal weapon, or an rogue with a whip, but is only 1d4 and precludes dual wield. Or you need to take swashbuckler to do with any other weapon and give up the bonuses and benefits you get with mastermind, assassin or thief. Doing it with a reach weapon getting massive damage would make swashbuckler more or less a useless kit.
I think to do it for all weapons without breaking things it would need to be a feat and I would still consider making it only work within 5 feet for non-finesse weapons.
Let's be clear though and not ignore two very important points here to consider:
1) The two handed weapons you suggest are NOT finesse weapons, which means the rogue now needs both strength AND dexterity to function or have an absolutely abysmal AC, and is also now spending at least one of his crucially need ASI to get GWM.
2) The rogue is not proficient by default with any of those weapons, or most twohanded weapons in general really.
I'd wager both of those are an important balancing factor that shouldn't be overlooked.
Now, the obvious thing to consider next is of course taking levels in another class, in which the player has one of two options: starting rogue and being capped at medium armor (which results in an AC similar to a rogue with 20 dex), but still requires dex of 14 AND strength, OR starting as a fighter or paladin and then not having dexterity save proficiency, which is...kind of a big deal for rogues what with evasion and all. And again any suggestion of taking more feats to shore up this is still competing with them needing both dex and strength alongside GWM.
The main concern would be a fighter (or possibly paladin with smite) going a few levels of rogue to boost their damage, but honestly I'm not convinced it would be that much of a damage increase over staying pure fighter or paladin, especially considering the more rogue they take, the more their extra attack(s) or spellcasting is delayed or other class features. Not sure it's worth it.
Now, to suggest something, I'd probably make it an archetype of rogue to let them do sneak attack with any weapons and give said archetype martial weapon proficiency and medium armor proficiency. Make that their 3rd level features, though they might need a ribbon feature or something. Call it the "thug" and come up with some ideas for stuff that helps fit the idea of a brutish rogue.
The other option, as suggested is a feat.