Often the assembler cannot generate debug information automatically. This means that you cannot get a source report unless you manually define the neccessary debug information; read your assembler documentation for how you might do that. The only debugging info needed currently by OProfile is the line-number/filename-VMA association. When profiling assembly without debugging info you can always get report for symbols, and optionally for VMA, through opreport -l or opreport -d, but this works only for symbols with the right attributes. For gas you can get this by
.globl foo .type foo,@function |
whilst for nasm you must use
GLOBAL foo:function ; [1] |
Note that OProfile does not need the global attribute, only the function attribute.