cleanup dwarf code