Robert Downey Jr. starred in critically acclaimed films during his heyday of the early 90's, but after his newfound stardom, Downey fell off the wagon and was found unceremoniously in the street, strung out. Approached by key individuals in Marvel to have his chance at a career redemption and play the role of a lifetime, Iron Man, the actor is introduced to an entirely new generation of fans who adore him.
Now, just replace "Robert Downey Jr." with "Trevor Slattery", "Marvel" with "A.I.M.", and "Iron Man" with "The Mandarin". Obviously, some details are warped to a darkly comedic effect in the movie (Marvel helped Downey get clean instead of giving him more drugs to entice him), but Trevor Slattery's just one aspect of the film's portrayal of Robert Downey's career. In a sense, the movie is one big satire of Robert Downey Jr.'s recent career comeback. The main theme of the film, "Does the suit make the man, or does the man make the suit?", was Shane Black's view that Downey was the driving force behind the success of the Iron Man saga.
Tony Stark's character foil is Aldrich Killian, who represents the actor who gets too caught up in his own role and thus becomes, in a sense, inseparable from it. Typecast, in a sort of way. Killian's Mandarin is your Mark Hamill Luke Skywalker, your Michael Keaton Batman, your Toby Maguire Spider-Man. Despite the box office success of those films, and the talent of the actors who played those characters, the characters could have been played anybody, just like Guy Pearce and the Killian character.
You gotta remember that Iron Man 3 was, at one point, the last Marvel film in Robert Downey Jr.'s contract, and it only makes sense for Tony to realize he doesn't need Iron Man to be a well rounded being and ends his "contract" via House Party Protocol and throwing his chest reactor into the ocean. Of course, Downey was signed on for two more films after the fact, but there was still an air of uncertainty during the production of the film.
If none of that made sense, I'm just saying the main theme of the film is that the actor should make the character, not the other way around. Iron Man would not have been the success it was without Robert Downey Jr.'s gravitas. After all, Ion Man can still operate without Tony Stark in the suit, it just might be hollow and fall apart easily.