Ejemplo n.º 1
0
Archivo: io.hpp Proyecto: B-Rich/EbbRT
inline void
ebbrt::out32(uint32_t val, uint16_t port)
{
#ifdef __linux__
  assert(0);
#elif __ebbrt__
  LRT_ASSERT(0);
#endif
}
Ejemplo n.º 2
0
Archivo: io.hpp Proyecto: B-Rich/EbbRT
inline uint32_t
ebbrt::in32(uint16_t port)
{
#ifdef __linux__
  assert(0);
#elif __ebbrt__
  LRT_ASSERT(0);
#endif
  return 0;
}
Ejemplo n.º 3
0
void
ebbrt::LocalConsole::Write(const char* str,
                            std::function<void()> cb)
{
#ifdef __linux__
  assert(!cb);
  std::cout << str;
#elif __ebbrt__
  LRT_ASSERT(!cb);
  lrt::console::write(str);
#endif
}
Ejemplo n.º 4
0
void
ebbrt::RemoteConsole::HandleMessage(NetworkId from,
                                    Buffer buffer)
{
#ifdef __linux__
#ifndef __bg__
  std::cout << buffer.data();
#else
  int rank;
  MPI_Comm_rank(MPI_COMM_WORLD, &rank);
  if (rank == 0) {
    std::cout << buffer.data();
  } else {
    assert(0);
  }
#endif
#elif __ebbrt__
  LRT_ASSERT(0);
#endif
}