watch out for == between compmap and compapptr