From 74bd48fb964a25d6fe9d0b90cf0f2d37c074e000 Mon Sep 17 00:00:00 2001 From: lkcl Date: Sat, 12 Jun 2021 21:12:50 +0100 Subject: [PATCH] --- openpower/sv/bitmanip.mdwn | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/openpower/sv/bitmanip.mdwn b/openpower/sv/bitmanip.mdwn index 5e26870fb..b623deb4c 100644 --- a/openpower/sv/bitmanip.mdwn +++ b/openpower/sv/bitmanip.mdwn @@ -284,6 +284,10 @@ however bitmask-invert is not, and set/clr are not covered, although they can us bmext (RB) version is not the same as rldicl because bmext is a right shift by RC, where rldicl is a left rotate. for the immediate version this does not matter, so a bmexti is not required. bmrev however there is no direct equivalent and consequently a bmrevi is required. +bmset (register for mask amount) is particularly useful for creating +predicate masks where the length is a dynamic runtime quantity. +bmset(RA=0, RB=0, RC=mask) will produce a run of ones of length "mask" in a single instruction without needing to initialise or depend on any other registers. + | 0.5|6.10|11.15|16.20|21.25| 26..30 |31| name | | -- | -- | --- | --- | --- | ------- |--| ----- | | NN | RT | RA | RB | RC | mode 010 |Rc| bm* | -- 2.30.2