From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1XYfia-00066G-RD for mharc-grub-devel@gnu.org; Mon, 29 Sep 2014 14:30:40 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41825) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XYfiT-0005rB-2X for grub-devel@gnu.org; Mon, 29 Sep 2014 14:30:38 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XYfiL-0008Ry-BA for grub-devel@gnu.org; Mon, 29 Sep 2014 14:30:33 -0400 Received: from mail-la0-x22d.google.com ([2a00:1450:4010:c03::22d]:58075) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XYfiL-0008Q1-3I for grub-devel@gnu.org; Mon, 29 Sep 2014 14:30:25 -0400 Received: by mail-la0-f45.google.com with SMTP id q1so7021555lam.32 for ; Mon, 29 Sep 2014 11:30:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; bh=WcnslJpmFW2kMW7BH3pzj4yFCPKf4lWlIACU8pnf8is=; b=ocKiOKLvaCHWMmcoOgVT7tPHqsTvaJnJRN0dobegySAw6MO4wvkNygiJoP5l4w6UEI TEQ4emplk0cd0ezQs71R0rMoQiv0I+YIYrrNX4Wrlt3EO0sF1tZ3jyVQ3B+LlGFPOwgT LKawZe/WyjOzFA4u9TQnycDQxZe//DkdIVG3dGX4C9FybCUEFa1tdLquXEogDazl3Dm3 KuFT0Ug3EmtTmVYy4tuzt6+ZFxo9J2RhklWbiHNL5MYHI5e4eU3eYqIhBu24wXVvUPJ5 9ikGC/OxXQC/5qoRnuviT3UvkDa1GMV8ivbfzEO5LXKS0zclO0YTzrFcGmqTtVThn73W FJVA== X-Received: by 10.112.44.129 with SMTP id e1mr39397783lbm.78.1412015418835; Mon, 29 Sep 2014 11:30:18 -0700 (PDT) Received: from opensuse.site (ppp94-29-94-89.pppoe.spdop.ru. [94.29.94.89]) by mx.google.com with ESMTPSA id bc1sm5134413lab.40.2014.09.29.11.30.17 for (version=SSLv3 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 29 Sep 2014 11:30:18 -0700 (PDT) Date: Mon, 29 Sep 2014 22:30:16 +0400 From: Andrei Borzenkov To: pfsmorigo@linux.vnet.ibm.com Subject: Re: [PATCH] Add flags for powerpc in order to avoid exceptions Message-ID: <20140929223016.1ebb5d7b@opensuse.site> In-Reply-To: <20140927090653.062225be@opensuse.site> References: <20140926192936.GA30134@beren.chocolate> <20140927090653.062225be@opensuse.site> X-Mailer: Claws Mail 3.9.2 (GTK+ 2.24.23; x86_64-suse-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c03::22d Cc: The development of GNU GRUB , azanella@linux.vnet.ibm.com X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Sep 2014 18:30:38 -0000 =D0=92 Sat, 27 Sep 2014 09:06:53 +0400 Andrei Borzenkov =D0=BF=D0=B8=D1=88=D0=B5=D1=82: > =D0=92 Fri, 26 Sep 2014 16:29:40 -0300 > Paulo Flabiano Smorigo =D0=BF=D0=B8=D1=88= =D0=B5=D1=82: >=20 > > * conf/Makefile.common [COND_powerpc_ieee1275] (CFLAGS_PLATFORM): Add > > -msoft-float -mno-vsx -mno-altivec. > >=20 > > Also-By: Adhemerval Zanella > > --- > > ChangeLog | 7 +++++++ > > conf/Makefile.common | 3 +++ > > 2 files changed, 10 insertions(+) > >=20 > > diff --git a/ChangeLog b/ChangeLog > > index 192e8bc..40eb90c 100644 > > --- a/ChangeLog > > +++ b/ChangeLog > > @@ -1,3 +1,10 @@ > > +2014-09-26 Paulo Flabiano Smorigo > > + > > + Add flags for powerpc in order to avoid exceptions > > + > > + * conf/Makefile.common [COND_powerpc_ieee1275] (CFLAGS_PLATFORM): Add > > + -msoft-float -mno-vsx -mno-altivec. > > + > > 2014-09-25 Colin Watson > > =20 > > Fix in-tree --platform=3Dnone > > diff --git a/conf/Makefile.common b/conf/Makefile.common > > index 51fbaf9..57c491a 100644 > > --- a/conf/Makefile.common > > +++ b/conf/Makefile.common > > @@ -22,6 +22,9 @@ endif > > if COND_arm64 > > CFLAGS_PLATFORM +=3D -mcmodel=3Dlarge > > endif > > +if COND_powerpc_ieee1275 > > + CFLAGS_PLATFORM +=3D -msoft-float -mno-vsx -mno-altivec > > +endif > > =20 > > #FIXME: discover and check XEN headers > > CPPFLAGS_XEN =3D -I/usr/include >=20 > Thank you! I confirm that this patch works and does not break grub on > earlier CPU :) >=20 > There are still differences in generated code, so we probably need to > tune some more flags. I looked at compiler options for PowerPC and I think instead of trying to catch individual flags which may change with every release we should simply force the most common platform by +if COND_powerpc_ieee1275 + CFLAGS_PLATFORM +=3D -mcpu=3Dpowerpc -mtune=3Dpowerpc +endif This makes sure result is identical on every platform and provides most generic code that is expected to run on every(?) system. WDYT?