From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/10382 Path: news.gmane.org!.POSTED!not-for-mail From: Sebastian Gottschall Newsgroups: gmane.linux.lib.musl.general Subject: Re: musl gcc compiler generating "udiv" on a A9mp ARM core... Date: Mon, 15 Aug 2016 16:24:58 +0200 Message-ID: <2c876ce9-1b3d-42c7-bbae-c5c302b41f1a@dd-wrt.com> References: Reply-To: musl@lists.openwall.com NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1471271126 7302 195.159.176.226 (15 Aug 2016 14:25:26 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 15 Aug 2016 14:25:26 +0000 (UTC) User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 To: musl@lists.openwall.com, Ovi Nastai Original-X-From: musl-return-10395-gllmg-musl=m.gmane.org@lists.openwall.com Mon Aug 15 16:25:18 2016 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.84_2) (envelope-from ) id 1bZIpK-0001S0-59 for gllmg-musl@m.gmane.org; Mon, 15 Aug 2016 16:25:18 +0200 Original-Received: (qmail 3863 invoked by uid 550); 15 Aug 2016 14:25:17 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 3845 invoked from network); 15 Aug 2016 14:25:16 -0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=dd-wrt.com; s=mikd; h=Subject:Content-Transfer-Encoding:Content-Type:In-Reply-To:MIME-Version:Date:Message-ID:From:References:To; bh=lvcESqlTUMfXTJBwcZxxvQJovbGBeJD+ksE2AdBgYjA=; b=bLSwPk5x9WFFbpfEU5y7Mbnpblpfr6OEeW+fElwLauAzIGAL2vipmZtC9DbBSAersxWa6/o52/8VdOmw2qKFOydETbwzFwacruUbxqbRsWwQCztSjjzMU4mD4RUq5wSeD52z8tqSCGKl7MQkNuz2p24fxajDgKx1i+XjcxDntrA=; In-Reply-To: X-SA-Exim-Connect-IP: 93.195.17.135 X-SA-Exim-Mail-From: s.gottschall@dd-wrt.com X-SA-Exim-Version: 4.2.1 (built Thu, 26 May 2011 15:22:33 +0200) X-SA-Exim-Scanned: Yes (on webmail.newmedia-net.de) X-NMN-MailScanner-Information: Please contact the ISP for more information X-NMN-MailScanner-ID: 1bZIp0-0003p2-SK X-NMN-MailScanner: Found to be clean X-NMN-MailScanner-From: s.gottschall@dd-wrt.com X-Received: from [93.195.17.135] (helo=[172.29.0.144]) by webmail.newmedia-net.de with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.72) (envelope-from ) id 1bZIp0-0003p2-SK; Mon, 15 Aug 2016 16:24:59 +0200 Xref: news.gmane.org gmane.linux.lib.musl.general:10382 Archived-At: 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