All of lore.kernel.org
 help / color / mirror / Atom feed
From: catalin.marinas@arm.com (Catalin Marinas)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] arm64: relax assembly code alignment from 16 byte to 4 byte
Date: Wed, 20 Sep 2017 13:19:07 +0100	[thread overview]
Message-ID: <20170920121907.x4jxd74tuogkb52a@localhost> (raw)
In-Reply-To: <CAK7LNAQYDgY-4Bu9-RRLAj8hvKFXx2ctXFf058W4uQLoqpTQeg@mail.gmail.com>

On Wed, Sep 20, 2017 at 07:58:34PM +0900, Masahiro Yamada wrote:
> 2017-09-08 1:46 GMT+09:00 Catalin Marinas <catalin.marinas@arm.com>:
> > On Thu, Aug 31, 2017 at 06:56:23PM +0900, Masahiro Yamada wrote:
> >> Aarch64 instructions must be word aligned.  The current 16 byte
> >> alignment is more than enough.  Relax it into 4 byte alignment.
> >>
> >> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> >> ---
> >>
> >> I do not know why arm64 Linux requires 16 byte alignment.
> >>
> >> I dug git-history of arch/arm64/include/asm/linkage.h
> >> and the only commit I see is:
> >>
> >>   commit aeed41a9371ee02257b608eb06a9058507a7d0f4
> >>   Author: Marc Zyngier <Marc.Zyngier@arm.com>
> >>   Date:   Fri Oct 19 17:33:27 2012 +0100
> >>
> >>       arm64: fix alignment padding in assembly code
> >>
> >> It just opt out of the asm-generic variant to remove 0x90.
> >> So, the amount of alignment might not be not optimized yet.
> >>
> >> Please correct me if I am missing something.
> >
> > Not sure why we ended up with 4. Possibly because we forgot the power of
> > 2 difference for arm/arm64.
> >
> > Queued for 4.14. Thanks.
> 
> I still do not see this patch in linux-next.

It won't make it into linux-next now, I'll push it as a fix for -rc2
(sorry, I've been away at Plumbers and didn't get the chance to send any
pull request). I'll push the patch out on fixes/core once I investigate
some unrelated failures.

-- 
Catalin

WARNING: multiple messages have this Message-ID (diff)
From: Catalin Marinas <catalin.marinas@arm.com>
To: Masahiro Yamada <yamada.masahiro@socionext.com>
Cc: Rob Herring <robh@kernel.org>, Arnd Bergmann <arnd@arndb.de>,
	Marc Zyngier <marc.zyngier@arm.com>,
	Will Deacon <will.deacon@arm.com>,
	Russell King <linux@armlinux.org.uk>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Olof Johansson <olof@lixom.net>,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCH] arm64: relax assembly code alignment from 16 byte to 4 byte
Date: Wed, 20 Sep 2017 13:19:07 +0100	[thread overview]
Message-ID: <20170920121907.x4jxd74tuogkb52a@localhost> (raw)
In-Reply-To: <CAK7LNAQYDgY-4Bu9-RRLAj8hvKFXx2ctXFf058W4uQLoqpTQeg@mail.gmail.com>

On Wed, Sep 20, 2017 at 07:58:34PM +0900, Masahiro Yamada wrote:
> 2017-09-08 1:46 GMT+09:00 Catalin Marinas <catalin.marinas@arm.com>:
> > On Thu, Aug 31, 2017 at 06:56:23PM +0900, Masahiro Yamada wrote:
> >> Aarch64 instructions must be word aligned.  The current 16 byte
> >> alignment is more than enough.  Relax it into 4 byte alignment.
> >>
> >> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> >> ---
> >>
> >> I do not know why arm64 Linux requires 16 byte alignment.
> >>
> >> I dug git-history of arch/arm64/include/asm/linkage.h
> >> and the only commit I see is:
> >>
> >>   commit aeed41a9371ee02257b608eb06a9058507a7d0f4
> >>   Author: Marc Zyngier <Marc.Zyngier@arm.com>
> >>   Date:   Fri Oct 19 17:33:27 2012 +0100
> >>
> >>       arm64: fix alignment padding in assembly code
> >>
> >> It just opt out of the asm-generic variant to remove 0x90.
> >> So, the amount of alignment might not be not optimized yet.
> >>
> >> Please correct me if I am missing something.
> >
> > Not sure why we ended up with 4. Possibly because we forgot the power of
> > 2 difference for arm/arm64.
> >
> > Queued for 4.14. Thanks.
> 
> I still do not see this patch in linux-next.

It won't make it into linux-next now, I'll push it as a fix for -rc2
(sorry, I've been away at Plumbers and didn't get the chance to send any
pull request). I'll push the patch out on fixes/core once I investigate
some unrelated failures.

-- 
Catalin

  reply	other threads:[~2017-09-20 12:19 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-31  9:56 [PATCH] arm64: relax assembly code alignment from 16 byte to 4 byte Masahiro Yamada
2017-08-31  9:56 ` Masahiro Yamada
2017-08-31 10:23 ` Lothar Waßmann
2017-08-31 10:23   ` Lothar Waßmann
2017-08-31 10:38   ` Robin Murphy
2017-08-31 10:38     ` Robin Murphy
2017-09-07 16:46 ` Catalin Marinas
2017-09-07 16:46   ` Catalin Marinas
2017-09-20 10:58   ` Masahiro Yamada
2017-09-20 10:58     ` Masahiro Yamada
2017-09-20 12:19     ` Catalin Marinas [this message]
2017-09-20 12:19       ` Catalin Marinas

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=20170920121907.x4jxd74tuogkb52a@localhost \
    --to=catalin.marinas@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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.