In glossy sci-fi movies like “Ex Machina” and “Chappie,” robots move with impressive — and frequently malevolent — dexterity. They appear to confirm the worst fears of prominent technologists and scientists like Elon Musk, Stephen Hawking and Bill Gates, who have all recently voiced alarm over the possible emergence of self-aware machines out to do harm to the human race.

“I don’t understand why some people are not concerned,” Mr. Gates said in an interview on Reddit.

“I think we should be very careful about artificial intelligence,” Mr. Musk said during an interview at M.I.T. “If I had to guess at what our biggest existential threat is, it’s probably that,” he added. He has also said that artificial intelligence would “summon the demon.”

And Mr. Hawking told the BBC that “the development of full artificial intelligence could spell the end of the human race.”

Not so fast. Next month, the Defense Advanced Research Projects Agency, a Pentagon research arm, will hold the final competition in its Robotics Challenge in Pomona, Calif. With $2 million in prize money for the robot that performs best in a series of rescue-oriented tasks in under an hour, the event will offer what engineers refer to as the “ground truth” — a reality check on the state of the art in the field of mobile robotics.