Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCHv2] mpg123: use code optimized for ARM NEON SIMD engine if available
@ 2014-06-01 12:42 Thomas Petazzoni
  2014-06-01 12:44 ` Gustavo Zacarias
  0 siblings, 1 reply; 2+ messages in thread
From: Thomas Petazzoni @ 2014-06-01 12:42 UTC (permalink / raw)
  To: buildroot

From: Sven Neumann <neumann@teufel.de>

[Thomas: as suggested by Peter, enable NEON as soon as NEON is
available, not necessarily when NEON is used as the default FPU. Note
that this requires passing -mfpu=neon to build mpg123, so that for
this specific package, the NEON unit is used as the FPU.]

Signed-off-by: Sven Neumann <neumann@teufel.de>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
---
 package/mpg123/mpg123.mk | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/package/mpg123/mpg123.mk b/package/mpg123/mpg123.mk
index d66592c..98fdc3e 100644
--- a/package/mpg123/mpg123.mk
+++ b/package/mpg123/mpg123.mk
@@ -13,10 +13,16 @@ MPG123_LICENSE = LGPLv2.1
 MPG123_LICENSE_FILES = COPYING
 
 MPG123_CPU = $(if $(BR2_SOFT_FLOAT),generic_nofpu,generic_fpu)
+MPG123_CFLAGS = $(TARGET_CFLAGS)
 
 ifeq ($(BR2_arm),y)
+ifeq ($(BR2_ARM_CPU_HAS_NEON),y)
+MPG123_CPU = neon
+MPG123_CFLAGS += -mfpu=neon
+else
 MPG123_CPU = arm_nofpu
 endif
+endif
 
 ifeq ($(BR2_i386),y)
 MPG123_CPU = x86
@@ -34,6 +40,7 @@ MPG123_CPU = x86-64
 endif
 
 MPG123_CONF_OPT += --with-cpu=$(MPG123_CPU)
+MPG123_CONF_ENV += CFLAGS="$(MPG123_CFLAGS)"
 
 MPG123_AUDIO = dummy oss
 
-- 
1.9.3

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [Buildroot] [PATCHv2] mpg123: use code optimized for ARM NEON SIMD engine if available
  2014-06-01 12:42 [Buildroot] [PATCHv2] mpg123: use code optimized for ARM NEON SIMD engine if available Thomas Petazzoni
@ 2014-06-01 12:44 ` Gustavo Zacarias
  0 siblings, 0 replies; 2+ messages in thread
From: Gustavo Zacarias @ 2014-06-01 12:44 UTC (permalink / raw)
  To: buildroot

On 06/01/2014 09:42 AM, Thomas Petazzoni wrote:

> From: Sven Neumann <neumann@teufel.de>
> 
> [Thomas: as suggested by Peter, enable NEON as soon as NEON is
> available, not necessarily when NEON is used as the default FPU. Note
> that this requires passing -mfpu=neon to build mpg123, so that for
> this specific package, the NEON unit is used as the FPU.]
> 
> Signed-off-by: Sven Neumann <neumann@teufel.de>
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>

It might be better to look at the new mpg123 release that does ARM
optimizations in a different (and possibly incompatible) way.
1.20.0 for Aarch64, 1.19.0 for ARM (--with-cpu for configure).
Regards.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-06-01 12:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-01 12:42 [Buildroot] [PATCHv2] mpg123: use code optimized for ARM NEON SIMD engine if available Thomas Petazzoni
2014-06-01 12:44 ` Gustavo Zacarias

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox