The number of people killed in acts of terror reached a record high last year, with almost four in five of these deaths occurring in just five countries, new research shows.