diff mbox

is ARMv4T deprecated?

Message ID 553007CF.6070906@meta.ua
State Superseded
Headers show

Commit Message

Sergiy Kibrik April 16, 2015, 7:04 p.m. UTC
On 4/16/15 12:43 AM, Bernhard Reutner-Fischer wrote:
>>> >> Please send me your
>>> >> grep "memcpy\.o[sS]* " log.do_compile
>>> >> The file should be somewhere around your
>>> >> tmp-uclibc/work/armv4t-oe-linux-uclibceabi/uclibc/0.9.33+gitAUTOINC+*/temp/log.do_compile
>> >
>> > here it goes: http://pastebin.com/VGqf31ac
> arm-poky-linux-uclibceabi-gcc -march=armv4t -marm -mthumb-interwork
> -msoft-float -mlittle-endian -mthumb
> 
> I see no notion of a tune?
> 
> IIRC armv4t defaulted to arm7TDMI. Given that OE usually does not
> configure for a default CPU (AFAICS) you have to pass a proper tune.
> 
> My 920t build used:
> arm-oe-linux-uclibceabi-gcc -march=armv4t -mthumb  -mthumb-interwork
> -O2 -mtune=arm920t
> 
> in your local.conf, try:
> FULL_OPTIMIZATION = "-O2 -mtune=arm920t"
> ARM_INSTRUCTION_SET := "thumb"
> 
> maybe you need some additional settings like DEFAULTTUNE TUNE_ARCH
> TUNE_PKGARCH that you certainly use already.
> 

I tried -mtune=arm920t some time ago once, but it didn't help.

I changed return [from Thumb routine] code, and it did the trick, now
busybox and couple of utilities seems to be working (yet I didn't run
uclibc tests):



What do you think of such fix?

--
regards,
Sergey

Comments

Bernhard Reutner-Fischer April 16, 2015, 8:41 p.m. UTC | #1
On April 16, 2015 9:04:47 PM GMT+02:00, Sergiy Kibrik <sakib@meta.ua> wrote:
>On 4/16/15 12:43 AM, Bernhard Reutner-Fischer wrote:
>>>> >> Please send me your
>>>> >> grep "memcpy\.o[sS]* " log.do_compile
>>>> >> The file should be somewhere around your
>>>> >>
>tmp-uclibc/work/armv4t-oe-linux-uclibceabi/uclibc/0.9.33+gitAUTOINC+*/temp/log.do_compile
>>> >
>>> > here it goes: http://pastebin.com/VGqf31ac
>> arm-poky-linux-uclibceabi-gcc -march=armv4t -marm -mthumb-interwork
>> -msoft-float -mlittle-endian -mthumb
>> 
>> I see no notion of a tune?
>> 
>> IIRC armv4t defaulted to arm7TDMI. Given that OE usually does not
>> configure for a default CPU (AFAICS) you have to pass a proper tune.
>> 
>> My 920t build used:
>> arm-oe-linux-uclibceabi-gcc -march=armv4t -mthumb  -mthumb-interwork
>> -O2 -mtune=arm920t
>> 
>> in your local.conf, try:
>> FULL_OPTIMIZATION = "-O2 -mtune=arm920t"
>> ARM_INSTRUCTION_SET := "thumb"
>> 
>> maybe you need some additional settings like DEFAULTTUNE TUNE_ARCH
>> TUNE_PKGARCH that you certainly use already.
>> 
>
>I tried -mtune=arm920t some time ago once, but it didn't help.
>
>I changed return [from Thumb routine] code, and it did the trick, now
>busybox and couple of utilities seems to be working (yet I didn't run
>uclibc tests):
>
>diff --git a/libc/sysdeps/linux/arm/bits/arm_asm.h
>b/libc/sysdeps/linux/arm/bits/arm_asm.h
>index 04664b3..78dc6f0 100644
>--- a/libc/sysdeps/linux/arm/bits/arm_asm.h
>+++ b/libc/sysdeps/linux/arm/bits/arm_asm.h
>@@ -13,12 +13,8 @@
>    unified assembly syntax.  */
> #define IT(t, cond)
> /* Code to return from a thumb function stub.  */
>-#ifdef __ARM_ARCH_4T__
>-#define POP_RET pop	{r2, pc}
>-#else
> #define POP_RET pop	{r2, r3}; bx	r3
> #endif
>-#endif
>
> #if defined(__ARM_ARCH_6M__)
> /* Force arm mode to flush out errors on M profile cores.  */
>
>
>What do you think of such fix?

Should probably take USE_BX into account..
Other than that and a signed-off-by sure, whatever works for you!

Many TIA,
Bernhard Reutner-Fischer April 17, 2015, 12:32 p.m. UTC | #2
>>--- a/libc/sysdeps/linux/arm/bits/arm_asm.h
>>+++ b/libc/sysdeps/linux/arm/bits/arm_asm.h
>>@@ -13,12 +13,8 @@
>>    unified assembly syntax.  */
>> #define IT(t, cond)
>> /* Code to return from a thumb function stub.  */
>>-#ifdef __ARM_ARCH_4T__
>>-#define POP_RET pop   {r2, pc}
>>-#else
>> #define POP_RET pop   {r2, r3}; bx    r3
>> #endif
>>-#endif
>>
>> #if defined(__ARM_ARCH_6M__)
>> /* Force arm mode to flush out errors on M profile cores.  */
>>
>>
>>What do you think of such fix?
>
> Should probably take USE_BX into account..
> Other than that and a signed-off-by sure, whatever works for you!

So i read some documents yesterday night and this lead me to think
that the condition is just inverted?
Shouldn't it read more like:

 /* Code to return from a thumb function stub.  */
#if defined __ARM_ARCH_4T__ /* && defined __THUMB_INTERWORK__ */
# define POP_RET pop   {r2, r3}; bx    r3
#else
# define POP_RET pop   {r2, pc}
#endif

thanks,
>
> Many TIA,
>
>
diff mbox

Patch

diff --git a/libc/sysdeps/linux/arm/bits/arm_asm.h
b/libc/sysdeps/linux/arm/bits/arm_asm.h
index 04664b3..78dc6f0 100644
--- a/libc/sysdeps/linux/arm/bits/arm_asm.h
+++ b/libc/sysdeps/linux/arm/bits/arm_asm.h
@@ -13,12 +13,8 @@ 
    unified assembly syntax.  */
 #define IT(t, cond)
 /* Code to return from a thumb function stub.  */
-#ifdef __ARM_ARCH_4T__
-#define POP_RET pop	{r2, pc}
-#else
 #define POP_RET pop	{r2, r3}; bx	r3
 #endif
-#endif

 #if defined(__ARM_ARCH_6M__)
 /* Force arm mode to flush out errors on M profile cores.  */