loop refinements
optimize cabal