Ignore:
Timestamp:
Jun 13, 2018, 9:51:17 PM (10 months ago)
Author:
cameron
Message:

IDISA builder updates for esimd_mergel/h

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/IR_Gen/idisa_sse_builder.cpp

    r6076 r6087  
    188188}
    189189
    190 Constant * IDISA_SSSE3_Builder::bit_interleave_byteshuffle_table(unsigned fw) {
    191     const unsigned fieldCount = mBitBlockWidth/8;
    192     if (fw > 2) llvm::report_fatal_error("bit_interleave_byteshuffle_table requires fw == 1 or fw == 2");
    193     // Bit interleave using shuffle.
    194     // Make a shuffle table that translates the lower 4 bits of each byte in
    195     // order to spread out the bits: xxxxdcba => .d.c.b.a (fw = 1)
    196     Constant * bit_interleave[fieldCount];
    197     for (unsigned i = 0; i < fieldCount; i++) {
    198         if (fw == 1)
    199             bit_interleave[i] = getInt8((i & 1) | ((i & 2) << 1) | ((i & 4) << 2) | ((i & 8) << 3));
    200         else bit_interleave[i] = getInt8((i & 3) | ((i & 0x0C) << 2));
    201     }
    202     return ConstantVector::get({bit_interleave, fieldCount});
    203 }
    204 
    205190Value * IDISA_SSSE3_Builder::esimd_mergeh(unsigned fw, Value * a, Value * b) {
    206191    if ((fw == 1) || (fw == 2)) {
Note: See TracChangeset for help on using the changeset viewer.