issue with profiling in LLVM 3.1

Hi,

I am using the profiling feature of LLVM 3.1. Mostly, it works well, but seems to be wrong in a few cases. For example, I have found that the number of times a function executed is reported as less than the number of times that the basic block calling this function executed (the difference was about 25x!). I am copying out the exact functions below. The relevant parts are in bold font: