Changeset 943 for trunk/lib


Ignore:
Timestamp:
Mar 12, 2011, 8:18:22 AM (8 years ago)
Author:
cameron
Message:

scanto_ci and scanto bugfix

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/carryQ.h

    r934 r943  
    252252        BitBlock markers1;
    253253        CarryType c = cq[carryno];
    254         adc128(markers0, simd_andc(EOF_mask, charclass), c, markers1);
    255         return simd_and(markers1, charclass);
     254        BitBlock scanclass = simd_andc(EOF_mask, charclass);
     255        adc128(markers0, scanclass, c, markers1);
     256        return simd_andc(markers1, scanclass);
    256257}
    257258
     
    259260        BitBlock markers1;
    260261        CarryType c = Carry0;
    261         adc128(markers0, simd_andc(EOF_mask, charclass), c, markers1);
    262         return simd_and(markers1, charclass);
     262        BitBlock scanclass = simd_andc(EOF_mask, charclass);
     263        adc128(markers0, scanclass, c, markers1);
     264        return simd_andc(markers1, scanclass);
    263265}
    264266
     
    706708
    707709static inline BitBlock BitBlock_scanto_ci(BitBlock markers0, BitBlock charclass, BitBlock EOF_mask, CarryQtype & cq, const int carryno) {
    708         return simd_and(BitBlock_add_ci(markers0, simd_and(simd_not(charclass), EOF_mask), cq, carryno), charclass);
     710        BitBlock scanclass = simd_andc(EOF_mask, charclass);
     711        return simd_andc(BitBlock_add_ci(markers0, scanclass, cq, carryno), scanclass);
    709712}
    710713
    711714static inline BitBlock BitBlock_scanto(BitBlock markers0, BitBlock charclass, BitBlock EOF_mask) {
    712         return simd_and(BitBlock_add(markers0, simd_and(simd_not(charclass), EOF_mask)), charclass);
     715        BitBlock scanclass = simd_andc(EOF_mask, charclass);
     716        return simd_andc(BitBlock_add(markers0, scanclass, cq, carryno), scanclass);
    713717}
    714718
Note: See TracChangeset for help on using the changeset viewer.