another 1/3 of bddop.c