No one is producing Bitcoin at loss, because it doesn't make any sense, but it might happen temporarily. Imagine the mining cost as a distribution curve, and bitcoin miners filling the distribution from the cheapest upwards to where the cost equals the revenue, i.e. the highest cost miner is at break-even, so that total of 3.125 (+transaction fees) bitcoin worth of hashrate is produced every 10 minutes. All but the highest cost miner operate at profit.