[…] she Too weak, for all her heart's endeavour, To set its struggling passion free From pride, […] (20-24)
The speaker doesn't consider Porphyria's presence there to be a sin. For him, the real sin is her "weak[ness]" and "pride" – her unwillingness to throw off society's expectations and be with him forever.
That moment she was mine, mine, fair, Perfectly pure and good: […] (36-37)
The moment that Porphyria "worship[s]" the speaker, he decides that she's no longer committing the sin of "pride" and she becomes "perfectly pure and good."
[…] I found A thing to do[…] (37-38)
The murder of Porphyria, in the speaker's mind, isn't a sin at all – it's just "a thing to do." He's awfully casual about killing his lover.