Shares in Google parent Alphabet and electric carmaker Tesla sank on Thursday after the companies both reported negative free cash flow in their most recent quarters, due to large and ever-increasing spending on AI infrastructure.

The companies both said they expect the investments to yield strong returns later on, but some investors were evidently spooked, with Google shares closing down 7 percent and Tesla dropping 14.5 percent.

Google’s free cash flow fell to a negative $5.9bn, down from almost $25bn a year ago.

Image credit: Google

The firm, known for large profit margins from online advertising, has not gone into negative free cash flow since it went public two decades ago.