ccRCR
ccRCL

Syntax

Uint64 = ccRCR(Target:Uint64,OPT CandC = 1:Word/or Word ByRef)
Uint64 = ccRCL(Target:Uint64,OPT CandC = 1:Word/or Word ByRef)

Description

Rotate trough Carry Right or
Rotate trough Carry Left on 64 bits Variable.

    .-.         .-----------------.
.--|C|<----|63 <---------- 0|<----.
|   '-'        '------------------'        |
'------------------------------------'
    .-.         .-----------------.
.--|C|---->|63 <---------- 0|---->.
|   '-'        '------------------'        |
'------------------------------------'

CandC = CandC|Carry << 9

Parameters

Target - Variable which bits will be rotated.
CandC - Counter for the bits being rotated. And in it's 8-th bit the Carry rotated in.

Return value

A Uint64 Rotated
'CandC' will contain 'CandC' and in it's 8-th bit the value of the last bit rotated out

Remarks

Sample:
By bit 8 = 1 of 'CandC' ccRCL("....00001",3) will result "....01100"
ccRCR("1000....",3) = > "0011....."

To get the Carry use Carry = CandC >> 8
And you have to give the 'CandC' Byref!!!
Like :
R = ccRCR(R,&CandC)

Example usage

R = ccRCR(R,S)
R = ccRCL(R,3)

See
Logics_Demo.eba