All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Hatle <mark.hatle@kernel.crashing.org>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH v4 4/5] microblaze tune: cleanup +=
Date: Tue,  4 Feb 2020 15:06:29 -0600	[thread overview]
Message-ID: <20200204210630.41960-5-mark.hatle@kernel.crashing.org> (raw)
In-Reply-To: <20200204210630.41960-1-mark.hatle@kernel.crashing.org>

From: Mark Hatle <mark.hatle@xilinx.com>

Various += were used, refactor these to be either = or .= depending on
usuage.

CONFLICTS should be '=', as no leading space is required and they are not
amending any other conflict settings.

The TUNE_CCARGS should be .= so that if the feature does not define a CCARG
blank spaces are not added to the CFLAGS.  This is consistent to how the arm
tuning is implemented.

Signed-off-by: Mark Hatle <mark.hatle@xilinx.com>
Signed-off-by: Mark Hatle <mark.hatle@kernel.crashing.org>
---
 .../include/microblaze/arch-microblaze.inc    | 22 +++++++++----------
 .../microblaze/feature-microblaze-math.inc    | 12 +++++-----
 2 files changed, 17 insertions(+), 17 deletions(-)

diff --git a/meta/conf/machine/include/microblaze/arch-microblaze.inc b/meta/conf/machine/include/microblaze/arch-microblaze.inc
index 0349caac0a..4f58076ac9 100644
--- a/meta/conf/machine/include/microblaze/arch-microblaze.inc
+++ b/meta/conf/machine/include/microblaze/arch-microblaze.inc
@@ -11,34 +11,34 @@ MACHINEOVERRIDES =. "${@bb.utils.contains("TUNE_FEATURES", "64-bit", "microblaze
 
 # Endian
 TUNEVALID[bigendian] = "Use Microblaze Big Endian"
-TUNECONFLICTS[bigendian] += "v10.0"
+TUNECONFLICTS[bigendian] = "v10.0"
 
 MBPKGARCH_ENDIAN = "${@bb.utils.contains("TUNE_FEATURES", "bigendian", "eb", "el", d)}"
 
-TUNE_CCARGS += "${@bb.utils.contains("TUNE_FEATURES", "bigendian", "-mbig-endian", "-mlittle-endian", d)}"
+TUNE_CCARGS .= "${@bb.utils.contains("TUNE_FEATURES", "bigendian", " -mbig-endian", " -mlittle-endian", d)}"
 
 # General features
 TUNEVALID[barrel-shift] = "Enable Hardware Barrel Shifter"
 TUNEVALID[pattern-compare] = "Enable Pattern Compare Instructions"
 TUNEVALID[reorder] = "Enable Reorder Instructions"
-TUNECONFLICTS[reorder] += "v8.00 v8.10 v8.20"
+TUNECONFLICTS[reorder] = "v8.00 v8.10 v8.20"
 
 # Core configuration tune optimizations
 TUNEVALID[frequency-optimized] = "Enabling tuning for frequency optimized core (AREA_OPTIMIZED_2)"
-TUNECONFLICTS[frequency-optimized] += "v8.00 v8.10 v8.20 v8.30 v8.40 v8.50 v9.0 v9.1 v9.2 v9.3 v9.4 v9.5 v9.6"
+TUNECONFLICTS[frequency-optimized] = "v8.00 v8.10 v8.20 v8.30 v8.40 v8.50 v9.0 v9.1 v9.2 v9.3 v9.4 v9.5 v9.6"
 
 # Feature compiler args
-TUNE_CCARGS += "${@bb.utils.contains("TUNE_FEATURES", "barrel-shift", "-mxl-barrel-shift", "-mno-xl-barrel-shift", d)}"
-TUNE_CCARGS += "${@bb.utils.contains("TUNE_FEATURES", "pattern-compare", "-mxl-pattern-compare", "-mno-xl-pattern-compare", d)}"
-TUNE_CCARGS += "${@bb.utils.contains("TUNE_FEATURES", "frequency-optimized", "-mxl-frequency", "", d)}"
-TUNE_CCARGS += "${@bb.utils.contains("TUNE_FEATURES", "64-bit", "-m64", "", d)}"
+TUNE_CCARGS .= "${@bb.utils.contains("TUNE_FEATURES", "barrel-shift", " -mxl-barrel-shift", " -mno-xl-barrel-shift", d)}"
+TUNE_CCARGS .= "${@bb.utils.contains("TUNE_FEATURES", "pattern-compare", " -mxl-pattern-compare", " -mno-xl-pattern-compare", d)}"
+TUNE_CCARGS .= "${@bb.utils.contains("TUNE_FEATURES", "frequency-optimized", " -mxl-frequency", "", d)}"
+TUNE_CCARGS .= "${@bb.utils.contains("TUNE_FEATURES", "64-bit", " -m64", "", d)}"
 
 # Disable reorder for v8.30 if pattern-compare is not enabled
-TUNE_CCARGS += "${@bb.utils.contains("TUNE_FEATURES", "reorder", \
+TUNE_CCARGS .= "${@bb.utils.contains("TUNE_FEATURES", "reorder", \
         bb.utils.contains("TUNE_FEATURES", "v8.30", \
             bb.utils.contains("TUNE_FEATURES", "pattern-compare", \
-                "-mxl-reorder", "-mno-xl-reorder", d), \
-            "-mxl-reorder", d), "-mno-xl-reorder", d)}"
+                " -mxl-reorder", " -mno-xl-reorder", d), \
+            " -mxl-reorder", d), " -mno-xl-reorder", d)}"
 
 # Feature package architecture formatting
 MBPKGARCH_TUNE = ""
diff --git a/meta/conf/machine/include/microblaze/feature-microblaze-math.inc b/meta/conf/machine/include/microblaze/feature-microblaze-math.inc
index a31516659c..cba0ae67e3 100644
--- a/meta/conf/machine/include/microblaze/feature-microblaze-math.inc
+++ b/meta/conf/machine/include/microblaze/feature-microblaze-math.inc
@@ -13,14 +13,14 @@ TUNECONFLICTS[fpu-hard] = "fpu-soft"
 TUNECONFLICTS[fpu-hard-extended] = "fpu-soft"
 
 # Compiler args
-TUNE_CCARGS += "${@bb.utils.contains_any('TUNE_FEATURES', ['multiply-low', 'multiply-high'], '-mno-xl-soft-mul', '-mxl-soft-mul', d)}"
-TUNE_CCARGS += "${@bb.utils.contains('TUNE_FEATURES', 'multiply-high', '-mxl-multiply-high', '', d)}"
+TUNE_CCARGS .= "${@bb.utils.contains_any('TUNE_FEATURES', ['multiply-low', 'multiply-high'], ' -mno-xl-soft-mul', ' -mxl-soft-mul', d)}"
+TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'multiply-high', ' -mxl-multiply-high', '', d)}"
 
-TUNE_CCARGS += "${@bb.utils.contains('TUNE_FEATURES', 'divide-hard', '-mno-xl-soft-div', '-mxl-soft-div', d)}"
+TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'divide-hard', ' -mno-xl-soft-div', ' -mxl-soft-div', d)}"
 
-TUNE_CCARGS += "${@bb.utils.contains('TUNE_FEATURES', 'fpu-soft', '', '', d)}"
-TUNE_CCARGS += "${@bb.utils.contains_any('TUNE_FEATURES', ['fpu-hard', 'fpu-hard-extended'], '-mhard-float', '', d)}"
-TUNE_CCARGS += "${@bb.utils.contains('TUNE_FEATURES', 'fpu-hard-extended', '-mxl-float-convert -mxl-float-sqrt', '', d)}"
+TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'fpu-soft', '', '', d)}"
+TUNE_CCARGS .= "${@bb.utils.contains_any('TUNE_FEATURES', ['fpu-hard', 'fpu-hard-extended'], ' -mhard-float', '', d)}"
+TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'fpu-hard-extended', ' -mxl-float-convert -mxl-float-sqrt', '', d)}"
 
 # Set target fpu (bitbake known target) to soft or hard (basic or extended)
 TARGET_FPU = "${@bb.utils.contains_any('TUNE_FEATURES', 'fpu-hard fpu-hard-extended', 'fpu-hard', 'fpu-soft', d)}"
-- 
2.17.1



  parent reply	other threads:[~2020-02-04 21:06 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-04 21:06 [PATCH v4 0/5] Microblaze tune updates Mark Hatle
2020-02-04 21:06 ` [PATCH v4 1/5] microblaze tune: change microblazeeb to microblaze Mark Hatle
2020-02-04 21:06 ` [PATCH v4 2/5] microblaze tune: Allow no version to be set Mark Hatle
2020-02-04 21:06 ` [PATCH v4 3/5] microblaze tune: Enable 64-bit Mark Hatle
2020-02-04 21:06 ` Mark Hatle [this message]
2020-02-04 21:06 ` [PATCH v4 5/5] Microblaze: Adjust Linux items from microblazeeb to microblaze Mark Hatle
2020-02-05 12:41 ` [PATCH v4 0/5] Microblaze tune updates Nathan Rossi

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=20200204210630.41960-5-mark.hatle@kernel.crashing.org \
    --to=mark.hatle@kernel.crashing.org \
    --cc=openembedded-core@lists.openembedded.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.