It was a collateral death: an example of Double Effect.
It's like a soldier who throws himself on a live grenade to save his buddies. It is not suicide. The intent was to save the buddies. His death was foreseen but not intended. If he had done it and by some crazy circumstances lives, he woul consider it a "plus" because his own death, while accepted, was not intended.
THis is my opinion.
Laying down one's life is not the same as committing suicide. One would seem to earn God's praise; the other His scorn.
But back to the topic at hand, I believe God would look into this poor man's heart and see that all he wanted was surcease from pain. Maybe that's a moral failing, but I don't think He would damn anyone for merely being human.
Then again, I'm not God.
As valueless as mine.
What does your chosen religion teach?