Commit baee0670 authored by unknown's avatar unknown
Browse files

tux optim 8 - store complete AttributeDescriptor (prepare for next step)

parent 41c3dc08
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -318,10 +318,9 @@ private:
   * Attribute metadata.  Size must be multiple of word size.
   */
  struct DescAttr {
    unsigned m_primaryAttrId : 16;
    unsigned m_typeId : 8;
    unsigned m_nullable : 1;
    unsigned pad1 : 7;
    Uint32 m_attrDesc;          // standard AttributeDescriptor
    Uint16 m_primaryAttrId;
    Uint16 m_typeId;
  };
  static const unsigned DescAttrSize = sizeof(DescAttr) >> 2;

+1 −1
Original line number Diff line number Diff line
@@ -264,9 +264,9 @@ NdbOut&
operator<<(NdbOut& out, const Dbtux::DescAttr& descAttr)
{
  out << "[DescAttr " << hex << &descAttr;
  out << " [attrDesc " << hex << descAttr.m_attrDesc;
  out << " [primaryAttrId " << dec << descAttr.m_primaryAttrId << "]";
  out << " [typeId " << dec << descAttr.m_typeId << "]";
  out << " [nullable " << dec << descAttr.m_nullable << "]";
  out << "]";
  return out;
}
+1 −2
Original line number Diff line number Diff line
@@ -181,10 +181,9 @@ Dbtux::execTUX_ADD_ATTRREQ(Signal* signal)
    // define the attribute
    DescEnt& descEnt = getDescEnt(indexPtr.p->m_descPage, indexPtr.p->m_descOff);
    DescAttr& descAttr = descEnt.m_descAttr[attrId];
    descAttr.m_attrDesc = req->attrDescriptor;
    descAttr.m_primaryAttrId = req->primaryAttrId;
    descAttr.m_typeId = req->extTypeInfo & 0xFF;
    descAttr.m_nullable = AttributeDescriptor::getNullable(req->attrDescriptor);
    descAttr.pad1 = 0;
#ifdef VM_TRACE
    if (debugFlags & DebugMeta) {
      debugOut << "Add frag " << fragPtr.i << " attr " << attrId << " " << descAttr << endl;
+4 −0
Original line number Diff line number Diff line
@@ -37,4 +37,8 @@ optim 6 mc02/a 42 ms 70 ms 66 pct
optim 7         mc02/a  42 ms   69 ms    61 pct
                mc02/b  52 ms  106 ms   101 pct

optim 8         mc02/a  42 ms   69 ms    62 pct
                mc02/b  54 ms  104 ms    92 pct


vim: set et: