In fact a pendulum is not a perfect harmonic oscillator! As it swings higher, its period becomes longer.

Also, the curve it traces out in phase space deviates further from a perfect ellipse. This makes the math more complicated and interesting.