New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 670541 link

Starred by 2 users

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug
Build-Toolchain



Sign in to add a comment

Use the most appropriate -mfpu option when building for ARM devices

Project Member Reported by hashimoto@chromium.org, Dec 2 2016

Issue description

arm.gni always sets arm_fpu to "neon" if arm_use_neon == true.

GCC accepts other values like "crypto-neon-fp-armv8" as -mfpu, so we should use the most appropriate one.
https://gcc.gnu.org/onlinedocs/gcc/ARM-Options.html#index-mfpu-1624
 
Cc: llozano@chromium.org
The GCC manual says "neon" is an alias for "neon-vfpv3".
At least, veyron supports neon-vfpv4 which adds half-precision extensions and fused multiply-add instructions.
Project Member

Comment 3 by bugdroid1@chromium.org, Dec 5 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/e90481d12da0f6b26e5fa541d111ae4e5b9f9022

commit e90481d12da0f6b26e5fa541d111ae4e5b9f9022
Author: hashimoto <hashimoto@chromium.org>
Date: Mon Dec 05 04:20:27 2016

gn: Make arm_fpu configurable

Chrome OS needs to use values like neon-vfpv4 or crypto-neon-fp-armv8.

BUG=670541

Review-Url: https://codereview.chromium.org/2546033002
Cr-Commit-Position: refs/heads/master@{#436231}

[modify] https://crrev.com/e90481d12da0f6b26e5fa541d111ae4e5b9f9022/build/config/arm.gni

Is there a noticeable performance gained by this change, or is it just cleanup?
Cc: puneetster@chromium.org dtor@chromium.org sonnyrao@chromium.org
Project Member

Comment 6 by bugdroid1@chromium.org, Dec 19 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/4341948bf829e486fdc319733b563ff37a00d431

commit 4341948bf829e486fdc319733b563ff37a00d431
Author: Ryo Hashimoto <hashimoto@chromium.org>
Date: Fri Dec 16 04:49:19 2016

chromeos-chrome: Explicitly set arm_fpu and arm_tune

BUG=chromium:670541
TEST=build

Change-Id: Ie68a887102bbf8968395278fc33154b0c89ee637
Reviewed-on: https://chromium-review.googlesource.com/421347
Commit-Ready: Douglas Anderson <dianders@chromium.org>
Tested-by: Ryo Hashimoto <hashimoto@chromium.org>
Reviewed-by: Mike Frysinger <vapier@chromium.org>

[modify] https://crrev.com/4341948bf829e486fdc319733b563ff37a00d431/chromeos-base/chromeos-chrome/chromeos-chrome-9999.ebuild

This is mainly for cleanup.

Currently, we feed MARCH_TUNE (which may contain a -mfpu flag like "neon-vfpv4") to Chrome's GN as extra CXXFLAGS/CFLAGS argument, but Chrome's arm.gni always appends -mfpu=neon so now we are feeding multiple contradicting FPU flags to the compiler.
Change referred by comment #6 is to fix this.

Also, I'd like to change veyron's make.conf to replace ARM_FPU=neon with ARM_FPU=neon-vfpv4 so that the compiler can use vfpv4 instructions (e.g. vfma) when appropriate.
This may result in performance gain, but I'm not sure if it's going to be noticeable.
Project Member

Comment 8 by bugdroid1@chromium.org, Dec 20 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/b0f4c9fd293889da2bb4a3dd55743a9654fecbec

commit b0f4c9fd293889da2bb4a3dd55743a9654fecbec
Author: Douglas Anderson <dianders@chromium.org>
Date: Tue Dec 20 17:15:55 2016

Revert "chromeos-chrome: Explicitly set arm_fpu and arm_tune"

This reverts commit 4341948bf829e486fdc319733b563ff37a00d431.

This appears to be causing problems.  See:
  chromium:675978

BUG= chromium:675978 , chromium:670541
TEST=Compile Chrome

Change-Id: Idce4779b8f3061c71ea6bd1ddfce1b92122b2664
Reviewed-on: https://chromium-review.googlesource.com/422416
Tested-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Mike Frysinger <vapier@chromium.org>

[modify] https://crrev.com/b0f4c9fd293889da2bb4a3dd55743a9654fecbec/chromeos-base/chromeos-chrome/chromeos-chrome-9999.ebuild

Components: Infra>Client>ChromeOS>Build Tools>ChromeOS-Toolchain

Sign in to add a comment