From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id DAD19138989 for ; Sat, 2 May 2015 12:39:02 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 50CA7E088C; Sat, 2 May 2015 12:38:51 +0000 (UTC) Received: from plane.gmane.org (plane.gmane.org [80.91.229.3]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 41665E0869 for ; Sat, 2 May 2015 12:38:49 +0000 (UTC) Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1YoWgx-00058t-NE for gentoo-user@lists.gentoo.org; Sat, 02 May 2015 14:38:47 +0200 Received: from athedsl-347543.home.otenet.gr ([85.72.213.53]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 02 May 2015 14:38:47 +0200 Received: from realnc by athedsl-347543.home.otenet.gr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 02 May 2015 14:38:47 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: gentoo-user@lists.gentoo.org From: Nikos Chantziaras Subject: [gentoo-user] Re: CFLAGs for kernel compilation Date: Sat, 02 May 2015 15:38:39 +0300 Organization: Lucas Barks Message-ID: References: <5540C101.70906@ramses-pyramidenbau.de> <20150430123819.b72d8b39bd60a912b7c7fde5@gentoo.org> <20150501104402.27d943c901f638942262d3d1@gentoo.org> <5544B2AB.1010700@googlemail.com> <5544B6F2.8040508@googlemail.com> <5544BEB9.9050103@googlemail.com> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: athedsl-347543.home.otenet.gr User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 In-Reply-To: <5544BEB9.9050103@googlemail.com> X-Archives-Salt: ef0a2f38-fafd-4a73-8c06-62fcedced1e7 X-Archives-Hash: 69e4c844101c2a605573c0841d1abc2c On 02/05/15 15:10, Volker Armin Hemmann wrote: > Am 02.05.2015 um 14:06 schrieb Nikos Chantziaras: >> On 02/05/15 14:37, Volker Armin Hemmann wrote: >>> Am 02.05.2015 um 13:25 schrieb Nikos Chantziaras: >>>>>> >>>>>> The kernel uses -O2 and several -march variants (e.g. -march=core2). >>>>>> Several other options are used to prevent GCC from generating >>>>>> unsuitable code. >>>>>> >>>>>> Specifying another -march variant does not affect the optimizer >>>>>> though. It only affects the code generator. If you don't modify the >>>>>> other CFLAGS and only change -march, you will not get FP instructions >>>>>> unless you use FP in the code. >>>>> >>>>> http://www.agner.org/optimize/calling_conventions.pdf >>>> >>>> Not sure what you're trying to say. >>>> >>> >>> that simd is not save in kernel if not carefully guarded. >>> >>> Really people, just don't fuck around with the cflags. >> >> I still fail to see the relevance. Unless you mean using a different >> -O level. In that case, yes. You shouldn't. But I was talking about >> -march. >> > > you said this > >> >> (note that SIMD is not FP and is perfectly fine in the kernel.) > > and I have shown you that you are wrong. Not sure why you think that. The kernel crypto routines are full of SIMD code (like SSE and AVX.) Automatic vectorization wouldn't work. But -march is not going to introduce that.