Switch to list for auxiliary threads

This makes it easy to ensure the ordering. There is a dependency between
the finalizer and the agent thread, because the agent creates an IO
object, so the finalizer needs to be setup.

Using this order makes sure that we run run auxiliary threads setup in a
fifo fashion and teardown in a lifo fashion. We also move the setup of
the finalizer thread before the phase where the agent thread might be
started.