[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+i0qc4z2aNHQ+WcCJ7uz9pt9WCseQ-B_x7D0baMYduDcsV8Rw@mail.gmail.com>
Date: Thu, 23 Jun 2016 09:27:30 +0300
From: Tomas Winkler <tomasw@...il.com>
To: Arnd Bergmann <arnd@...db.de>
Cc: "Levy, Amir (Jer)" <amir.jer.levy@...el.com>,
Andrew Morton <akpm@...ux-foundation.org>,
"mm-commits@...r.kernel.org" <mm-commits@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-scsi@...r.kernel.org" <linux-scsi@...r.kernel.org>,
"jpoimboe@...hat.com" <jpoimboe@...hat.com>,
Martin Jambor <mjambor@...e.cz>,
"Martin K. Petersen" <martin.petersen@...cle.com>,
James Bottomley <James.Bottomley@...senpartnership.com>,
Denys Vlasenko <dvlasenk@...hat.com>,
Thomas Graf <tgraf@...g.ch>,
Peter Zijlstra <peterz@...radead.org>,
David Rientjes <rientjes@...gle.com>,
Ingo Molnar <mingo@...nel.org>,
Himanshu Madhani <himanshu.madhani@...gic.com>,
Dept-Eng QLA2xxx Upstream <qla2xxx-upstream@...gic.com>,
Jan Hubicka <hubicka@....cz>
Subject: Re: [PATCH v2] byteswap: try to avoid __builtin_constant_p gcc bug
On Wed, Jun 22, 2016 at 3:25 PM, Arnd Bergmann <arnd@...db.de> wrote:
> On Wednesday, June 22, 2016 2:44:21 PM CEST Tomas Winkler wrote:
>> >
>> > There are more than 20 files that have the statement: case cpu_to_...
>> > Sparse complains about: case __builtin_bswap, not about __builtin_constant_p.
>>
>> There is even much more in the header files used in initializers,
>> which also require constants. I wonder if __builtin_bswap produces
>> constant expression correctly under gcc?
>
> In gcc-4.8 or later yes. gcc-4.6/4.7 on powerpc was a special case that we
> have worked around now, as the 16-bit byteswap there was not a constant
> expression, unlike the 32-bit and 64-bit ones.
Can you please give any references to that?
Just to make sure we are on the same line , the bottom line is that
sparse has to be adjusted.
Thanks
Tomas
Powered by blists - more mailing lists