The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: toby@telegraphics.com.au (Toby Thain)
Subject: [TUHS] PowerPC, bit twiddling - was Re:  origins of void* -- Apology!
Date: Fri, 10 Nov 2017 18:43:19 -0500	[thread overview]
Message-ID: <92767af5-6aa5-666a-4a61-4956c2dbbd74@telegraphics.com.au> (raw)
In-Reply-To: <42D46D6E-46F4-49E9-A76B-360A812DBBB0@gmail.com>

On 2017-11-09 2:14 AM, Don Hopkins wrote:
> 
>> On 9 Nov 2017, at 07:37, Lars Brinkhoff <lars at nocrew.org
>> <mailto:lars at nocrew.org>> wrote:
>>
>> Bakul Shah wrote:
>>> I agree that `char' shouldn't do double duty as the smallest
>>> addressable unit and I was suggesing uint8_t does that job.
>>
>> There are still machines around where 8-bit bytes isn't a natural fit.
> 
> 1 bit bytes, the smallest addressable unit on the PDP-10, sounds kinda
> cool actually. Now would those be signed or unsigned?
> 
> The PowerPC was great at smashing and swizzling bit fields ...

It's funny you should mention "1-bit bytes" and PowerPC close together,
because the PowerPC has an architectural feature that I have not seen
discussed much - the 8 x 4 bit CR register set, and the Conditional
Register Logical instructions that can operate on them directly as if
they were 32 single bit registers, with operations AND, OR, XOR, NAND,
NOR, EQV (complemented XOR), AND complemented operand, OR complemented
operand, move between 4-bit fields, and of course the usual branch tests.

I have been curious about whether a compiler could make good use of this
facility.

--Toby




> 
> -Don
> 



  parent reply	other threads:[~2017-11-10 23:43 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-04 10:19 [TUHS] origins of void* Paul Ruizendaal
2017-11-05  9:48 ` Clem Cole
2017-11-05 10:06 ` arnold
2017-11-05 13:20   ` Ron Natalie
2017-11-05 15:14     ` Warner Losh
2017-11-05 17:53       ` Clem cole
2017-11-05 18:29         ` Steve Simon
2017-11-05 20:12           ` Clem cole
2017-11-05 21:08             ` Chet Ramey
2017-11-05 21:38               ` Clem cole
2017-11-05 21:53             ` Steve Simon
2017-11-05 20:44   ` Paul Ruizendaal
2017-11-05 21:06     ` Warner Losh
2017-11-06  7:24     ` arnold
2017-11-06 15:02       ` Warner Losh
2017-11-06 21:46         ` [TUHS] origins of void* -- Apology! Steve Johnson
2017-11-06 22:18           ` Warner Losh
2017-11-07  0:25           ` Ron Natalie
2017-11-07  0:34             ` Arthur Krewat
2017-11-07  0:36               ` Ron Natalie
2017-11-07  1:09             ` Bakul Shah
2017-11-07  1:55               ` Ron Natalie
2017-11-08 17:44               ` Ralph Corderoy
2017-11-08 19:56                 ` Ron Natalie
2017-11-08 20:39                   ` Don Hopkins
2017-11-08 20:42                     ` Ron Natalie
2017-11-08 20:47                       ` Don Hopkins
2017-11-08 20:48                         ` Don Hopkins
2017-11-08 20:43                     ` Don Hopkins
2017-11-08 20:43                     ` Clem Cole
2017-11-08 20:45                     ` Warner Losh
2017-11-09  6:33                       ` Lars Brinkhoff
2017-11-08 20:50                   ` Steve Nickolas
2017-11-08 21:25                 ` Bakul Shah
2017-11-09  6:37                   ` Lars Brinkhoff
2017-11-09  7:14                     ` Don Hopkins
2017-11-09  7:44                       ` Lars Brinkhoff
2017-11-10 23:43                       ` Toby Thain [this message]
2017-11-10 23:58                         ` [TUHS] PowerPC, bit twiddling - was " Ralph Corderoy

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=92767af5-6aa5-666a-4a61-4956c2dbbd74@telegraphics.com.au \
    --to=toby@telegraphics.com.au \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).