On the Deligne-Simpson problem