Hi, I'm using CC4.10.37. My sources files are located in 4 different directories and the project file is in an other directory. When I step into the code, CC is sometimes able to find the source for some files but not for all of them. Realy annoying ! Does anyone know the logic or limitation used by CC to find the source when debugging ? Thanks a lot! |
|
cannot find source files when debugging
Started by ●August 4, 2003
Reply by ●August 5, 20032003-08-05
Hi Frederic I have never needed to extensively use multiple directories as you are. Still, I assume you are tinkering with the Project->Options pulldown menu that opens the "Build Options" dialog box. Here you will find a "Compiler" tab, and at the bottom a list of sub options under 'Catagory'. If you have missed this, select 'Files' and fill in the directories. On the other hand, if this is a bonafied CCs problem, it might be that trying to pass extremely long strings on the command line (CL30 blah blah blah blah...) is limited. The usual way of creating an extended search path is with the C_DIR (A_DIR etc...) environment variables. Also note that the OS itself might be getting you by not allocating enough environment space. You can see what is in the environment space by opening a DOS console box and executing the 'SET' command. This will list to the screen all of the environment variables including the path. The environment space allocation is usually set as an option to command.com in command.sys when the PC starts. Hope this helps, Best regards, Keith Larson --------------------------------- At 10:21 PM 8/4/03 -0000, you wrote: Hi, I'm using CC4.10.37. My sources files are located in 4 different directories and the project file is in an other directory. When I step into the code, CC is sometimes able to find the source for some files but not for all of them. Realy annoying ! Does anyone know the logic or limitation used by CC to find the source when debugging ? Thanks a lot! +-----------+ |Keith Larson | |Member Group Technical Staff | |Texas Instruments Incorporated | | | | 281-274-3288 | | | | www.micro.ti.com/~klarson | |-----------+ | TMS320C3x/C4x/VC33 Applications | | | | TMS320VC33 | | The lowest cost and lowest power 500 w/Mflop | | floating point DSP on the planet! | +-----------+ |
Reply by ●August 6, 20032003-08-06
Keith, The project/option/compiler/files/obj directory is filled. I use a other directory than the sources directories The project/option/compiler/includeSearchPath is not too big because in this case the compiler would complain about include. So there is something else causing the problem. After I load my program, the source of the main is not seen (can't do 'go to main', can't step in main.) But when I do view/mixed source asm, code composer is able to mix asm and source. Also I'm able to set a breakpoint, but when the breakpoint is reached, the asm is shown instead of the c source. Do you know by which way code composer know the path of the debug symbol file (.obj) Rgs, Fred ----- Original Message ----- From: Keith E. Larson To: frederic_terrettaz ; Sent: Tuesday, August 05, 2003 4:21 PM Subject: Re: [c3x] cannot find source files when debugging Hi Frederic I have never needed to extensively use multiple directories as you are. Still, I assume you are tinkering with the Project->Options pulldown menu that opens the "Build Options" dialog box. Here you will find a "Compiler" tab, and at the bottom a list of sub options under 'Catagory'. If you have missed this, select 'Files' and fill in the directories. On the other hand, if this is a bonafied CCs problem, it might be that trying to pass extremely long strings on the command line (CL30 blah blah blah blah...) is limited. The usual way of creating an extended search path is with the C_DIR (A_DIR etc...) environment variables. Also note that the OS itself might be getting you by not allocating enough environment space. You can see what is in the environment space by opening a DOS console box and executing the 'SET' command. This will list to the screen all of the environment variables including the path. The environment space allocation is usually set as an option to command.com in command.sys when the PC starts. Hope this helps, Best regards, Keith Larson --------------------------------- At 10:21 PM 8/4/03 -0000, you wrote: Hi, I'm using CC4.10.37. My sources files are located in 4 different directories and the project file is in an other directory. When I step into the code, CC is sometimes able to find the source for some files but not for all of them. Realy annoying ! Does anyone know the logic or limitation used by CC to find the source when debugging ? Thanks a lot! +-----------+ |Keith Larson | |Member Group Technical Staff | |Texas Instruments Incorporated | | | | 281-274-3288 | | | | www.micro.ti.com/~klarson | |-----------+ | TMS320C3x/C4x/VC33 Applications | | | | TMS320VC33 | | The lowest cost and lowest power 500 w/Mflop | | floating point DSP on the planet! | +-----------+ _____________________________________ Note: If you do a simple "reply" with your email client, only the author of this message will receive your answer. You need to do a "reply all" if you want your answer to be distributed to the entire group. _____________________________________ About this discussion group: To Join: Send an email to To Post: Send an email to To Leave: Send an email to Archives: http://groups.yahoo.com/group/c3x More Groups: http://www.dsprelated.com |
Reply by ●August 6, 20032003-08-06
Hi Frederic My mistake, I thought you were having a compile problem. I know you probably never wanted to know what is inside a *.OUT file, but if you happen to examine one with a binary editor, you can peer inside and have a look. Interestingly, there is no directory information. If you think about this, with no directory information, the debugger needs to search for the files in some reasonable way. This version of CC(s) is, at least from the documentation I found, using the D_DIR and D_SRC environment variables to set up the search paths (do a GOOGLE search). BTW, I have not actually gone about seperating my source files to test this hypothesis. That is, the DOC I found seems to imply this. Note that if you have multiple sources, the search order is important! What a Pain In The Ass (PITA) that has been for me as I was writing the new VC33 DSK and debugger, which by the way has no heritage to CC! The present mechanism for the DSK debugger is to search the *.OUT files directory for sources. Yet another little thing to work on :-) Best regards, Keith Larson Tidbit Note: ASM30 can also track ASM source files by adding the -g command. It is *real* nice having the comments to look at. However, the resulting files tend to explode in size, so use sparingly. The TI Software Development Tools group added this after I one-upped them by adding ASM source tracking to the DSK some years ago. CL30 MAIN.C -g <- enable C/HLL tracking ASM30 OPTIMIZE.ASM -g <- enable ASM/HLL tracking LNK30 LINKIT.CMD -- At 03:56 PM 8/6/03 -0400, you wrote: Keith, The project/option/compiler/files/obj directory is filled. I use a other directory than the sources directories The project/option/compiler/includeSearchPath is not too big because in this case the compiler would complain about include. So there is something else causing the problem. After I load my program, the source of the main is not seen (can't do 'go to main', can't step in main.) But when I do view/mixed source asm, code composer is able to mix asm and source. Also I'm able to set a breakpoint, but when the breakpoint is reached, the asm is shown instead of the c source. Do you know by which way code composer know the path of the debug symbol file (.obj) Rgs, Fred ----- Original Message ----- From: Keith E. Larson To: frederic_terrettaz ; Sent: Tuesday, August 05, 2003 4:21 PM Subject: Re: [c3x] cannot find source files when debugging Hi Frederic I have never needed to extensively use multiple directories as you are. Still, I assume you are tinkering with the Project->Options pulldown menu that opens the "Build Options" dialog box. Here you will find a "Compiler" tab, and at the bottom a list of sub options under 'Catagory'. If you have missed this, select 'Files' and fill in the directories. On the other hand, if this is a bonafied CCs problem, it might be that trying to pass extremely long strings on the command line (CL30 blah blah blah blah...) is limited. The usual way of creating an extended search path is with the C_DIR (A_DIR etc...) environment variables. Also note that the OS itself might be getting you by not allocating enough environment space. You can see what is in the environment space by opening a DOS console box and executing the 'SET' command. This will list to the screen all of the environment variables including the path. The environment space allocation is usually set as an option to command.com in command.sys when the PC starts. Hope this helps, Best regards, Keith Larson ------------------------------ At 10:21 PM 8/4/03 -0000, you wrote: Hi, I'm using CC4.10.37. My sources files are located in 4 different directories and the project file is in an other directory. When I step into the code, CC is sometimes able to find the source for some files but not for all of them. Realy annoying ! Does anyone know the logic or limitation used by CC to find the source when debugging ? Thanks a lot! +-----------+ |Keith Larson | |Member Group Technical Staff | |Texas Instruments Incorporated | | | | 281-274-3288 | | | | www.micro.ti.com/~klarson | |-----------+ | TMS320C3x/C4x/VC33 Applications | | | | TMS320VC33 | | The lowest cost and lowest power 500 w/Mflop | | floating point DSP on the planet! | +-----------+ |
Reply by ●August 8, 20032003-08-08
Hello Khurram This highly depends on what you want to do and how much you want to spend. DSK's ----- For me, 99% of what I do is with the C31 and now VC33 DSK. These low cost $150 kits use a small 250 word interrupt driven 'kernel mode' driver that is loaded into hi-ram. This in turn is used to send data to and from the host processor (usually a PC) via a communications link (in this case the PC printer port). By tacking on the STOP,RUN and STEP, emulation commands a debugger is now possible. Advantage --------- High performance interface for applications (EG FFT analyzer) that can be reused for a number of applications Kernel is a real time mini-RTOS that can be extended TI open source for all tools (except the TI COFF code gen tools that are also included) The host port (printer port) inteface is nothing more than a comm channel. Any suitable com channel can be used but you will need to tweek the driver code. Example would be a memory mapped version of the PC printer port. You can hit transfer rates approaching 10MB/Sec this way. Low cost $150: VC33-150, PCM3003 stereo codec, external SRAM and FeRAM A JTAG *connector* is on the board so you can use it as an emulator target DSK3DW debug tool is not Code Composer based and packed with a lot of features you wont find in Code Composer Disadvantage ------------ Connected to data pins and occupies some address space Occupies memory and interrupt space DSK3DW Debug tool is not Code Composer based (not a typo). The weakest part of this debugger is that it does not have a full blown program build manager. Instead, when a source file is edited you will be prompted to run a make or batch file containing the build information that then runs in the background. Simple and easy to impliment! JTAG ---- On the other hand, if you want to go with a full blown JTAG emulator, Spectrum Digital, Blackhawk, Signum, DSP Research, Kane Computing and others come to mind. Advantage --------- Non intrusive: Does not occupy memory or interrupt space You can *really* grab hold of the processor. This can be important on the first time startup (after this I prefer a comm interface). Small footprint required to pin out the JTAG header Disadvantage ------------ Host side applications do not have access to a comm/debug host port interface so building an interactive application is pretty much out of the question. JTAG emulators can be rather expensive, so if you just want to get a flavor of what JTAG is like, you might want to look into a low cost JTAG board like Spectrum Digitals VC33 Ez-DSP (this is not a DSK). Also note that the Ez-DSP is not a full blown emulator, and is under special license so you are obliged to only use the tools for that one board. I hope this helps, but I expect this will generate more questions :-) Best regards, Keith Larson At 04:52 AM 8/8/03 -0700, you wrote: >Dear Keith, >Plz suggest me a VC 33 debugger/emulator. >thanx >khurram +-----------+ |Keith Larson | |Member Group Technical Staff | |Texas Instruments Incorporated | | | | 281-274-3288 | | | | www.micro.ti.com/~klarson | |-----------+ | TMS320C3x/C4x/VC33 Applications | | | | TMS320VC33 | | The lowest cost and lowest power 500 w/Mflop | | floating point DSP on the planet! | +-----------+ |
Reply by ●August 11, 20032003-08-11
Keith, I try to add to the environment variable D_SRC the path of the different directrories where my source files are located and it work!!! Code composer is even able to find the source files when I'm debugging libraries. Rgs, Fred ----- Original Message ----- From: Keith E. Larson To: Frederic Terrettaz ; Sent: Wednesday, August 06, 2003 6:16 PM Subject: Re: [c3x] cannot find source files when debugging Hi Frederic My mistake, I thought you were having a compile problem. I know you probably never wanted to know what is inside a *.OUT file, but if you happen to examine one with a binary editor, you can peer inside and have a look. Interestingly, there is no directory information. If you think about this, with no directory information, the debugger needs to search for the files in some reasonable way. This version of CC(s) is, at least from the documentation I found, using the D_DIR and D_SRC environment variables to set up the search paths (do a GOOGLE search). BTW, I have not actually gone about seperating my source files to test this hypothesis. That is, the DOC I found seems to imply this. Note that if you have multiple sources, the search order is important! What a Pain In The Ass (PITA) that has been for me as I was writing the new VC33 DSK and debugger, which by the way has no heritage to CC! The present mechanism for the DSK debugger is to search the *.OUT files directory for sources. Yet another little thing to work on :-) Best regards, Keith Larson Tidbit Note: ASM30 can also track ASM source files by adding the -g command. It is *real* nice having the comments to look at. However, the resulting files tend to explode in size, so use sparingly. The TI Software Development Tools group added this after I one-upped them by adding ASM source tracking to the DSK some years ago. CL30 MAIN.C -g <- enable C/HLL tracking ASM30 OPTIMIZE.ASM -g <- enable ASM/HLL tracking LNK30 LINKIT.CMD -- At 03:56 PM 8/6/03 -0400, you wrote: Keith, The project/option/compiler/files/obj directory is filled. I use a other directory than the sources directories The project/option/compiler/includeSearchPath is not too big because in this case the compiler would complain about include. So there is something else causing the problem. After I load my program, the source of the main is not seen (can't do 'go to main', can't step in main.) But when I do view/mixed source asm, code composer is able to mix asm and source. Also I'm able to set a breakpoint, but when the breakpoint is reached, the asm is shown instead of the c source. Do you know by which way code composer know the path of the debug symbol file (.obj) Rgs, Fred ----- Original Message ----- From: Keith E. Larson To: frederic_terrettaz ; Sent: Tuesday, August 05, 2003 4:21 PM Subject: Re: [c3x] cannot find source files when debugging Hi Frederic I have never needed to extensively use multiple directories as you are. Still, I assume you are tinkering with the Project->Options pulldown menu that opens the "Build Options" dialog box. Here you will find a "Compiler" tab, and at the bottom a list of sub options under 'Catagory'. If you have missed this, select 'Files' and fill in the directories. On the other hand, if this is a bonafied CCs problem, it might be that trying to pass extremely long strings on the command line (CL30 blah blah blah blah...) is limited. The usual way of creating an extended search path is with the C_DIR (A_DIR etc...) environment variables. Also note that the OS itself might be getting you by not allocating enough environment space. You can see what is in the environment space by opening a DOS console box and executing the 'SET' command. This will list to the screen all of the environment variables including the path. The environment space allocation is usually set as an option to command.com in command.sys when the PC starts. Hope this helps, Best regards, Keith Larson ------------------------------ At 10:21 PM 8/4/03 -0000, you wrote: Hi, I'm using CC4.10.37. My sources files are located in 4 different directories and the project file is in an other directory. When I step into the code, CC is sometimes able to find the source for some files but not for all of them. Realy annoying ! Does anyone know the logic or limitation used by CC to find the source when debugging ? Thanks a lot! +-----------+ |Keith Larson | |Member Group Technical Staff | |Texas Instruments Incorporated | | | | 281-274-3288 | | | | www.micro.ti.com/~klarson | |-----------+ | TMS320C3x/C4x/VC33 Applications | | | | TMS320VC33 | | The lowest cost and lowest power 500 w/Mflop | | floating point DSP on the planet! | +-----------+ _____________________________________ Note: If you do a simple "reply" with your email client, only the author of this message will receive your answer. You need to do a "reply all" if you want your answer to be distributed to the entire group. _____________________________________ About this discussion group: To Join: Send an email to To Post: Send an email to To Leave: Send an email to Archives: http://groups.yahoo.com/group/c3x More Groups: http://www.dsprelated.com |
Reply by ●August 11, 20032003-08-11
Good news! Now hopefully I can get the new DSK debugger to do the same as I was working on this over the weekend! Best regards, Keith Larson - At 10:55 AM 8/11/03 -0400, you wrote: >Keith, > >I try to add to the environment variable D_SRC the path of the different directrories where my source files are located and it work!!! > >Code composer is even able to find the source files when I'm debugging libraries. > >Rgs, > >Fred > ----- Original Message ----- > From: Keith E. Larson > To: Frederic Terrettaz ; > Sent: Wednesday, August 06, 2003 6:16 PM > Subject: Re: [c3x] cannot find source files when debugging > Hi Frederic > > My mistake, I thought you were having a compile problem. > > I know you probably never wanted to know what is inside a *.OUT file, but if > you happen to examine one with a binary editor, you can peer inside and have > a look. Interestingly, there is no directory information. > > If you think about this, with no directory information, the debugger needs > to search for the files in some reasonable way. This version of CC(s) is, > at least from the documentation I found, using the D_DIR and D_SRC > environment variables to set up the search paths (do a GOOGLE search). BTW, > I have not actually gone about seperating my source files to test this > hypothesis. That is, the DOC I found seems to imply this. Note that if you > have multiple sources, the search order is important! > > What a Pain In The Ass (PITA) that has been for me as I was writing the new > VC33 DSK and debugger, which by the way has no heritage to CC! The present > mechanism for the DSK debugger is to search the *.OUT files directory for > sources. Yet another little thing to work on :-) > > Best regards, > Keith Larson > > Tidbit Note: > > ASM30 can also track ASM source files by adding the -g command. It is > *real* nice having the comments to look at. However, the resulting files > tend to explode in size, so use sparingly. The TI Software Development > Tools group added this after I one-upped them by adding ASM source tracking > to the DSK some years ago. > > CL30 MAIN.C -g <- enable C/HLL tracking > ASM30 OPTIMIZE.ASM -g <- enable ASM/HLL tracking > LNK30 LINKIT.CMD > -- > At 03:56 PM 8/6/03 -0400, you wrote: > Keith, > > The project/option/compiler/files/obj directory is filled. I use a other > directory than the sources directories > > The project/option/compiler/includeSearchPath is not too big because in this > case the compiler would complain about include. > > So there is something else causing the problem. > > After I load my program, the source of the main is not seen (can't do 'go to > main', can't step in main.) But when I do view/mixed source asm, code > composer is able to mix asm and source. Also I'm able to set a breakpoint, > but when the breakpoint is reached, the asm is shown instead of the c source. > > Do you know by which way code composer know the path of the debug symbol > file (.obj) > > Rgs, > > Fred > ----- Original Message ----- > From: Keith E. Larson > To: frederic_terrettaz ; > Sent: Tuesday, August 05, 2003 4:21 PM > Subject: Re: [c3x] cannot find source files when debugging > > Hi Frederic > > I have never needed to extensively use multiple directories as you are. > Still, I assume you are tinkering with the Project->Options pulldown menu > that opens the "Build Options" dialog box. Here you will find a "Compiler" > tab, and at the bottom a list of sub options under 'Catagory'. If you have > missed this, select 'Files' and fill in the directories. > > On the other hand, if this is a bonafied CCs problem, it might be that > trying to pass extremely long strings on the command line (CL30 blah blah > blah blah...) is limited. The usual way of creating an extended search path > is with the C_DIR (A_DIR etc...) environment variables. > > Also note that the OS itself might be getting you by not allocating enough > environment space. You can see what is in the environment space by opening > a DOS console box and executing the 'SET' command. This will list to the > screen all of the environment variables including the path. The environment > space allocation is usually set as an option to command.com in command.sys > when the PC starts. > > Hope this helps, > Best regards, > Keith Larson > ------------------------------ > At 10:21 PM 8/4/03 -0000, you wrote: > Hi, > I'm using CC4.10.37. > > My sources files are located in 4 different directories and the project file > is in an other directory. > > When I step into the code, CC is sometimes able to find the source for some > files but not for all of them. Realy annoying ! > > Does anyone know the logic or limitation used by CC to find the source when > debugging ? > > Thanks a lot! > +-----------+ > |Keith Larson | > |Member Group Technical Staff | > |Texas Instruments Incorporated | > | | > | 281-274-3288 | > | | > | www.micro.ti.com/~klarson | > |-----------+ > | TMS320C3x/C4x/VC33 Applications | > | | > | TMS320VC33 | > | The lowest cost and lowest power 500 w/Mflop | > | floating point DSP on the planet! | > +-----------+ > > > _____________________________________ > Note: If you do a simple "reply" with your email client, only the author of this message will receive your answer. You need to do a "reply all" if you want your answer to be distributed to the entire group. > > _____________________________________ > About this discussion group: > > To Join: Send an email to > > To Post: Send an email to > > To Leave: Send an email to > > Archives: http://groups.yahoo.com/group/c3x > > More Groups: http://www.dsprelated.com > ">http://docs.yahoo.com/info/terms/">Yahoo! Terms of Service</A>.</TT> ><BR></BLOCKQUOTE></BODY></HTML> > +-----------+ |Keith Larson | |Member Group Technical Staff | |Texas Instruments Incorporated | | | | 281-274-3288 | | | | www.micro.ti.com/~klarson | |-----------+ | TMS320C3x/C4x/VC33 Applications | | | | TMS320VC33 | | The lowest cost and lowest power 500 w/Mflop | | floating point DSP on the planet! | +-----------+ |
Reply by ●August 13, 20032003-08-13
Keith,
Ti has raised the bug #SDSsq16740 about this problem. It is called " source level debugging does not work if you use sub directories" The status of this bug is "no plans to fix".
Since the solution to this problem is easy, you may add a workaround to the bug description and may add this to the FAQ of Code composer 4.10. It will help a lot of people.
BTW do you know where this FAQ is located? Rgd,
Fred
|
Reply by ●August 13, 20032003-08-13
Hi Fred Actually 'the plan' that is being promoted is to move to CC(s) 2.x, in which case this problem goes away. However, the usual result is that yet others arise and being an early adopter has its drawbacks! Corporate America's financial dilema is not helping either! When I figured out this problem I more or less pieced it together from another Code Composer installation document (previous C54x CC document) and what I knew about the underlying tool strategies. BTW, if you were not aware of this, Code Composer 4.10 is Code Composer Studio 1.x, minus the DSP BIOS and RTDX stuff. Even if it is documented someplace, and it probably is, it sure is a paint to find! So I am not surprised that the PIC raised this as a 'bug'. As for an FAQ, your best bet is the search engine at DSP Village, or use Google. On a number of instanced we have found Google better at finding TI documents on the TI web than the search engine at TI, which interestingly is I am told also based on a Google search engine... With some obvious some room to improve. Also... As mentioned before, this has spurred me forward into adding a debugger path search algorithm to the new DSK tools that is not based on an environment variable. I need to test and debug this a bit before posting it. Hope this helps, Keith Larson PS: Any futher replies will be delayed for 3 days of vacation starting tommorrow PPS: If anyone has picked up a VC33 DSK (C31 DSK as well), I am also interested in this kind of feedback ===================================================== At 10:05 AM 8/13/03 -0400, you wrote: >Keith, > >Ti has raised the bug #SDSsq16740 about this problem. It is called " source level debugging does not work if you use sub directories" > >The status of this bug is "no plans to fix". > >Since the solution to this problem is easy, you may add a workaround to the bug description and may add this to the FAQ of Code composer 4.10. It will help a lot of people. > >BTW do you know where this FAQ is located? > >Rgd, >Fred > ----- Original Message ----- > From: Keith E. Larson > To: Frederic Terrettaz ; > Sent: Monday, August 11, 2003 12:04 PM > Subject: Re: [c3x] cannot find source files when debugging > Good news! > > Now hopefully I can get the new DSK debugger to do the same as I was working > on this over the weekend! > > Best regards, > Keith Larson > +-----------+ |Keith Larson | |Member Group Technical Staff | |Texas Instruments Incorporated | | | | 281-274-3288 | | | | www.micro.ti.com/~klarson | |-----------+ | TMS320C3x/C4x/VC33 Applications | | | | TMS320VC33 | | The lowest cost and lowest power 500 w/Mflop | | floating point DSP on the planet! | +-----------+ |