The NICS is an on site process used at the point of purchase for a firearm. The FFL Dealer logs into the system and keys in the purchasers information then the system either approves or denys the purchase.
All the info contained by the FBI in the NICS is provided by the participating states and deals primarily with felony crime convictions or domestic assault issues.....There is no info provided to the FBI about an individual's mental health unless such illness was directly related to the felony conviction.
Does this mean the system is flawed? I don't think so, the only individuals who may have had a remote possibility of preventing this tragedy were the kid's family and I don't think they had any control over him since he no longer lived at home.
Also, you are mistaken about his residence, as Jerry Loughner lived with his parents.