Humans can switch flexibly to accomodate the tasks in any given environment, but that ability comes with the cost of increased reaction times during the transition. The switch cost probably comes from 1) interference and competition from action preferences in the last task set, and 2) configuring new S-R contigencies. Hyafil et al recently brain imaged subjects while they were performing either stationary or conflicting task sets. One theory is that the joint executive function of the ACC and dlPFC is overcoming sensorimotor conflict, but that the ACC detects conflict, while dlPFC activates the top-down algorithms to deal it when it arises. In this paper, the researchers argue that the ACC also assigns task sets a certain level of priority, and the dlPFC compensates for interference from concurrent task sets. This seems esoteric, but is the kind of question that will likely be integral for AI research.
Hyafil A, et al. 2009 Two mechanisms for task switching in the prefrontal cortex. doi:10.1523/JNEUROSCI.2828-08.2009