[RFA/libgloss/arm] Handle zero heap base from semihosting

Matthew Gretton-Dann matthew.gretton-dann@arm.com
Tue Sep 27 08:50:00 GMT 2011


Hi,

The attached patch fixes an issue in libgloss' heap setup when using 
semihosting.

In particular the semihosting SYS_HEAPINFO call can return 0 for the 
heap_base, and this means that the C library is to start the heap at the 
end of the image.

This behaviour is documented here:

http://infocenter.arm.com/help/topic/com.arm.doc.dui0471-/Bacbefaa.html

The attached patch handles this case.

Please can someone review.

Thanks,

Matt

libgloss/ChangeLog:

2011-09-02  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>

         * arm/crt0.s: support 0 heap base response from semihosting.

Thanks,

Matt

-- 
Matthew Gretton-Dann
Principal Engineer, PD Software - Tools, ARM Ltd
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 1109-libgloss-heap-init.txt
URL: <http://sourceware.org/pipermail/newlib/attachments/20110927/9b96782c/attachment.txt>


More information about the Newlib mailing list