-
If it's on a bike with rings and chain you can usually position the other pedal under low shelf or similar that you don't care about and wrangle things so you can push dead hard on an extension that'll loosen the pedal whilst jamming the other one into the shelf holding everything else in place. Always try the pedals first if they're meant to be coming off. If that's not an option then I'd put the allen key in a vice and turn the crank, easier on the left one when you can extend it more easily.
No flats on the pedal and i have taken the rings off. Ultegra 34/50