Can gcc spit out, given a C file, a list of the all function calls that occur, with filename and line number both for the call itself and for the function\'s declaration?
You might try Treehydra, a GCC plugin that gives you read-only access to GCC internal representations of code during compilation. (However, it's a bit of a chore to build, and I'm not sure it'll give better results than -fdump-* for this problem.)