Keira Knightley will star in The Imitation Game with Star Trek Into Darkness villain Benedict Cumberbatch.

Variety first reported that she is in talks for the film, which will be directed by Morten Tyldum (Headhunters). Teddy Schwarzman’s Black Bear Pictures is financing, with Nora Grossman and Ido Ostrowsky of Ampersand Pictures as co-producers. There’s still no distributor attached, but Knightley’s participation might help the production find one soon.

The film is based on the life of Alan Turing, a genius British mathematician who helped the Allies break Nazi codes during World War II. His life and career took a radical turn in the 1950s, though, since he was persecuted for being homosexual. It’s based on Alan Turing: The Enigma.

According to The Hollywood Reporter, it’s expected to have a $15 million budget.

It’s a project that’s been sitting around Hollywood for a few years, showing up on the 2011 Black List. Leonardo DiCaprio was interested at one point and it was even set up at Warner Bros. But when DiCaprio dropped out, so did Warner Bros. Cumberbatch board the project in February, reviving it.

Knightley recently appeared in Anna Karenina and is filming Paramount’s Jack Ryan reboot with Chris Pine.

image: NBC