added context_switch function