Doctors are deeply concerned for their severely mentally ill patients and the public, as Sydney courts brace for the impact on the criminal justice system.