There are actually new FIDE rules as of 2014 or so, where after 75 moves, or a fivefold repetition, the game is immediately declared drawn without the need for a player to take action.
Thanks for that clarification.
In perfect play either black or white resigns in their first move or agrees to a draw.
But in in-perfect play you could get a situation where it plays until heat death. You at the very least could wait for a bit flip on the memory of the opposing player that might let you win.
Of course two Kings can't checkmate each other. If the board bit flipped, well that would be cheating / not a proper game. So in this specific case it'd be agreeed to a draw without the 50 move/repetition rule by the most basic of programs since checkmate is not possible given any play. But legally they wouldn't have to, unlike the above scenario when it can make logical sense to continue.