示例#1
0
void CmdInstrument::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_type);
  thrift.write(m_enabled);
  ASSERT(m_instPoints);
  InstPointInfo::SendImpl(*m_instPoints, thrift);
}
void DebuggerCommand::sendImpl(DebuggerThriftBuffer &thrift) {
  TRACE(2, "DebuggerCommand::sendImpl\n");
  thrift.write((int32_t)m_type);
  thrift.write(m_class);
  thrift.write(m_body);
  thrift.write(m_version);
}
示例#3
0
void CmdMachine::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_sandboxes);
  thrift.write(m_rpcConfig);
  thrift.write(m_force);
  thrift.write(m_succeed);
}
示例#4
0
文件: cmd_list.cpp 项目: bd808/hhvm
// Always called from send and implements specific
// logic for serializing a list command to send via Thrift.
void CmdList::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_file);
  thrift.write(m_line1);
  thrift.write(m_line2);
  thrift.write(m_code);
}
示例#5
0
void CmdEval::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_output);
  thrift.write(m_frame);
  thrift.write(m_bypassAccessCheck);
  if (this->m_version == 2) thrift.write(m_failed);
}
void CmdInternalTesting::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_arg);
  // Write less data on purpose, to get the server to choke on deserialization
  if ((m_arg != "shortcmd")) {
    thrift.write(m_unused);
  }
}
示例#7
0
void CmdWhere::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  {
    String sdata;
    DebuggerWireHelpers::WireSerialize(m_stacktrace, sdata);
    thrift.write(sdata);
  }
  thrift.write(m_stackArgs);
}
示例#8
0
void CmdVariable::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_frame);
  {
    String sdata;
    DebuggerWireHelpers::WireSerialize(m_variables, sdata);
    thrift.write(sdata);
  }
  thrift.write(m_global);
}
示例#9
0
void InstPointInfo::sendImpl(DebuggerThriftBuffer &thrift) {
  TRACE(2, "InstPointInfo::sendImpl\n");
  thrift.write(m_locType);
  thrift.write(m_valid);
  thrift.write(m_file);
  thrift.write(m_line);
  thrift.write(m_func);
  thrift.write(m_desc);
  thrift.write(m_code);
}
示例#10
0
void CmdPrint::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  if (m_printLevel > 0) {
    g_context->setDebuggerPrintLevel(m_printLevel);
  }
  thrift.write(m_ret);
  if (m_printLevel > 0) {
    g_context->setDebuggerPrintLevel(-1);
  }
  thrift.write(m_output);
  thrift.write(m_frame);
  thrift.write(m_bypassAccessCheck);
  thrift.write(m_printLevel);
}
示例#11
0
void InstPointInfo::SendImpl(const InstPointInfoPtrVec& ips,
                             DebuggerThriftBuffer &thrift) {
  TRACE(2, "InstPointInfo::SendImpl\n");
  int16_t size = ips.size();
  thrift.write(size);
  for (int i = 0; i < size; i++) {
    ips[i]->sendImpl(thrift);
  }
}
示例#12
0
void CmdVariable::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_frame);
  {
    String sdata;
    DebuggerWireHelpers::WireSerialize(m_variables, sdata);
    thrift.write(sdata);
  }
  thrift.write(m_global);
  if (m_version == 2) {
    thrift.write(m_formatMaxLen);
    thrift.write(m_varName);
    thrift.write(m_filter);
  }
}
示例#13
0
void CmdPrint::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  if (m_printLevel > 0) {
    g_context->setDebuggerPrintLevel(m_printLevel);
  }
  {
    String sdata;
    DebuggerWireHelpers::WireSerialize(m_ret, sdata);
    thrift.write(sdata);
  }
  if (m_printLevel > 0) {
    g_context->setDebuggerPrintLevel(-1);
  }
  thrift.write(m_output);
  thrift.write(m_frame);
  thrift.write(m_bypassAccessCheck);
  thrift.write(m_printLevel);
  thrift.write(m_noBreak);
}
示例#14
0
void CmdShell::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_args);
  thrift.write(m_out);
}
示例#15
0
void CmdFlowControl::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_count);
}
示例#16
0
void CmdThread::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_out);
  thrift.write(m_threads);
}
示例#17
0
void CmdRun::sendImpl(DebuggerThriftBuffer &thrift) {
  TRACE(2, "CmdRun::sendImpl\n");
  DebuggerCommand::sendImpl(thrift);
  thrift.write(*m_args);
}
示例#18
0
void CmdExample::sendImpl(DebuggerThriftBuffer &thrift) {
  CmdExtended::sendImpl(thrift);
  thrift.write(m_input);
  thrift.write(m_output);
}
示例#19
0
void CmdSignal::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_signum);
}
示例#20
0
void CmdExtension::sendImpl(DebuggerThriftBuffer &thrift) {
  CmdExtended::sendImpl(thrift);
  thrift.write(m_args);
  thrift.write(m_out);
  thrift.write(m_err);
}
示例#21
0
void CmdVariable::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_frame);
  thrift.write(m_variables);
  thrift.write(m_global);
}
示例#22
0
void CmdGlobal::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_globals);
}
示例#23
0
void CmdInterrupt::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_interrupt);
  thrift.write(m_program);
  thrift.write(m_errorMsg);
  thrift.write(m_threadId);
  thrift.write(m_pendingJump);
  if (m_site) {
    thrift.write(true);
    thrift.write(m_site->getFile());
    thrift.write(m_site->getLine0());
    thrift.write(m_site->getChar0());
    thrift.write(m_site->getLine1());
    thrift.write(m_site->getChar1());
    thrift.write(m_site->getNamespace());
    thrift.write(m_site->getClass());
    thrift.write(m_site->getFunction());
    Variant e = m_site->getException();
    if (e.isNull()) {
      thrift.write("");
    } else if (e.isObject()) {
      thrift.write(e.toObject()->o_getClassName());
    } else {
      String ex(BreakPointInfo::ErrorClassName);
      thrift.write(ex);
    }
    thrift.write(e.toString());
  } else {
    thrift.write(false);
  }
  BreakPointInfo::SendImpl(m_matched, thrift);
}
示例#24
0
void CmdRun::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(*m_args);
}
示例#25
0
void CmdInterrupt::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  assert(m_interrupt != ExceptionHandler); // Server-side only.
  thrift.write(m_interrupt);
  thrift.write(m_program);
  thrift.write(m_errorMsg);
  thrift.write(m_threadId);
  // Used to be m_pendingJump, but that's been removed. Write false until
  // we rev the protocol.
  thrift.write(false);
  if (m_site) {
    thrift.write(true);
    thrift.write(m_site->getFile());
    thrift.write(m_site->getLine0());
    thrift.write(m_site->getChar0());
    thrift.write(m_site->getLine1());
    thrift.write(m_site->getChar1());
    thrift.write(m_site->getNamespace());
    thrift.write(m_site->getClass());
    thrift.write(m_site->getFunction());
    Variant e = m_site->getError();
    if (e.isNull()) {
      thrift.write("");
    } else if (e.isObject()) {
      thrift.write(e.toObject()->getClassName());
    } else {
      String ex(BreakPointInfo::ErrorClassName);
      thrift.write(ex);
    }
    thrift.write(e.toString());
  } else {
    thrift.write(false);
  }
  BreakPointInfo::SendImpl(0, m_matched, thrift);
}
示例#26
0
void CmdUser::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_cmd);
}
示例#27
0
void DebuggerCommand::sendImpl(DebuggerThriftBuffer &thrift) {
  thrift.write((int32)m_type);
  thrift.write(m_class);
  thrift.write(m_body);
  thrift.write(m_version);
}
示例#28
0
void CmdWhere::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_stacktrace);
}
示例#29
0
void CmdHeaptrace::sendImpl(DebuggerThriftBuffer &thrift) {
  DebuggerCommand::sendImpl(thrift);
  thrift.write(m_accum.typesMap);
  thrift.write(m_accum.sizeMap);
  thrift.write(m_accum.adjacencyList);
}
示例#30
0
void CmdEval::sendImpl(DebuggerThriftBuffer &thrift) {
    DebuggerCommand::sendImpl(thrift);
    thrift.write(m_output);
    thrift.write(m_frame);
    thrift.write(m_bypassAccessCheck);
}