<div>Hi,</div><div> </div><div> </div><div>I am still stuck up with the debugging issue. </div><div> </div><div>I try to build the system with the debug flags with no optimization. I have used the pre-built 4.11 toolchain for blackfin.</div>
<div> </div><div>Is this an issue with rtems port of the toolchain?  Can anyone suggest more test  that i should be performing?</div><div> </div><div>If this is not the group that deals with toolchain issues to which group should this issue be reported to as a bug?</div>
<div> </div><div>To which mailing list do you want me to move this thread to the rtems-gdb mailing list, gnu-gdb or adi-gdb?</div><div> </div><div>Thanks and regards</div><div>Rohan Kangralkar</div><div><br><br> </div><div class="gmail_quote">
On Tue, May 24, 2011 at 11:38 AM, Rohan Kangralkar <span dir="ltr"><<a href="mailto:rohan.stays@gmail.com">rohan.stays@gmail.com</a>></span> wrote:<br><blockquote style="margin: 0px 0px 0px 0.8ex; padding-left: 1ex; border-left-color: rgb(204, 204, 204); border-left-width: 1px; border-left-style: solid;" class="gmail_quote">
<pre>Hi,<br><br>I am not using the ADI toolchain. I am using the toolchain provided by rtems.<br><br><br><i>I compile my source using</i><i> bfin-rtems4.11-gcc. Then i load it <br>to bfin-rtems4.11-gdb and</i><i> connect it to the bfin simulator.<br>

</i><i>Then i try to put a breakpoint in the file by opening then file. <br></i><i>The debugger complains that there is no such line number. Also<br></i><i>there is no optimization set while compiling. I also compile with <br>

the -g flag so that the debug symbols are included.</i><i> This is making <br>my debugging difficult since i have to look at the</i><i> disassembly <br>for debugging.  Is there any way i can use the C</i><i> source for debugging.</i><br>

<br><br>I find only the <a href="http://www.rtems.org/pipermail/rtems-tooltestresults/" rel="nofollow" target="_blank">RTEMS Tool Test Results</a> mailing group on rtems. To which <br>group should i move this thread to. <br>

<br><br>==========================================================<br>Rohan Kangralkar<br><br><br>Sorry I lost the mailing thread so i had to copy the mail contents.<br><br>===========================================================<br>

<br>Unfortunately, we probably need to move this to either the<br>binutils or gdb mailing lists.  I am not sure which.  Probably<br>the gdb mailing list is more likely to produce an answer.<br><br>Just to make sure I understand the bfin-elf gdb configuration<br>

includes support for a debug connection to a target that<br>bfin-rtems does not?  That doesn't seem correct given<br>that bfin-*-* is the pattern which matches both rtems<br>and elf bfin targets in gdb/configure.tgt<br>

<br>And the gdb's are built from the same source tree?<br><br>Why do you need the bfin-elf toolchain at all?<br><br>--joel<br><br>On 05/18/2011 10:55 AM, Rohan Kangralkar wrote:<br>><i><br></i>><i><br></i>><i> On Wed, May 18, 2011 at 11:44 AM, Rohan Kangralkar <br>

</i>><i> <<a href="http://www.rtems.org/mailman/listinfo/rtems-users" target="_blank">rohan.stays at gmail.com</a> <mailto:<a href="http://www.rtems.org/mailman/listinfo/rtems-users" target="_blank">rohan.stays at gmail.com</a>>> wrote:<br>

</i>><i><br></i>><i>     On Thu, May 12, 2011 at 5:43 PM, Joel Sherrill<br></i>><i>     <<a href="http://www.rtems.org/mailman/listinfo/rtems-users" target="_blank">joel.sherrill at oarcorp.com</a> <mailto:<a href="http://www.rtems.org/mailman/listinfo/rtems-users" target="_blank">joel.sherrill at oarcorp.com</a>>> wrote:<br>

</i>><i><br></i>><i>         On 05/12/2011 04:41 PM, Rohan Kangralkar wrote:<br></i>><i><br></i>><i>             Hi,<br></i>><i><br></i>><i>             I am using the rtems blackfin tools to build and debug my<br>

</i>><i>             board that contains analog devices BF527 processor.<br></i>><i><br></i>><i>             The issue i am facing is that I am not able to place<br></i>><i>             breakpoints in some part of my c code. So the debugging is<br>

</i>><i>             becoming difficult. GDB complains  "No line 291 in file"<br></i>><i>             even though the file has more that 300 lines of code.<br></i>><i><br></i>><i><br></i>><i>         What's the name of the file?  There is a chance there are two<br>

</i>><i>         files with the same name in the executable and gdb is confused.<br></i>><i>         I have seen this before.<br></i>><i><br></i>><i><br></i>><i>     The name of the file is tll_fpga.c. I looked for the file in my<br>

</i>><i>     project and there are no files with duplicate file names.<br></i>><i><br></i>><i><br></i>><i>             I use the compiler, debugger provided by rtems4.11 for<br></i>><i>             debugging my application.<br>

</i>><i><br></i>><i>             After some debugging and analysis of the mapping the line<br></i>><i>             number in the elf to the C code in the file using objdump<br></i>><i>             i find the following.<br>

</i>><i>             1.  executing the bfin-elf-objdump (  analog devices<br></i>><i>             toolchain) on the elf the following error is thrown out<br></i>><i><br></i>><i>             BFD: Dwarf Error: mangled line number section.<br>

</i>><i><br></i>><i>             2. but the objdump from rtems does not complain.<br></i>><i><br></i>><i>         Are they built from the same source?  If not, then random<br></i>><i>         differences.<br>

</i>><i><br></i>><i><br></i>><i><br></i>><i>     They are built from the same source.<br></i>><i><br></i>><i><br></i>><i><br></i>><i><br></i>><i><br></i>><i>             So<br></i>><i>             How do i correct the issue in the rtems blackfin gdb?<br>

</i>><i>             I also observe that analog devices have their own<br></i>><i>             gdb-proxy but rtems does not provide gpd-proxy<br></i>><i>             should the gdb-proxy also be included in the rtems bfin<br>

</i>><i>             toolchain?<br></i>><i><br></i>><i>         Would be good.  Yes.<br></i>><i><br></i>><i><br></i>><i><br></i>><i><br></i>><i>     I have some more information about the problem. To decouple it<br>

</i>><i>     from the ADI toolchain, I compile my source using<br></i>><i>     bfin-rtems4.11-gcc. Then i load it to bfin-rtems4.11-gdb and<br></i>><i>     connect it to the gdb bfin simulator.<br></i>><i>     Then i try to put a breakpoint in the file by opening then file. <br>

</i>><i>     The debugger complains that there is no such line number. Also<br></i>><i>     there is no optimization set while compiling.<br></i>><i>     This is making my debugging difficult since i have to look at the<br>

</i>><i>     disassembly for debugging.  Is there any way i can use the C<br></i>><i>     source for debugging.<br></i>><i><br></i>><i><br></i>><i><br></i>><i><br></i>><i>             Thankyou<br></i>><i>             Rohan Kangralkar<br>

</i>><i><br></i>><i><br></i>><i><br></i>><i>         -- <br></i>><i>         Joel Sherrill, Ph.D.             Director of Research&<br></i>><i>          Development<br></i>><i>         <a href="http://www.rtems.org/mailman/listinfo/rtems-users" target="_blank">joel.sherrill at OARcorp.com</a>        On-Line Applications Research<br>

</i>><i>         Ask me about RTEMS: a free RTOS  Huntsville AL 35805<br></i>><i>           Support Available <a href="tel:%28256%29%20722-9985" target="_blank" value="+12567229985">(256) 722-9985</a> <tel:%28256%29%20722-9985><br>
</i>><i><br></i>><i><br></i>><i><br></i>><i><br>
</i>><i><br></i>><i>     -- <br></i>><i>     ___________________________<br></i>><i>     Thanks and regards<br></i>><i>     Rohan Kangralkar<br></i>><i><br></i>><i><br></i>><i><br></i>><i><br></i><br>

<br>-- <br>Joel Sherrill, Ph.D.             Director of Research&  Development<br><a href="http://www.rtems.org/mailman/listinfo/rtems-users" target="_blank">joel.sherrill at OARcorp.com</a>        On-Line Applications Research<br>
Ask me about RTEMS: a free RTOS  Huntsville AL 35805<br>
    Support Available             <a href="tel:%28256%29%20722-9985" target="_blank" value="+12567229985">(256) 722-9985</a><br></pre><br><br><br>
</blockquote></div><br>