You need a topsail. It's all to do with the length of the leading edge of the mainsail. Thats why bermudans perform better to windward. Adding a topsail increases the apparent leading edge and therefore improves upwind performance.
Well, OK, you can do the usuals - cut down on surplus windage and weight aloft, clean the bottom, do some fiddling with the trimming ballast and then nip down to the sailmaker and order yourself a new staysail (that's the critical sail - replace that first, then the jib, then the mainsail).
However, you are never going to make a silk purse out of a sow's ear.
Well, without making drastic changes to the rig a topsail is the best way to improve a gaffers chances to windward.
The way the topsail is set up is important too though. If you don't have a topsail spar then it can sometimes be difficult to get the luff tension there, which will make a difference.
No one has mentioned jib luff tension and I always thought that was one of the key things to get a boat to point closer to the wind?
My (gaff) boat has running backstays just for this purpose. These are 3 to 1 block and tackles and they seem to work well. I just need to make sure the leeside is released and the windward side tensioned while going about. (Makes for a lot of rope pulling though)