President Trump delivered a rebuke to Japan Inc. on Monday.

"Try building your cars in the United States instead of shipping them over. Is that possible to ask? That's not rude. Is that rude? I don't think so," Trump told executives from local automakers during a trip to Japan.

At the same time, Trump thanked Japanese automakers for "building new plants and doing expansions" of existing facilities in the United States. He praised Toyota (TM) and Mazda (MZDAF) for planning a new $1.6 billion manufacturing plant in the U.S.

Trump has made reducing the $57 billion trade deficit with Japan a top priority.

But Japan's big three car companies have huge factories in the U.S., and their production in the country is at a record high. Japanese automakers have been increasing their investment in the U.S. for decades.

The Japan Automobile Manufacturers Association estimates that its members built nearly 4 million vehicles in the U.S. last year. Exports from Japan to the U.S. have fallen from 3.5 million cars a year in 1986 to just over 1.5 million in 2016.

It said that three out of four Japanese cars sold in the U.S. last year were built in North America, including Mexico and Canada.

"Many Japanese cars are made in the U.S. already and this request is not reflective of today's reality," said Stephen Nagy, a professor at Tokyo's International Christian University.

Nissan (NSANF) says that it sold 1.5 million vehicles in the U.S. last year, and made 1 million in the country -- although some of those were for export. Honda (HMC) locally manufactured 70% of the 1.2 million vehicles it sold in the U.S. in 2016. Toyota (TM), meanwhile, built 2.1 million cars at its North American plants last year. It didn't respond to a request for more detailed statistics.

Trade with Japan is a major flash point for Trump, who is on a lengthy tour of Asia.

"Our trade with Japan is not fair and it's not open," he said Monday.

Related: Asia braces for Trump's trade trash talk

Foreign firms have been eager to play up their investments in the U.S. following the election of Trump, who blames lopsided trade agreements for decimating American industry and killing blue-collar jobs.

Toyota, for example, is spending $1.3 billion to upgrade a facility in Kentucky. It has also scaled back a planned $700 million investment in a new manufacturing plant in Mexico.

The U.S. runs deficits with all five countries that Trump will visit in Asia, including a particularly big one with China.

-- Correction: The original version of this article and its headline did not make clear that President Trump had praised Japanese automakers for expanding existing U.S. facilities and for making new investments in the U.S. The article and headline have been updated.