Synchronizing execution between parent and child