Netflix chief executive Reed Hastings took the stage at Amazon’s big cloud event in Las Vegas today with Amazon’s senior VP Andy Jassy, and told the audience that he wanted Netflix to be the largest business in the world that runs entirely on Amazon Web Services.

In spite of the fact, of course, that Amazon and Netflix are die-hard competitors.

“The biggest benefit is the scale,” Hastings said. “Now we’re on a cost curve and an architecture that, as more people use it, gets cheaper.”

Netflix, of course, sells streaming entertainment. So does Amazon … and Amazon also sells DVDs and Blu-Rays. But Hastings said that Amazon CEO Jeff Bezos has assured him that it is safe to be on Amazon’s cloud services, and Jassy told him that to Amazon Web Services, Amazon streaming and Netflix streaming are just two equal clients.

“Netflix is every bit as important a customer to us as Amazon retail,” Jassy said.

While cost and scalability are the huge benefits of the cloud — especially since Amazon just reduced most clients’ data storage costs by about 25 percent — Hastings also talked about what is not great with the cloud: configuration.

“When you have to pick individual instance types, you know something’s wrong,” the very technical Hastings said, referring to how Amazon packages and prices cloud usage. “It reminds me a lot of when I started in computing and had to handle register allocation manually before compilers came out … we’re kind of at that stage before the compiler.”

Hastings also provided some insight into how Netflix uses the cloud beyond basic storage and streaming.

“Netflix’s biggest problem is ranking,” Hastings said, saying that the company has the impossible task of fitting 10,000 videos into 10 inches of screen real estate.

When the company gets it right, people watch what Netflix is showing them. When the company gets it wrong, he says, people go watch cable. So Netflix analyzes gigabytes of subscriber data on the cloud to optimize its ranking methodology … and ensure that what users see on the first page of Netflix is something that’s actually interesting to them.