Judge warns ‘people are going to get hurt’ as sentencing delays leave ‘hundreds if not thousands’ of convicted offenders awaiting sentence