Respected sir/ madam
It was really sad to hear about your grandfather.
The information you have provided is too little to infer anything conclusively.
However common causes for such a devastating vomiting of blood which takes away the life of patient can be rupture of varicose veins
(related to liver failure
), sudden rupture of a gastric ulcer, rupture of lower part of food pipe by repeated vomiting, bleed from a cancer of stomach, food pipe or intestine or rarely rupture of large blood vessel (aortic aneurysm
) into food pipe (esophagus
If you can provide more details, I will discuss further.