Technical discussions about the TI C6000 DSPs (including the c62x, c64x and c67x DSPs).
|
Hi C6x i have a very strange problem i allocated memory dinamicaly with malloc it is ok at start but during the running of the program suddenly that address chage and pointed to another location and the program act strangely please help me in tyhis problem yaser attar izzy |
|
|
|
If you are using BIOS you should use MEM_alloc(). I had problems when I used malloc along with MEM_alloc(). You have to be careful when using the BIOS configuration, which mainly sets up MEM_alloc(). Anyway, MEM_alloc() is more powerful in terms of allowing proper memory alignment and debugging. /khalid |
|
Hi, I think more than malloc, your program has potential bugs. I dont think there are any problems using malloc or MEM_alloc or MEM_calloc. Kindly check if you are not modifying your pointer inside the program. Else check your heap size. Have you put a check after malloc to crosscheck if the memory has been successfully allocated or not ? If not, put a check. I guess it is more a case that you are modifying your pointer rather than a problem with malloc. Thanks and Regards, Ganesh ----- Original Message ----- From: Yasser Attarizzi To: Sent: Saturday, June 21, 2003 9:46 PM Subject: [c6x] malloc Hi C6x i have a very strange problem i allocated memory dinamicaly with malloc it is ok at start but during the running of the program suddenly that address chage and pointed to another location and the program act strangely please help me in tyhis problem yaser attar izzy _____________________________________ |