Since Smart Contracts can call multiple contracts, is there a chance that smart contracts enter a gridlock situation?
-
Deadlocks are discussed here: ethereum.stackexchange.com/questions/4564/… – Richard Horrocks Apr 8 '18 at 15:07
No.
Transactions a well-ordered and execute serially. Contracts can call other contracts, which passes flow control to the other contract.
Although they can be logically entangled (parent do child.method()
, and child do parent.method()
) there is no wait loop so those methods either return or fail.
The block gasLimit
is the outer bulwark against the "halting problem". A transaction that does not complete "on budget" is deemed failed.
Have a look over here for more discussion of concurrency: What is the order and concurrency behavior of multiple calls to a contract in a single transaction?
Hope it helps.