Well, you generally don't, because Duff's Device isn't generally regarded as a good idea anymore, in my understanding:
> It turns out that with branch predictions and the relative speed of CPU
> vs. memory changing over the past decade, loop unrolling is pretty much
> pointless.
http://lkml.iu.edu/hypermail/linux/kernel/0008.2/0171.html