There are two different explanations for the two examples you give.
Harry didn't think to use a Summoning Charm
In the instance where Harry is stuck in the stair, a Summoning Charm would've been useful, it's true. It would possibly have allowed Harry to stop the Egg wailing extensively and waking up the teachers. But, with magic as with life in general, the trick is not just knowing the theory but being able to make correct decisions in the heat of the moment. This is not as easy as it seems. You may know the theory of how to control a skidding car but it's easy to panic when the situation arises and slam on the brakes/turn the steering wheel the wrong way, thereby making things much worse. In retrospect, Harry may well have thought, "It would've been good to use a Summoning Charm in that situation". But he simply didn't think of it at the time. There were some mitigating factors. The Marauder's Map was quite close and he thought he might be able to reach it anyway.
Harry pulled out his wand and struggled to touch the Marauder's Map, to wipe it blank, but it was too far away to reach.
(Goblet of Fire, Chapter 25, The Egg and the Eye).
Moody/Crouch could also see through Invisibility Cloaks so all attempts at remaining hidden were futile when he turned up. Harry doesn't actually lose the Marauder's Map at this point but freely gives it away later in the chapter.
"Can I borrow this?"
"Oh!" said Harry. He was very fond of his map, but on the other hand, he was extremely relieved that Moody wasn't asking him where he'd got it, and there was no doubt that he owed Moody a favour. "Yeah, OK."
(Goblet of Fire, Chapter 25, The Egg and the Eye).
This didn't give Harry cause for concern. After all, he had no reason to suspect Crouch and he'd handed the Map over to a previous Defence Against the Dark Arts teacher in similar circumstances the previous year.
"And I can't let you have it back, Harry." [Lupin]
Harry had expected that, and was too keen for explanations to protest.
(Prisoner of Azkaban, Chapter 14, Snape's Grudge).
Harry couldn't summon the Triwizard Cup
As @Bellerophon mentions in the comments, it won't be possible to Summon certain things in certain circumstances. For instance, Harry tried Summoning a locket in a later book to no effect.
"We couldn't...we couldn't just try a Summoning Charm?" Harry said, sure that it was a stupid suggestion, but much keener than he was prepared to admit on getting out of this place as soon as possible.
"Certainly we could," said Dumbledore, stopping so suddenly that Harry almost walked into him. "Why don't you do it?"
"Me? Oh...OK..."
Harry had not expected this, but cleared his throat and said loudly, wand aloft, "Accio Horcrux!"
With a noise like an explosion, something very large and pale erupted out of the dark water some twenty feet away; before Harry could see what it was, it had vanished again with a crashing splash that made great, deep ripples on the mirrored surface.
(Half-Blood Prince, Chapter 26, The Cave).
The long and the short of it is they can't Summon the locket. Voldemort had placed anti-Summoning Charms on the object to prevent people from skipping steps in winning the Horcrux. In a competition as supposedly prestigious as the Triwizard Tournament the Ministry would've been pretty dumb, quite frankly, to have allowed the whole thing to be won by a simple Summoning Charm. It's almost certain that they placed anti-Summoning Charms on the Cup to force competitors to go through the maze and face the challenges properly. So a Summoning Charm would have simply been ineffective.