Optimus was informed shortly after once recieving a message through his internal communication system, and before he confronted Sentinel at the Lincoln Memorial. Moments later he also discovered the fate of Skids and presumed Mudflap. When an Autobot hears static, there is still a chance they can be saved, but when there is utter silence, the Spark is utterly destroyed.
As Goktimus said, Prime doesn't exactly respond strongly to a character demise (bar Elita-1 in Rising Storm). Moments later, Prime forgets Ironhide and makes excuses that Sentinel must have been brainwashed and under Decepticon control.
It was in the novel.