call majority() before entering phi node