Changeset 1212 for trunk


Ignore:
Timestamp:
Jul 6, 2011, 3:03:29 PM (8 years ago)
Author:
cameron
Message:

Bitblock_advance32 versions

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/carryQ.h

    r1197 r1212  
    108108static inline BitBlock BitBlock_advance(BitBlock strm) __attribute__ ((always_inline));
    109109
     110static inline BitBlock BitBlock_advance32_ci_co(BitBlock strm, uint32_t & pending32) __attribute__ ((always_inline));
     111
     112static inline BitBlock BitBlock_advance32_ci(BitBlock strm, uint32_t & pending32) __attribute__ ((always_inline));
     113
     114static inline BitBlock BitBlock_advance32_co(BitBlock strm, uint32_t & pending32) __attribute__ ((always_inline));
     115
     116static inline BitBlock BitBlock_advance32(BitBlock strm) __attribute__ ((always_inline));
     117
    110118static inline BitBlock BitBlock_add_ci_co(BitBlock strm1, BitBlock strm2, CarryQtype cq, const int carryno) __attribute__ ((always_inline));
    111119
     
    174182        return sisd_slli(strm, 1);
    175183}
     184
     185static inline BitBlock BitBlock_advance32_ci_co(BitBlock strm, uint32_t & pending32){
     186        uint32_t temp = pending32;
     187        pending32 = sisd_to_int(sisd_srli(strm,96));
     188        return simd_or(sisd_slli(strm, 32), sisd_from_int(temp));
     189}
     190
     191static inline BitBlock BitBlock_advance32_ci(BitBlock strm, uint32_t & pending32) {
     192        return simd_or(sisd_slli(strm, 32), sisd_from_int(pending32));
     193}
     194
     195static inline BitBlock BitBlock_advance32_co(BitBlock strm, uint32_t & pending32) {
     196        pending32 = sisd_to_int(sisd_srli(strm,96));
     197        return sisd_slli(strm, 32);
     198}
     199
     200static inline BitBlock BitBlock_advance32(BitBlock strm) {
     201        return sisd_slli(strm, 32);
     202}
     203
     204
     205
    176206
    177207static inline BitBlock BitBlock_add_ci_co(BitBlock strm1, BitBlock strm2, CarryQtype cq, const int carryno) {
Note: See TracChangeset for help on using the changeset viewer.