Pip's initial reaction to finding out Magwitch is his benefactor is one of horror and almost disgust. All this time, Pip had believed that Miss Havisham, an odd but socially accepted woman, had been his benefactor and that she was grooming Pip to become a husband for Estella. Discovering Magwitch, who is a lower class, convict, is the one he owes his "expectations" to shatters many of his dreams.
But, as Pip comes to know his benefactor and to understand his past he realizes the kind of person he himself has become. This old man to whom he showed kindness only once, sent Pip his money and risked his life in order to meet Pip. In recognizing the irony of the entire story,from making him into a gentleman to fathering Estella, Pip changes and becomes a caring and thoughtful person again. He recognizes his debt to Magwitch and looks beyond his social standing. He goes to great lengths to get Magwitch out of the country and when that fails, stays with him until his death. He begins to realize that wealth and social status are not prerequisites to happiness and respect.
Dickens divided his novel "Great Expectations" into three parts for specific reasons, one of which was to reveal the stages of Pip's growth. As a dynamic character, Pip moves from his innocence and unconditional love of Joe and kindness to the convict in Stage 1 to a value system based upon social status in Stage 2 of the novel. For instance, he becomes ashamed of Joe because he does not possess the social graces of such gentlemen as Herbert and feels that Miss Havisham's social status makes her a superior benefactor--even though she is insane--over a lowly criminal such as Magwitch.
Now, in Stage 3 the reader perceives that Pip has grown in his thinking. For, he has come to understand what Mr. Jaggers has told him earlier in the novel: "Take nothing on appearances." That is, social status is merely a mask for what a person is. The truly good people, the people with real human values, are the "common" ones: Joe, Biddy, Magwitch. In Chapter 45 Pip sees what kind of a person Magwitch is, not what he appears to be as in Chapter 39 of Stage 2 in which Pip has held false values.
There is a quote from Carl Jung which explains the transformation of Pip:
Your vision will become clear only when you can look into your own heart. Who looks outside, dreams; who looks inside, awakes.