When autoignition occurs the gas pressure wave it causes superimposes on the normal pressure wave of the combustion chamber. These two waves interact to create a third sawtooth-shaped wave pattern of pressure oscillations. The pressure oscillations create the knocking sound. Pressure waves caused by knock can build up quickly and shorten the life span of an engine. Knock can be reduced by adding chemicals to the fuel.
Common examples are tetra ethyl lead, aromatics, and oxygenates.
While these substances increase the octane rating, their composition does not contribute to the energy of the fuel when it is burned. The result may be less energy per unit volume of fuel used, and thus less efficiency. In short, higher octane fuels may require more fuel to be burnt in order to produce the same amount of energy. There is one piece of information we have been missing. The compression ratio of an engine has a lot to do with knock and the apparent effects of octane.