Topic : malloc() in thumb mode

Forum : ARM

Original Post
Post Information Post
August 25, 2009 - 11:22am
Guest

Hi,

For code size reduction I swithced my STR7 application to thumb mode. I discovered that in thumb mode a call to malloc() returns a datapointer that appears to be located on the usrstack (somewhere between _susrstack and _eusrstack. Is this correct? Since applying thumb mode, my application crashes and I suspect the malloc() function to be the cause. Should malloc not try to obtain a datpointer from the heap?

regards
Kris

Replies
Post Information Post
+1
0
-1
August 27, 2009 - 4:25pm
Guest

Hi Signum

We indeed have been working on the way our library were implemented.
Some known issues have been corrected and I guess this should help in your issue.

If you can send to a project which reproduce this issue
I can confirm you this point.

Regards,
Matloub

+1
0
-1
August 31, 2009 - 2:59pm
Guest

Hi Matloub,

Thanks for your reply. Does it mean I can install a new STR7 library? Where can I get this library? Can you tell what exactly may be the problem(s) when switching from non-thumb to thumb mode? Is there a ist of known problems I could consult regarding this issue?
If you could tell me how create an attachment from here or give me an alternative mail address, I will be glad to send my project to you (although I'm not quite sure if it will help you: its written for a dedicated hardware and it's rather big so it might take a while to figure things out)

regards,
Kris

+1
0
-1
September 2, 2009 - 4:55pm
Guest

Hi

You are right its better that you wait for the release of RKit-ARM upcoming.
Without the hardware it mightbe difficult for us to verify if our modification correct your issue.

The library I was talking about is not STR7 library but other libraries such as printf etc.....

Regards,
Matloub

+1
0
-1
September 2, 2009 - 5:05pm
Guest

Is it possible to send me the modified libs so I can test it in advance?

regards
Kris

+1
0
-1
September 10, 2009 - 5:31pm
Guest

Hi

The file are avaible since yesterday.
Sorry I could not send you the file before.

Best regards,
Matloub

+1
0
-1
September 11, 2009 - 3:32pm
Guest

Hi,

I've installed the latest version of Rkit and Ride and built the entire application ans STR7 libs again. The newly generated thumb-version of the code appears to be working fine. Thank you very much for your help

regards
Kris