All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger.
First of all, it should be noted that the fact that a certain meat is forbidden does not necessarily mean that it is impure; rather, the prohibition may be due to something else. For example, the meat of a human being is forbidden to eat, and this is not because it is impure but rather because of its sanctity as stated by the scholars.
Pork, on the other hand, is forbidden and impure. Allaah says (what means): {…or the flesh of swine — for indeed, it is impure —}[Quran 6:145]
As regards the effect of eating an impurity on the prayer, like eating pork or consuming alcohol, then a person who has eaten or drunk an impurity is still obliged to perform the prayer and it is not permissible for him to abandon the prayer, but some scholars said that he has to vomit that impurity so that his prayer would be valid and if he is unable to vomit it, then it does not affect the validity of his prayer as he was unable to vomit it.
The commentary of Ad-Dusooqi on Ash-Sharh Al-Kabeer, in the Maaliki Fiqh, reads: “If one has eaten or drunk an impurity, he is obliged to regurgitate it if possible; otherwise, he is obliged to repeat the prayer as long as he believes that the impurity remains in his stomach; and if he is unable to regurgitate it, then there is no harm on him as he was unable to remove it.”
If someone eats or drinks an impurity and repents, then Allaah will accept his repentance. Allaah says (what means): {And it is He who accepts repentance from His servants and pardons misdeeds, and He knows what you do.}[Quran 42:25]
It is important that you refer to Fataawa 87744 and 115699.
Allaah Knows best.