This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, rs6000] Fix PR target/68872, make -mcpu=powerpc64le pass correct assembler option
- From: David Edelsohn <dje dot gcc at gmail dot com>
- To: Peter Bergner <bergner at vnet dot ibm dot com>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 22 Dec 2015 13:36:45 -0500
- Subject: Re: [PATCH, rs6000] Fix PR target/68872, make -mcpu=powerpc64le pass correct assembler option
- Authentication-results: sourceware.org; auth=none
- References: <1450804433 dot 3482 dot 17 dot camel at vnet dot ibm dot com>
On Tue, Dec 22, 2015 at 12:13 PM, Peter Bergner <bergner@vnet.ibm.com> wrote:
> Currently, -mcpu=powerpc64le correctly sets the TARGET_* flags for an
> LE compile, meaning it mimics a -mcpu=power8 compile, but it doesn't
> pass the correct -mpower8/-mpwr8 option to the assembler, so we die
> with lots of assembler errors on POWER8 instructions. This patch
> fixes things so we pass the correct assembler option when using
> -mcpu=powerpc64le.
>
> This passes bootstrap/regtesting on powerpc64le-linux. Ok for mainline?
> Ok for the release branches too after testing?
>
> Peter
>
>
> gcc/
> PR target/68772
> * config/rs6000/rs6000.h (ASM_CPU_SPEC): For -mcpu=powerpc64le,
> pass %(asm_cpu_power8)/-mpwr8.
> * config/rs6000/aix53.h: Likewise.
> * config/rs6000/aix61.h: Likewise.
> * config/rs6000/aix71.h: Likewise.
>
> gcc/testsuite/
> PR target/68772
> * gcc.target/powerpc/pr68872.c: New test.
AIX does not support PPC64LE, so the aix53.h, aix61.h and aix71.h
changes should not be applied.
Ultimately rs6000_file_start ".machine" directive support should be
strengthened to handle -mcpu=.
Okay with just the rs6000.h change and new testcase.
Thanks, David