* [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic)
@ 2019-07-18 20:52 Yann E. MORIN
2019-07-18 20:52 ` [Buildroot] [PATCH 1/2 v3] toolchain: allow architectures to enforce compilation flags Yann E. MORIN
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Yann E. MORIN @ 2019-07-18 20:52 UTC (permalink / raw)
To: buildroot
Hello All!
This series makes it so that architectures can set compilation flags,
passed down via the wrapper.
This is then used by arc to enforce -matomic for those cores that need
it, namely arc7x0, as reported by Alexey:
https://patchwork.ozlabs.org/patch/1087480/
https://patchwork.ozlabs.org/patch/1087471/
Changes v2 -> v3:
- fix 'y' -> 'yy' in condition
Changes v1 -> v2:
- move condition that was previously in package/Makefile.in (Alexey)
Regards,
Yann E. MORIN.
The following changes since commit ed3eef6bb49270de619e5a86a249fdd8724c40cd
package/glib-networking: bump to version 2.61.1 (2019-07-14 16:11:45 +0200)
are available in the git repository at:
git://git.buildroot.org/~ymorin/git/buildroot.git
for you to fetch changes up to 7fe54408b9c04d8d5799a167aded7c0b0157c572
arch/arc: always needs -matomic with atomix extensions (2019-07-18 22:51:24 +0200)
----------------------------------------------------------------
Yann E. MORIN (2):
toolchain: allow architectures to enforce compilation flags
arch/arc: always needs -matomic with atomix extensions
arch/arch.mk.arc | 4 ++++
package/Makefile.in | 4 ----
toolchain/toolchain-wrapper.mk | 1 +
3 files changed, 5 insertions(+), 4 deletions(-)
create mode 100644 arch/arch.mk.arc
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH 1/2 v3] toolchain: allow architectures to enforce compilation flags
2019-07-18 20:52 [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic) Yann E. MORIN
@ 2019-07-18 20:52 ` Yann E. MORIN
2019-07-18 20:52 ` [Buildroot] [PATCH 2/2 v3] arch/arc: always needs -matomic with atomix extensions Yann E. MORIN
2019-07-18 20:57 ` [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic) Thomas Petazzoni
2 siblings, 0 replies; 5+ messages in thread
From: Yann E. MORIN @ 2019-07-18 20:52 UTC (permalink / raw)
To: buildroot
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
Cc: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Cc: Arnout Vandecappelle <arnout@mind.be>
Acked-by: Alexey Brodkin <abrodkin@synopsys.com>
---
toolchain/toolchain-wrapper.mk | 1 +
1 file changed, 1 insertion(+)
diff --git a/toolchain/toolchain-wrapper.mk b/toolchain/toolchain-wrapper.mk
index ca66fa7ba4..8f872506ec 100644
--- a/toolchain/toolchain-wrapper.mk
+++ b/toolchain/toolchain-wrapper.mk
@@ -17,6 +17,7 @@ TOOLCHAIN_WRAPPER_ARGS = $($(PKG)_TOOLCHAIN_WRAPPER_ARGS)
TOOLCHAIN_WRAPPER_ARGS += -DBR_SYSROOT='"$(STAGING_SUBDIR)"'
TOOLCHAIN_WRAPPER_OPTS = \
+ $(ARCH_TOOLCHAIN_WRAPPER_OPTS) \
$(call qstrip,$(BR2_SSP_OPTION)) \
$(call qstrip,$(BR2_TARGET_OPTIMIZATION))
--
2.20.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH 2/2 v3] arch/arc: always needs -matomic with atomix extensions
2019-07-18 20:52 [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic) Yann E. MORIN
2019-07-18 20:52 ` [Buildroot] [PATCH 1/2 v3] toolchain: allow architectures to enforce compilation flags Yann E. MORIN
@ 2019-07-18 20:52 ` Yann E. MORIN
2019-07-18 20:57 ` [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic) Thomas Petazzoni
2 siblings, 0 replies; 5+ messages in thread
From: Yann E. MORIN @ 2019-07-18 20:52 UTC (permalink / raw)
To: buildroot
As reported by Alexey:
https://patchwork.ozlabs.org/patch/1087480/
https://patchwork.ozlabs.org/patch/1087471/
Reported-by: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
Cc: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Cc: Arnout Vandecappelle <arnout@mind.be>
Acked-by: Alexey Brodkin <abrodkin@synopsys.com>
---
Changes v2 -> v3:
- fix the condition test ('yy', not 'y')
Changes v1 -> v2:
- move the condition out of package/Makefile.in (Alexey)
---
arch/arch.mk.arc | 4 ++++
package/Makefile.in | 4 ----
2 files changed, 4 insertions(+), 4 deletions(-)
create mode 100644 arch/arch.mk.arc
diff --git a/arch/arch.mk.arc b/arch/arch.mk.arc
new file mode 100644
index 0000000000..5fcffb7f4b
--- /dev/null
+++ b/arch/arch.mk.arc
@@ -0,0 +1,4 @@
+# -matomic is always required when the ARC core has the atomic extensions
+ifeq ($(BR2_arc)$(BR2_ARC_ATOMIC_EXT),yy)
+ARCH_TOOLCHAIN_WRAPPER_OPTS = -matomic
+endif
diff --git a/package/Makefile.in b/package/Makefile.in
index f05b9cc3aa..0a7899c852 100644
--- a/package/Makefile.in
+++ b/package/Makefile.in
@@ -112,10 +112,6 @@ ifeq ($(BR2_xtensa),y)
TARGET_ABI += -mlongcalls -mauto-litpools
endif
-ifeq ($(BR2_arc)$(BR2_ARC_ATOMIC_EXT),yy)
-TARGET_ABI += -matomic
-endif
-
STAGING_SUBDIR = $(GNU_TARGET_NAME)/sysroot
STAGING_DIR = $(HOST_DIR)/$(STAGING_SUBDIR)
--
2.20.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic)
2019-07-18 20:52 [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic) Yann E. MORIN
2019-07-18 20:52 ` [Buildroot] [PATCH 1/2 v3] toolchain: allow architectures to enforce compilation flags Yann E. MORIN
2019-07-18 20:52 ` [Buildroot] [PATCH 2/2 v3] arch/arc: always needs -matomic with atomix extensions Yann E. MORIN
@ 2019-07-18 20:57 ` Thomas Petazzoni
2019-07-20 13:38 ` Thomas Petazzoni
2 siblings, 1 reply; 5+ messages in thread
From: Thomas Petazzoni @ 2019-07-18 20:57 UTC (permalink / raw)
To: buildroot
Hello,
On Thu, 18 Jul 2019 22:52:46 +0200
"Yann E. MORIN" <yann.morin.1998@free.fr> wrote:
> Yann E. MORIN (2):
> toolchain: allow architectures to enforce compilation flags
> arch/arc: always needs -matomic with atomix extensions
Thanks, I've applied the series. I extended the commit log of the
second patch, because it was really terse.
Following this, I believe it would make sense to move the two remaining
uses of TARGET_ABI in package/Makefile.in to the appropriate arch/
file, and drop TARGET_ABI entirely. Indeed, those ABI options are
really mandatory, if they don't get passed to the cross-compiler,
things are going to be clearly wrong.
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic)
2019-07-18 20:57 ` [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic) Thomas Petazzoni
@ 2019-07-20 13:38 ` Thomas Petazzoni
0 siblings, 0 replies; 5+ messages in thread
From: Thomas Petazzoni @ 2019-07-20 13:38 UTC (permalink / raw)
To: buildroot
On Thu, 18 Jul 2019 22:57:40 +0200
Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote:
> On Thu, 18 Jul 2019 22:52:46 +0200
> "Yann E. MORIN" <yann.morin.1998@free.fr> wrote:
>
> > Yann E. MORIN (2):
> > toolchain: allow architectures to enforce compilation flags
> > arch/arc: always needs -matomic with atomix extensions
>
> Thanks, I've applied the series. I extended the commit log of the
> second patch, because it was really terse.
>
> Following this, I believe it would make sense to move the two remaining
> uses of TARGET_ABI in package/Makefile.in to the appropriate arch/
> file, and drop TARGET_ABI entirely. Indeed, those ABI options are
> really mandatory, if they don't get passed to the cross-compiler,
> things are going to be clearly wrong.
Also, in relation to this, I think we could probably revert commit
18855d79e2e86dc646182bd6f4861c491a05c624 one the TARGET_ABI flags are
encoded into the compiler wrapper.
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2019-07-20 13:38 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-07-18 20:52 [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic) Yann E. MORIN
2019-07-18 20:52 ` [Buildroot] [PATCH 1/2 v3] toolchain: allow architectures to enforce compilation flags Yann E. MORIN
2019-07-18 20:52 ` [Buildroot] [PATCH 2/2 v3] arch/arc: always needs -matomic with atomix extensions Yann E. MORIN
2019-07-18 20:57 ` [Buildroot] [PATCH 0/2 v3] arch: allow passing compile flags (branch yem/arc-atomic) Thomas Petazzoni
2019-07-20 13:38 ` Thomas Petazzoni
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox