From owner-freebsd-mips@freebsd.org Thu Nov 24 19:01:29 2016 Return-Path: Delivered-To: freebsd-mips@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A1F70C532CB for ; Thu, 24 Nov 2016 19:01:29 +0000 (UTC) (envelope-from mizhka@gmail.com) Received: from mail-wm0-x229.google.com (mail-wm0-x229.google.com [IPv6:2a00:1450:400c:c09::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 33148E36 for ; Thu, 24 Nov 2016 19:01:29 +0000 (UTC) (envelope-from mizhka@gmail.com) Received: by mail-wm0-x229.google.com with SMTP id a197so123331106wmd.0 for ; Thu, 24 Nov 2016 11:01:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=Kp1+FJhmtBQKgZO7FOkaTXBblSOKYDdkku0VELrZkcw=; b=vm4dM1M+ri+G2EvTEkBYTbcSxGPTtqPO/yPRfGLVAVguPok3R0+bgCex3huaLz3wH9 DKv0rQm4B4on3KsykUPEmSLAO5ztJyz5fezEgI0zOncPmyCf14eUifdZyM/4h2d4OU3y 2zDezKapK2jLU2XeGH3qFCYKwFD8RA9avgX+2OSEinHCDgzhl4JrhZ7PG8YzyBnuJbhf zYwiXyHqfbx7eBSXd15wyHviopGJiX3mg4XOb+PC+7mzFZzTs9bTEkhUTUj6iqVJ0Mch J1CBRr45/fgUs9zR2ANFhtl7HONBnTknp+A5ACtqOBICeEtAMOgy3Il1PB8c9AH4M69p w8WQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=Kp1+FJhmtBQKgZO7FOkaTXBblSOKYDdkku0VELrZkcw=; b=Yvc2f2kLvTI4zeVJajIvHEDqjbHgsiJo5tl4W02XWQNuGcUhFFn56JsJo2Yyy1bCgI NkfpYyOX0sl6GtbOylAjStuKfG97rwtfMvuO7MI+sOuAZ1z71PQwVFK/SNgXvPyqTmah 1noXAx1t9+jY4vpY2ABCyE/myzYpIeflNX9AJLbD/VcGGiHGiirrV0Cjz6TGc26uS+3g bvRlgguSlwzcxiLcVYj/gMdLbhQEMcXUF887iU/wgbo+U6Fpa3aC8nXdtyzqxbja1oMC zBi8+pT0VoNZheHiIEKsAjJWODVyO76iWI4a/3mxZecWsP51msl1Z0UeoZjZiEH5H6W3 sL1g== X-Gm-Message-State: AKaTC01GL6I9HV+P8M0vAnLL+88sWInkWENqTGEFq/Hf5cAFQxZgKYpzQuFm76GK3riL5qgSHCS/84zx9cEk4A== X-Received: by 10.28.113.218 with SMTP id d87mr3573660wmi.111.1480014086316; Thu, 24 Nov 2016 11:01:26 -0800 (PST) MIME-Version: 1.0 Received: by 10.28.70.197 with HTTP; Thu, 24 Nov 2016 11:01:25 -0800 (PST) In-Reply-To: <5837261E.9040700@grosbein.net> References: <5831E800.60003@grosbein.net> <5832FF33.9010307@grosbein.net> <58330AB6.60306@grosbein.net> <58332491.3000706@grosbein.net> <58332940.8030606@grosbein.net> <58346974.2020907@grosbein.net> <58371526.4050908@grosbein.net> <5837261E.9040700@grosbein.net> From: Michael Zhilin Date: Thu, 24 Nov 2016 22:01:25 +0300 Message-ID: Subject: Re: MIPS code size strangeness To: Eugene Grosbein Cc: Adrian Chadd , "freebsd-mips@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-mips@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to MIPS List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Nov 2016 19:01:29 -0000 Mm... size of libprivateucl.so.1 was 241560 and new size is 247224? Strange. Could you please compare old & new versions? On Thu, Nov 24, 2016 at 8:40 PM, Eugene Grosbein wrote: > On 24.11.2016 23:28, Eugene Grosbein wrote: > > On 24.11.2016 05:11, Adrian Chadd wrote: > >> It's the mips-xtoolchain or xtoolchain-mips-gcc or something > > > > Thanks! > > > > I've changed the port devel/powerpc64-gcc (master port for > devel/mips-gcc) slightly > > to build gcc-6.2.0 instead of gcc-5.3.0 and it builds and installs just > fine > > using command make FREEBSD_EXTENSION=yes install > > > > Then, I've installed devel/mips-xtoolchain-gcc and run buildworld using > CROSS_TOOLCHAIN=mips-gcc. > > It fails: > > > > --- cancelpoints_sem_new.o --- > > {standard input}: Assembler messages: > > {standard input}:1347: Error: opcode not supported on this processor: > mips1 (mips1) `ll $5,4($4)' > > {standard input}:1350: Error: opcode not supported on this processor: > mips1 (mips1) `sc $5,4($4)' > > {standard input}:1360: Error: opcode not supported on this processor: > mips1 (mips1) `sync' > > {standard input}:1456: Error: opcode not supported on this processor: > mips1 (mips1) `ll $4,0($17)' > > {standard input}:1459: Error: opcode not supported on this processor: > mips1 (mips1) `sc $4,0($17)' > > {standard input}:1469: Error: opcode not supported on this processor: > mips1 (mips1) `sync' > > {standard input}:1697: Error: opcode not supported on this processor: > mips1 (mips1) `sync' > > {standard input}:1702: Error: opcode not supported on this processor: > mips1 (mips1) `ll $5,4($4)' > > {standard input}:1705: Error: opcode not supported on this processor: > mips1 (mips1) `sc $5,4($4)' > > *** [cancelpoints_sem_new.o] Error code 1 > > > > I try to build code for TP-Link WDR3600. > > I'm not familiar with MIPS assembler. Is there a way to alter gcc6 code > generator to avoid this error? > > I've managed to build FreeBSD12/mips using gcc6 and additional src.conf > knobs: > > CROSS_TOOLCHAIN=mips-gcc > WITHOUT_CROSS_COMPILER=yes > CROSSENV+=CFLAGS="-march=mips32" > > This time, ucl_hash_replace() function takes 628 bytes (0x274) instead of > 25000: > > # nm -C -D --print-size --size-sort libprivateucl.so.1 | grep > ucl_hash_replace > 0003098c 00000274 T ucl_hash_replace > > However, libprivateucl.so.1 still takes 247224 bytes in case of > FreeBSD12/mips > comparing with 136064 bytes in case of FreeBSD11/amd64. > > _______________________________________________ > freebsd-mips@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-mips > To unsubscribe, send any mail to "freebsd-mips-unsubscribe@freebsd.org" >