There's a few things here:
- Farmers in the U.S., for the most part, do not use "illegal immigrants." Instead, they hire "migrant workers," which are persons legally allowed to work in the United States.
- The bulk of businesses hiring illegal immigrants are government contractors. Go figure, aye?
- Work programs cost the government, and thus a "chain gang" would just be another government subsidizing program for farmers. Compensation, for any work performed by inmates, is Federally mandated and is initially applied to housing/restitution costs, which translates to the government losing money if they're paying the inmates.
- Prisoner abuse and injury has long been the problem with "chain ganging," which is another reason why it is not presently utilized in any U.S. State.
- Productivity of mandated chain gangs is marginal, at best, as there is no motivation for them to work. Motivation, via physical abuse, is illegal. Penalties, including isolation, are heavily restricted (to the point they are ineffective as a motivator, marginally effective as a deterrent to misbehavior) and there is insufficient isolation housing for such to be implemented on a large scale.
- The means to avoid participating in chain gangs, is to claim medical incapacity, which would (and has) result in a whole helluva lot of unnecessary doctors' visits, at our (government's) expense.
Volunteer work release programs are the modern alternative, which has private businesses employing inmates
(instead of the Government having to pay). Additional government agents are hired to monitor and manage these inmates, who are housed outside of the prison system. Paychecks go directly to the correctional facility, which provides a portion of the income for the inmates, whilst the bulk of it is applied to housing/restitution and the additional expenses required for running such a program.
The major problem with volunteer work release programs is public exposure to inmates, who are openly released into the community. They are released from their housing units only for the purposes of going to work, working, and then returning to their housing units. However, such is sufficient for these persons to run illegal activities on the side, which is often the case. Nonetheless, these volunteer programs are available only for prisoners in good standing. Violate the rules just once, even for failing to return to the housing unit on time or getting late to work, results in being incarcerated back into the prison and never being allowed to return to the work release program.
A more stringent approach is needed, but you cannot force prisoners to work without some legal means to motivate them, and any approach needs to be cost effective. Chain gangs are "not" that means.