Very common in student culture. Often used with admiration or light jealousy. The opposite is 学渣 (xuézhā, academic slacker). There's also 学神 (xuéshén, study god) — someone who aces everything without seeming to try.
memory
霸 means 'tyrant' or 'overlord' — a 学霸 is an overlord of studying. They rule the classroom like a king rules a kingdom.