PATCH: Support armv6-m in libgloss

Bin Cheng bin.cheng@arm.com
Tue Jun 28 15:45:00 GMT 2011


Hi,
The attached patch supports armv6-m in libgloss/arm, which is thumb only
arch and have not been supported in libgloss yet.
This patch makes following changes:

-   arm unified assembly language(UAL) is now used globally in libgloss,
rather than in thumb2 startup codes only;
-   use flag setting variant of some instructions, this is required by
rewriting pre-UAL to UAL codes;
    Though it might change the behavior of some of these instructions, it
won't change program behavior, since all instructions depend on flags have
its own direct preceding flag setting instructions.
-   change in functionality for AngelSWI_Reason_HeapInfo semihosting, we no
longer set sp/sl if values loaded are ZERO. Please refer to comments at line
127 of this patch and section 8.3.9 of ARM document
"DUI0203J_rvct_developer_guide" for more information;
-   fix a semihosting bug in crt0.S involving armv6-m/armv7-m, please see
line 106-117 of this patch, and go to website
http://sources.redhat.com/ml/newlib/2011/msg00240.html and
http://sources.redhat.com/ml/newlib/2011/msg00257.html for more discussions;


I have run arm-none-eabi-gcc/g++/gdb "make check" on
arm9/arm9_thumb/cortex-m3, the results seems sane. Also I ran some
benchmarks on cortex-m0/m3 boards successfully.

Please review this patch and apply it if OK.


2011-06-24  Chengbin  <bin.cheng@arm.com>

libgloss/
               * arm/crt0.S: Support armv6-m processors in libgloss.
               * arm/swi.h: Likewise.
               * arm/trap.S: Likewise.
               * arm/redboot-crt0.S: Likewise.
               * arm/linux-crt0.c: Likewise.
               * arm/arm.h: New.


Thanks-chengbin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: support-armv6m-in-libgloss_20110624.patch
Type: application/octet-stream
Size: 13429 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/newlib/attachments/20110628/d4b030d8/attachment.obj>


More information about the Newlib mailing list