Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
s_shiftRightM.c File Reference
#include <stdint.h>
#include "platform.h"
#include "primitives.h"
Include dependency graph for s_shiftRightM.c:

Go to the source code of this file.

Macros

#define softfloat_shiftRightM   softfloat_shiftRightM
 

Functions

void softfloat_shiftRightM (uint_fast8_t size_words, const uint32_t *aPtr, uint32_t dist, uint32_t *zPtr)
 

Macro Definition Documentation

◆ softfloat_shiftRightM

#define softfloat_shiftRightM   softfloat_shiftRightM

Definition at line 42 of file s_shiftRightM.c.

Function Documentation

◆ softfloat_shiftRightM()

void softfloat_shiftRightM ( uint_fast8_t size_words,
const uint32_t * aPtr,
uint32_t dist,
uint32_t * zPtr )

Definition at line 46 of file s_shiftRightM.c.

52{
53 uint32_t wordDist;
54 uint_fast8_t innerDist;
55 uint32_t *destPtr;
57
58 wordDist = dist>>5;
59 if ( wordDist < size_words ) {
60 aPtr += indexMultiwordHiBut( size_words, wordDist );
61 innerDist = dist & 31;
62 if ( innerDist ) {
64 size_words - wordDist,
65 aPtr,
66 innerDist,
67 zPtr + indexMultiwordLoBut( size_words, wordDist )
68 );
69 if ( ! wordDist ) return;
70 } else {
71 aPtr += indexWordLo( size_words - wordDist );
72 destPtr = zPtr + indexWordLo( size_words );
73 for ( i = size_words - wordDist; i; --i ) {
74 *destPtr = *aPtr;
75 aPtr += wordIncr;
76 destPtr += wordIncr;
77 }
78 }
79 zPtr += indexMultiwordHi( size_words, wordDist );
80 } else {
81 wordDist = size_words;
82 }
83 do {
84 *zPtr++ = 0;
85 --wordDist;
86 } while ( wordDist );
87
88}
#define indexMultiwordHi(total, n)
#define wordIncr
#define indexWordLo(total)
#define indexMultiwordHiBut(total, n)
#define indexMultiwordLoBut(total, n)
void softfloat_shortShiftRightM(uint_fast8_t size_words, const uint32_t *aPtr, uint_fast8_t dist, uint32_t *zPtr)
unsigned int uint32_t
Definition stdint.h:126
uint8_t uint_fast8_t
Definition stdint.h:154
Here is the call graph for this function: