mailing list of musl libc
 help / color / mirror / code / Atom feed
* musl gcc compiler generating "udiv" on a A9mp ARM core...
@ 2016-08-15 13:51 Ovi Nastai
  2016-08-15 14:24 ` Sebastian Gottschall
  0 siblings, 1 reply; 2+ messages in thread
From: Ovi Nastai @ 2016-08-15 13:51 UTC (permalink / raw)
  To: musl

[-- Attachment #1: Type: text/plain, Size: 1239 bytes --]

Hi,

I have  an A9mp based SoC.

My tool generates the “udiv” opcode, that it is not supported by the A9mp.
I also see the “__aeabi_uidiv” at times.

I need to have the tool generating exclusively “__aeabi_uidiv”, on my A9mp
system.



This is the tool’s version:

…

[onastai@bldsrv-ott-03 user]$
../../../../../toolchains/gcc-arm-tzos-musl-4_8-2015q1/bin/arm-tzos-musl-gcc
--version

arm-tzos-musl-gcc (GNU Tools for ARM Embedded Processors) 4.8.4 20140725
(release) [ARM/embedded-4_8-branch revision 213147]

Copyright (C) 2013 Free Software Foundation, Inc.

…

This is the command line (to show the flags):

…

../../../../../toolchains/gcc-arm-tzos-musl-4_8-2015q1/bin/arm-tzos-musl-gcc
-I. -I../../../../kernel/api -MD -MP -mcpu=cortex-a9 -mtune=mpcore
-mfpu=vfpv3 -D__TZOS__ -O2 -g -Wall -Werror  -std=gnu99 -D_POSIX_SOURCE -c
signals_tests.c -o bin/signals_tests.o

../../../../../toolchains/gcc-arm-tzos-musl-4_8-2015q1/bin/arm-tzos-musl-g++
bin/signals_tests.o   -o user.elf

…



Question: are there any flags to instruct the tool to NOT generate the
“udiv” opcodes, and replace them with “sw division” (i.e. “__aeabi_uidiv) ?





Tnx,

Ovi

[-- Attachment #2: Type: text/html, Size: 2798 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: musl gcc compiler generating "udiv" on a A9mp ARM core...
  2016-08-15 13:51 musl gcc compiler generating "udiv" on a A9mp ARM core Ovi Nastai
@ 2016-08-15 14:24 ` Sebastian Gottschall
  0 siblings, 0 replies; 2+ messages in thread
From: Sebastian Gottschall @ 2016-08-15 14:24 UTC (permalink / raw)
  To: musl, Ovi Nastai

one hint. your compile flags are likelly wrong. mpcore is not cortex-a9
try -mcpu=armv6k
but would be better if you can tell me the exact cpu brand and name
if its the broadcom northstar cortext a9 cpu, the following flags are 
working good.
-march=armv7-a -mcpu=cortex-a9 -mtune=cortex-a9 -msoft-float since the 
northstar cpu has no fpu support, vfpv3 would be wrong

consider always that the musl libc library needs to be compiled using 
the same flags, otherwise it will break again

Sebastian



Am 15.08.2016 um 15:51 schrieb Ovi Nastai:
>
> Hi,
>
> I have  an A9mp based SoC.
>
> My tool generates the “udiv” opcode, that it is not supported by the 
> A9mp. I also see the “__aeabi_uidiv” at times.
>
> I need to have the tool generating exclusively “__aeabi_uidiv”, on my 
> A9mp system.
>
> This is the tool’s version:
>
> …
>
> [onastai@bldsrv-ott-03 user]$ 
> ../../../../../toolchains/gcc-arm-tzos-musl-4_8-2015q1/bin/arm-tzos-musl-gcc 
> --version
>
> arm-tzos-musl-gcc (GNU Tools for ARM Embedded Processors) 4.8.4 
> 20140725 (release) [ARM/embedded-4_8-branch revision 213147]
>
> Copyright (C) 2013 Free Software Foundation, Inc.
>
> …
>
> This is the command line (to show the flags):
>
> …
>
> ../../../../../toolchains/gcc-arm-tzos-musl-4_8-2015q1/bin/arm-tzos-musl-gcc 
> -I. -I../../../../kernel/api -MD -MP -mcpu=cortex-a9 -mtune=mpcore 
> -mfpu=vfpv3 -D__TZOS__ -O2 -g -Wall -Werror -std=gnu99 -D_POSIX_SOURCE 
> -c signals_tests.c -o bin/signals_tests.o
>
> ../../../../../toolchains/gcc-arm-tzos-musl-4_8-2015q1/bin/arm-tzos-musl-g++ 
> bin/signals_tests.o   -o user.elf
>
> …
>
> Question: are there any flags to instruct the tool to NOT generate the 
> “udiv” opcodes, and replace them with “sw division” (i.e. 
> “__aeabi_uidiv) ?
>
> Tnx,
>
> Ovi
>


-- 
Mit freundlichen Grüssen / Regards

Sebastian Gottschall / CTO

NewMedia-NET GmbH - DD-WRT
Firmensitz:  Berliner Ring 101, 64625 Bensheim
Registergericht: Amtsgericht Darmstadt, HRB 25473
Geschäftsführer: Peter Steinhäuser, Christian Scheele
http://www.dd-wrt.com
email: s.gottschall@dd-wrt.com
Tel.: +496251-582650 / Fax: +496251-5826565



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-08-15 14:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-15 13:51 musl gcc compiler generating "udiv" on a A9mp ARM core Ovi Nastai
2016-08-15 14:24 ` Sebastian Gottschall

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).