U.S. President Barack Obama said late Thursday that he was “most frustrated” over his failure to pass “sufficient common sense gun safety laws” in the country. The comments, made in a BBC interview, came just hours before a gunman opened fire inside a movie theater in the state of Louisiana, killing two people and injuring several others before shooting himself.

“If you ask me where has been the one area where I feel that I've been most frustrated and most stymied, it is the fact that the United States of America is the one advanced nation on Earth in which we do not have sufficient common sense gun safety laws even in the face of repeated mass killings,” Obama said.

American citizens’ right to bear arms is protected under the Second Amendment to the U.S. constitution. However, a much higher prevalence of gun violence in the U.S. compared to other developed nations has led many activists to demand stricter gun controls.

According to the Gun Violence Archive, a nonprofit that compiles data about gun-related violence, over 7,100 people have been killed this year in nearly 28,000 incidents of gun violence in the U.S.

“If you look at the number of Americans killed since 9/11 by terrorism it’s less than 100,” the president added. “If you look at the number killed by gun violence, it’s in the tens of thousands. And for us not to be able to resolve that issue has been something that’s distressing but it’s not something I intend to stop working on in the remaining 18 months.”

In the wide-ranging interview, Obama also touched upon the issue of race relations in the U.S. at a time when debate is raging over whether enough is being done to tackle institutional racism in the country.

Although a recent poll, conducted jointly by the New York Times and CBS News, revealed that nearly 6 in 10 Americans thought race relations in the country are “generally bad” and 4 in 10 believed that the situation is actually getting worse, Obama said that race relations had improved during his presidency.

“There was never a promise that race relations in America would be entirely resolved during my presidency or anybody’s presidency. This has been a running thread and fault line in American life and American politics since its founding,” Obama told BBC. “What I will say is that after eight years of my presidency, children growing up during these eight years will have a different view of race relations. … America is becoming more diverse, it’s becoming more tolerant.”