DSPRelated.com

Interface assembler/C

Started by Bernhard 'Gustl' Bauer in TMS320c6x14 years ago 1 reply

Hi, is there a document that states the use of registers when calling a assembler function from C. I know that B3 is the return address; B15...

Hi, is there a document that states the use of registers when calling a assembler function from C. I know that B3 is the return address; B15 is SP; A4, B4, A6, B6, ... are the arguments. I checked the assembler code of a lib function. There was B10 saved to the stack. I wonder what is located in B10, and if there are other registers I must preserve. TIA Gustl _______________...


a profiling problem

Started by zhoux1977 in TMS320c6x18 years ago

Hi, everyone, I encoutered a error dialog when I profile my H.264 decoder under CCS3.2 which is configured as EVMDM6446 cycle accurate...

Hi, everyone, I encoutered a error dialog when I profile my H.264 decoder under CCS3.2 which is configured as EVMDM6446 cycle accurate simulator, As regarding to my observation, only if i enable too many profiling events, the below error dialog will display: "Unexpected Fatal error encountered which may have been caused by a stack overflow, out of memory condition, or access violation...


Calling Assembly within assembly

Started by wilbur in TMS320c6x17 years ago 11 replies

Hi All, What precautions does one need to take when calling an assembly function within the scope of another assembly function in linear...

Hi All, What precautions does one need to take when calling an assembly function within the scope of another assembly function in linear assembly. Does the compiler take care of this? or do I have to store the values of the registers that I require?. Another question I have is...do I need to align the stack pointer in anyway for C64xx when I enter and exit the assembly function? My da...


problems with cmd file

Started by Khurram Shehzad in TMS320c6x19 years ago 1 reply

hi i have written code and i want to put some part of it in internal memory(L2) of c6711 so that it can run fast is ther any way . more...

hi i have written code and i want to put some part of it in internal memory(L2) of c6711 so that it can run fast is ther any way . more over i want to put stack section of my code in the internal memory which is less than 64 k . i have to change linker command file of my proj according to it or i have to use pragma directive ?more over i m using dsp


Problems calling functions in CCS

Started by vijay chauhan in TMS320c6x20 years ago 4 replies

Hello every 1, I am calling certain functions from main and also passing few arguements to these functions. But the values of...

Hello every 1, I am calling certain functions from main and also passing few arguements to these functions. But the values of these arguements are gettting changed as soon as i enter the function . I increased the stack size but still it doesnt work. I am using CCS


Re: [Fwd: RE: [c54x] REg: inline assembly]

Started by Jeff Brower in TMS320c6x18 years ago

Giridhar- > Yes I used the space but the problem is "val" is not a register its a > variable in C file. > int val; > asm(" swap2 val1,...

Giridhar- > Yes I used the space but the problem is "val" is not a register its a > variable in C file. > int val; > asm(" swap2 val1, val2"); > now this gives error. > > Then inline asm is of limited use! You can access C variables using 64x inline asm, but you have to be careful. The C vars should not be on the stack and you should test it first with all optimizations turned off


RE: One Qn regding Speech Codecs

Started by Anand Pradhan in TMS320c6x18 years ago

Thanks for prompt replies, Mike and Suresh ! Here are some things more clarified ! I am presently using c6416 DSP, and there is only one...

Thanks for prompt replies, Mike and Suresh ! Here are some things more clarified ! I am presently using c6416 DSP, and there is only one channel of EVRC codec running ie EVRC Encode - EVRC Decode The optimized code is smaller than the unoptimized code. There is neither a warning that code is having stack overflow problem whenever it runs. Will you please explain, Mike, as what to...


Re: Interfacing C & Assembly

Started by Andrew V. Nesterov in TMS320c6x23 years ago 1 reply
CCS

Passing parameters to an assembly function is described in the SPRU187 C6x Optimizing C Compiler: Chapter Runtime Environment: ...

Passing parameters to an assembly function is described in the SPRU187 C6x Optimizing C Compiler: Chapter Runtime Environment: C System Stack, Register Conventions, Function Structure and Calling Conventions, Interfacing C with Assembly Language All th


ERROR: Parallel branch is illegal in linear assembly

Started by Bernhard 'Gustl' Bauer in TMS320c6x14 years ago 1 reply

Hi, I copied this code snipped from a asm file to a sa file and get the above error: STW .D2 B10,*SP--[1] ; saving B10...

Hi, I copied this code snipped from a asm file to a sa file and get the above error: STW .D2 B10,*SP--[1] ; saving B10 on stack || MV .L1X B6,A8 ; move index to A8 || MV .L2X A8,B6 ; move csize to B6 || B .S1 NO_INT ; protect from ints I wonder whats wrong? Must I rename my sa to asm? Or do I need a...


help for linear assembly

Started by goelhss in TMS320c6x21 years ago

Hi All, I am new to assembly programming in C62x and I m facing a problem. I have to convert a "C" function into linear...

Hi All, I am new to assembly programming in C62x and I m facing a problem. I have to convert a "C" function into linear assembly. This function declares and uses a 1-D array and a 2-D array, which I would want to declare on stack. I gathered some


EMAC configuration problem

Started by presciutti_dgl2k in TMS320c6x17 years ago

Hi all, I've the following problems with EMAC module of 6412 DSP: The EMAC peripheral is connect to 2 PHYs ( Intel LXT971A ) and the EMAC...

Hi all, I've the following problems with EMAC module of 6412 DSP: The EMAC peripheral is connect to 2 PHYs ( Intel LXT971A ) and the EMAC goal is just receive all incoming Ethernet packets from both PHYs. I use a TI TCP/IP stack and I have the Ethernet packet driver provided in the NDK, in particularly I can manage the source file called "llpacket.c" and "dm642.c". At this moments, EMA...


EMAC configuration problem

Started by presciutti_dgl2k in TMS320c6x17 years ago

Hi all, I've the following problems with EMAC module of 6412 DSP: The EMAC peripheral is connect to 2 PHYs ( Intel LXT971A ) and the EMAC...

Hi all, I've the following problems with EMAC module of 6412 DSP: The EMAC peripheral is connect to 2 PHYs ( Intel LXT971A ) and the EMAC goal is just receive all incoming Ethernet packets from both PHYs. I use a TI TCP/IP stack and I have the Ethernet packet driver provided in the NDK, in particularly I can manage the source file called "llpacket.c" and "dm642.c". At this moments, EMA...


Do I really need fancy power sequencing ICs to power C6xxx circuits?

Started by jeanpierrepoulin in TMS320c6x19 years ago

Hi all! I'm constructing a C6xxx-based circuit for which low-cost is the top priority. (still debating between the $9.66 C6204...

Hi all! I'm constructing a C6xxx-based circuit for which low-cost is the top priority. (still debating between the $9.66 C6204 and the $20 C6410 for the DSP...) Looking into my stack of Spectrum Digital reference designs, TI DSPs are typically booted up with fancy power sequencing chips... (Which, by uncanny coincidence, usua


DM648 Ethernet cpsw_MDIO_FindingState: Timed Out looking for a Phy!

Started by tian...@gmail.com in TMS320c6x13 years ago 6 replies

hi guys. I have a pb. I tried the DM648 ethernet demo,but it seems there is sth wrong...

hi guys. I have a pb. I tried the DM648 ethernet demo,but it seems there is sth wrong . C:\dvsdk_1_11_00_00_DM648\ndk_1_92_00_22_eval\packages\ti\ndk\example\network\cfgdemo\evmdm648 When i compiled the project,downloaded the out file ,and run the cpu.It prints a lot. TCP/IP Stack Client Configuration Demo 220 bytes required for save Using MAC Address: 3c-2d-b7-27-b7-c6 cpsw_MDIO...


Heap, Stack, Global, and unions

Started by William C Bonner in TMS320c6x17 years ago

How efficient is the heap memory management in TI's libraries for the 6713 processor? How much risk do I run into with a few allocations /...

How efficient is the heap memory management in TI's libraries for the 6713 processor? How much risk do I run into with a few allocations / deallocations of large memory blocks that I'll fragment the memory and not be able to allocate large blocks of memory? I'm currently not explicitly using the heap, but I am using a bunch of system calls for sprintf() sscanf() and various math func...


memory map prevented read of target memory specified

Started by joshy jose in TMS320c6x17 years ago

hai friends, i am getting a new error which is not familier for me, that is memory map prevented read of target memory specified this...

hai friends, i am getting a new error which is not familier for me, that is memory map prevented read of target memory specified this cause program to stuck in some places where user defiend variable is accesed why its happening i guess it is something with , stack or heap , or something with .cmd file please help me in solving the problem -- regards, Joshy m....


Memory allocation problems

Started by Giovanni in TMS320c6x19 years ago 2 replies

Hello evrybody I am using an EVM board with C6701 processor and I have some problems with memory allocation: Here is my cmd...

Hello evrybody I am using an EVM board with C6701 processor and I have some problems with memory allocation: Here is my cmd file /*** CMD file settings ***/ -c -heap 0xA000 -stack 0xB000 -m memory.txt MEMORY { PME


Porting UNIX design to DSP

Started by tim....@ultra-ems.com in TMS320c6x16 years ago 3 replies

Hello, I am in the process of determining if our Unix based (QNX) RTOS application can be migrated over to the DSP platform. My major...

Hello, I am in the process of determining if our Unix based (QNX) RTOS application can be migrated over to the DSP platform. My major concern is if we will have high level support that we currently use in our C code. Will the DSP RT Kernal provided by TI, support: POSIX / ANSI compliance? Is there a high level ethernet stack driver, that allows function calls that will not require d...


Calling C function From Assembly

Started by bharath in TMS320c6x18 years ago 3 replies

Hi all, I am calling C function from Assembly, I strore the return address in B3 and then i call the assembly function using call...

Hi all, I am calling C function from Assembly, I strore the return address in B3 and then i call the assembly function using call routine. I want to know wether i have to save the registers from (A0 to A9) (A16-A31) and (B0 to B9)(B16-B31) on stack before calling ,and pop those values after returning back rom C?. what others things i should takecare when calling C from Assembly. ...


Memory Allocation :Help

Started by deepti_d_r in TMS320c6x17 years ago 1 reply

Hi all I am working on C6416 DSK Simulator. I am trying to port a code written in C, developed for video coding (H.264 based ) of frame size...

Hi all I am working on C6416 DSK Simulator. I am trying to port a code written in C, developed for video coding (H.264 based ) of frame size qcif (176x144). Right now am trying to port only the code for a single frame as a starting. I am inputing the frame as *.h file. My problem is after coding a few blocks of the input image, it is giving error "May be stack overflow or memory...