Answer:
2,757,796 people died in vietnam war,korean war,civil war,world war 1 and 2,war of 1812,gulf war,mexican american war,spanish american war,revolutionary war combined together.There might be more but not counting unidentified soldiers.
Firstly, determining the number of human who have ever lived is problematic, as, particularly during the hunter-gatherer stage, we have little information about birth and death rates.
Part of the problem is that infant mortality (i.e. the percentage of infants who died before their first birthday) has been astronomical throughout history, perhaps as much as 50% during our hunter-gatherer days, and well over 10% since the establishment of civilizations c. 5,000 B.C.). This artificially inflates the numbers of humans who have been alive.
A wild estimate is that about 50 billion people have lived since 1 A.D., and perhaps as many as 70 Billion since the establishment of civilization.
If we restrict the question to people who have died as a direct result of warfare, and not by disease or starvation afterwards (that is, it would count everyone who died during a siege as "died in war", but not those who died right after the siege was over, due to continuing disease/starvation/etc), the total is relatively small.
Even in the industrial age, when mass killing in war became the norm, something as horrible as WW2 only caused less than 65 million deaths, out of a world population of about 2.2 Billion, which is less than 3% during that time period. Perhaps the bloodiest wars of the ancient era, the Punic Wars, resulted in a death rate of maybe 1.5% at best (250,000+ killed, out of 200 million world population). It's simply hard to kill people unless you have mechanized means at your disposal.
Thus, I think it's safe to assume that less 1% of the total world population has been killed in a war. That would mean less than 700 million people have died in war, and likely, that is a very HIGH estimate. Honestly, I'd vote for something on the order of 200 million or so as a better number, as killing simply was too difficult to do in large numbers until very recently.
The majority of post-infant humans who have died in history are due to epidemic disease (smallpox, typhus, plague, malaria, yellow fever, measles, cholera, influenza, etc) or starvation; additionally, perhaps about 25% of the total world population died before their first birthday.