The invention relates to a mechanical oscillator, in particular for watchmaking, comprising a spiral spring (1) having a number N of turns, a central end (2), an eccentric end (3) and a rotary collet (4), connected to the central end (2), comprising an orifice intended to receive an arbor for rotation about an axis (A), and a balance (7), the axis of rotation of which coincides with the rotation arbor (A), the eccentric end (3) being intended to be integral with a stationary element of the “balance-cock” type, said spiral spring (1) being made up of a single-crystal silicon (Si) core (1a) and at least one peripheral coating (1b) based on a material having a thermoelastic coefficient different from that of silicon, the single-crystal silicon (Si) being oriented along the crystallographic axis {1,1,1} to optimize the temperature coefficient of the mechanical oscillator as a whole. In addition, this invention likewise relates to a method of designing said mechanical oscillator, consisting in optimizing the temperature coefficient of the complete oscillator in order to limit its thermal drift.