Hi Luke,
There's nothing that can do that at the moment, but I'm not averse to
doing so (Bake has a mechanism for doing exactly this operation).
There is a single function which has the flavour of roughly what you
want:
https://hackage.haskell.org/package/shake-0.15/docs/Development-Shake.html#v:unsafeExtraThread
That function lets you use an extra thread without it being accounted
to you. In your case you want basically the inverse, to be considered
to be using a thread even though you aren't. You can do that with
resources by making every rule depend on a particular resource, but
that's nasty. Instead, I think the way to go is have a "more threads"
resource, so you could write:
phony "benchmark" $ withResource resourceThreads n $ ...
And that would acquire the necessary threads, one by one, and once it
had them all would do the action. Does that sound like it would work
for you?
Thanks, Neil