Improve the arch affinity support.

Updates the new arches.py functions to be useable by orm.py,
and updates orm.py to use them (this re-enables create_jobs).

Note that this moves the list of preffered affinities to the GroupSource model,
as it needs to be consistent with the list of valid architectures in
the GroupSource model.