You need to go to the stage called Bomb Omb Field. Go to a level that allows you to us Cannons. Now, go across the bridge and go straight until you get to a Cannon on a big stone.
Jump into it.
Now, you want to aim your cannon a little bit more downward than the picture above. Line up the bottom arrow's bottom edge against the land with the big mountain. (The land closer to you) Then press A to fire. Mario will be blasted into the land, and then the game will glitch. Mario will disappear, and he'll be miles up in the sky, falling and he'll land on the top of the mountain, but taking damage along the way.