more visibility in test
many small bitfiddling fixes