A man who appeared to be wielding a long knife died after being shot by Los Angeles police inside a shopping mall.