It actually measures the amount of glucose 'stuck' to the red cells over their lifetime.
Red cells last from 60-120 days so up to three months. However, because the older cells die off and new ones are produces, the test is weighted towards the last 2-4 weeks. (ie if your control gets better/worsens in the last month it will make a difference to the results)