All of lore.kernel.org
 help / color / mirror / Atom feed
From: Serhey Popovych <serhe.popovych@gmail.com>
To: Khem Raj <raj.khem@gmail.com>
Cc: Patches and discussions about the oe-core layer
	<openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH 05/13] arch-powerpc64.inc: Use elfv2 ABI when building with musl
Date: Mon, 17 Dec 2018 11:36:42 +0200	[thread overview]
Message-ID: <40d476be-b97b-641a-f823-25c9a162324e@gmail.com> (raw)
In-Reply-To: <CAMKF1spGeN_PxOKM5XC5CG6dPFSNv1H+OyDv2P9k6SoK6uAt5g@mail.gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 2403 bytes --]

Khem Raj wrote:
> On Fri, Dec 14, 2018 at 9:56 AM Serhey Popovych
> <serhe.popovych@gmail.com> wrote:
>>
>> Historically first PowerPC ABI was big-endian only (elfv1 currently). It
>> is standard ABI for both 32-bit ppc and 64-bit ppc64 architectures.
>>
>> With PowerPC little-endian support new ABI was introduced (elfv2) and it
>> is used primarily with ppc64le target only. While it has support for
>> big-endian it is not commonly used and elfv1 still preferred.
>>
>> Musl does support only elfv2 ABI for both LE and BE and does not have
>> any plans to support elfv1.
>>
>> Since then to build for powerpc64 with musl new ABI should be used. As
>> expected it is not compatible with elfv1 but that isn't problem as long
>> as there is no binary distributed software or assembly code written for
>> elfv1 ABI.
>>
>> Signed-off-by: Serhey Popovych <serhe.popovych@gmail.com>
>> ---
>>  meta/conf/machine/include/powerpc/arch-powerpc64.inc | 3 +++
>>  1 file changed, 3 insertions(+)
>>
>> diff --git a/meta/conf/machine/include/powerpc/arch-powerpc64.inc b/meta/conf/machine/include/powerpc/arch-powerpc64.inc
>> index f751c6b..d9916d4 100644
>> --- a/meta/conf/machine/include/powerpc/arch-powerpc64.inc
>> +++ b/meta/conf/machine/include/powerpc/arch-powerpc64.inc
>> @@ -7,6 +7,9 @@ TUNECONFLICTS[m64] = "m32 nf"
>>  TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'm64', ' -m64', '', d)}"
>>  TUNE_ARCH .= "${@bb.utils.contains('TUNE_FEATURES', [ 'm64' ], 'powerpc64', '', d)}"
>>
>> +# musl only supports elfv2 ABI for ppc64
>> +TUNE_CCARGS .= "${@['', ' -mabi=elfv2']['libc-musl' in d.getVar('OVERRIDES').split(':')]}"
>> +
> 
> I wonder if we should change gcc to use this ABI by default when
> configured for ppc64/musl ?
> This would avoid us adding compiler options here, in bad cases it may
> be that other compilers
> call it out differently.

Good point. This should be easy to do with patch applied for libc-musl
override.

> 
>>  # user mode qemu doesn't support ppc64
>>  MACHINE_FEATURES_BACKFILL_CONSIDERED_append = " ${@bb.utils.contains('TUNE_FEATURES', 'm64', 'qemu-usermode', '', d)}"
>>
>> --
>> 2.7.4
>>
>> --
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.openembedded.org/mailman/listinfo/openembedded-core



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 501 bytes --]

  reply	other threads:[~2018-12-17  9:36 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-14 17:54 [PATCH 00/13] powerpc/powerpc64: Support build with musl as libc Serhey Popovych
2018-12-14 17:54 ` [PATCH 01/13] lib/oe/elf.py: Add powerpc64 architecture definition for musl Serhey Popovych
2018-12-14 17:54 ` [PATCH 02/13] tune-power[5-7].inc: Fix DEFAULTTUNE values Serhey Popovych
2018-12-14 17:54 ` [PATCH 03/13] tune-power[5-7].inc: Disable QEMU usermode usage Serhey Popovych
2018-12-14 17:54 ` [PATCH 04/13] qemuwrapper: Explicitly exit in case of no qemu supported for target Serhey Popovych
2018-12-14 17:54 ` [PATCH 05/13] arch-powerpc64.inc: Use elfv2 ABI when building with musl Serhey Popovych
2018-12-14 23:36   ` Khem Raj
2018-12-17  9:36     ` Serhey Popovych [this message]
2018-12-17 10:26       ` Richard Purdie
2018-12-14 17:54 ` [PATCH 06/13] musl: Create default library search path based on configuration Serhey Popovych
2018-12-14 23:40   ` Khem Raj
2018-12-17  9:37     ` Serhey Popovych
2018-12-14 17:54 ` [PATCH 07/13] musl: Ensure GLIBC_LDSO symlink target does not exist on reinstall Serhey Popovych
2018-12-14 19:09   ` Andre McCurdy
2018-12-15 11:00     ` Richard Purdie
2018-12-17  9:49       ` Serhey Popovych
2018-12-17 10:44         ` richard.purdie
2018-12-17 15:13           ` Serhey Popovych
2018-12-14 17:54 ` [PATCH 08/13] openssl: Skip assembler optimized code for powerpc64 with musl Serhey Popovych
2018-12-14 17:54 ` [PATCH 09/13] python3: Fix do_configure check platform triplet error (2) Serhey Popovych
2018-12-14 17:54 ` [PATCH 10/13] gcc: Fix preprocessor redefines for header pathes Serhey Popovych
2018-12-14 17:54 ` [PATCH 11/13] gcc: More places to patch to disable ldbl 128 for musl on PPC Serhey Popovych
2018-12-14 23:44   ` Khem Raj
2018-12-15 12:06     ` Richard Purdie
2018-12-14 17:54 ` [PATCH 12/13] gcc: Enable secureplt for powerpc64 target too Serhey Popovych
2018-12-14 17:54 ` [PATCH 13/13] gcc-7.3, gcc-8.2: Use variable SYSTEMLIBS_DIR instead of hardcoding it for ppc64 Serhey Popovych
2018-12-14 23:46 ` [PATCH 00/13] powerpc/powerpc64: Support build with musl as libc Khem Raj
2018-12-17  9:56   ` Serhey Popovych

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=40d476be-b97b-641a-f823-25c9a162324e@gmail.com \
    --to=serhe.popovych@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=raj.khem@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.