The path from pop to screen stardom is strewn with the wreckage of a thousand broken dreams but British singer Harry Styles may have pulled it off first time in wartime epic "Dunkirk".

The path from pop to screen stardom is strewn with the wreckage of a thousand broken dreams but British singer Harry Styles may have pulled it off first time in wartime epic "Dunkirk".

If initial reactions to the big-budget wartime epic -- which is released this week -- are anything to go by, Styles may be about to join a select club that includes David Bowie and Mark Wahlberg as rare exceptions to the rule.

The One Direction singer plays a teenage British soldier desperate to escape northern France in 1940 as German troops push the Allies into the sea.

"Harry put in an amazing performance," said the film's British director Christopher Nolan, the man behind some of the biggest blockbusters ever made.

"He very much earned his seat at the table and did a wonderful job," the maker of "Interstellar", "Inception" and "The Dark Knight" told AFP.

Critics canvassed after its red-carpet premiere this weekend were also pleasantly surprised by how well the pop star did, with one tweeting "Harry Styles can act!"

The 23-year-old singer trained with the film's stunt crew before the arduous shoot on the same beaches from which 338,000 British, French and Canadian troops were evacuated despite constant shelling and bombing raids in the nine days that became known as the "Miracle of Dunkirk".

Big gamble

Styles has screen time alongside heavyweights Cillian Murphy, Kenneth Branagh and Mark Rylance in the movie.

But co-star Jack Lowden said neither he nor the film's other big screen first-timers, British actors Fionn Whitehead and Tom Glynn-Carney, looked out of place in such company.

"It's remarkable what the boys did," he told AFP.

British singer Harry Styles plays a teenage British soldier in the big-budget wartime epic "Dunkirk"(AFP)

"On a set like this you could pick the wrong two or three guys and they could implode on you. Christopher Nolan took a gamble and it worked."

Styles, whose debut solo single "Sign of the Times" topped the charts in 84 countries in May, admitted that the shoot, which was hampered by bad weather, was tough and that he was "overwhelmed" by his first few days on set.

Unlike almost all big Hollywood directors, Nolan eschews special effects.

He insisted on using the actual locations where the events took place, real warships and World War II aircraft and many of the original "little boats" that brought the soldiers safely to England.

Nor did he stop filming when gales blasted the French coast, tearing lumps off an historic jetty he had had rebuilt.

"The whole film was a bit of a challenge. We were not working in normal film set conditions," Styles told AFP before its premiere in Dunkirk on Sunday.

"Chris is very visceral in the way he works, which can be intense at times. It was nothing of course compared to the real story... but yeah it was tough."

Who's Harry Styles?

Styles's character Alex is one of a group of young soldiers whose ordeal on the beaches is followed over a week in the film.

"Alex has this edge to him. He comes off a little more hardened than the other guys. Alex likes the idea of being the tough guy, but he's also really scared," he said.

"It is impossible to know how you would have reacted (in that situation). And luckily we haven't had to.

"Growing up in England you learn a little bit about Dunkirk in school. But because it is not our finest moment it is often washed over and told quite quickly," Styles added.

"It is this fairytale story of people who were on the beach and then were picked up and taken home" by the plucky little boats.

Nolan, 46, who made his name with "Memento" starring Guy Pearce in 2000, admitted that he didn't really know who Styles was before he began casting for the film.

"My kids talked about him, but I don't think I was that aware of how famous Harry was.

"We were looking at thousands and thousands of young men in open casting calls" when Harry put himself forward, he said.

"We were determined to cast fresh faces -- unknowns ironically... (but) Harry very much earned his seat at the table."