I'm kind of sure it was Xehanort screaming it at Terra as he struggled to regain control. o.o;;; might need a rewatch though.
its confusing. i always thought it would make sense that it was Terra because he first paralized him. then Xehanort started to struggle and then it was Terra saying
"Get out of my heart" i mean it would make sense for Terra to say that right because it is his own body.
i mean I just think Xehanort's too smart to stab himself with a keyblade as hes been using the keyblade for god knows how long while Terra is a young keyblade warrior and only his 20s and probably didnt know the consequences of what would happen if he stabbed himself unlike Xehanort who probably knows that it's a terrible idea to do that
just my take