text: // ==============================================================
  // RTL generated by Vivado(TM) HLS - High-Level Synthesis from C, C++ and SystemC
  // Version: 2017.2
  // Copyright (C) 1986-2017 Xilinx, Inc. All Rights Reserved.
  // 
  // ===========================================================
  
  #include "linebuffer.h"
  #include "AESL_pkg.h"
  
  using namespace std;
  
  namespace ap_rtl {
  
  const sc_logic linebuffer::ap_const_logic_0 = sc_dt::Log_0;
  const sc_lv<72> linebuffer::ap_const_lv72_0 = "000000000000000000000000000000000000000000000000000000000000000000000000";
  const sc_logic linebuffer::ap_const_logic_1 = sc_dt::Log_1;
  
  linebuffer::linebuffer(sc_module_name name) : sc_module(name), mVcdFile(0) {
      call_U0 = new call("call_U0");
      call_U0->in_stream_V_value_V_dout(in_stream_V_value_V_dout);
      call_U0->in_stream_V_value_V_empty_n(in_stream_V_value_V_empty_n);
      call_U0->in_stream_V_value_V_read(call_U0_in_stream_V_value_V_read);
      call_U0->out_stream_V_value_V_din(call_U0_out_stream_V_value_V_din);
      call_U0->out_stream_V_value_V_full_n(out_stream_V_value_V_full_n);
      call_U0->out_stream_V_value_V_write(call_U0_out_stream_V_value_V_write);
      call_U0->ap_clk(ap_clk);
      call_U0->ap_rst(ap_rst);
      call_U0->ap_done(call_U0_ap_done);
      call_U0->ap_start(call_U0_ap_start);
      call_U0->ap_ready(call_U0_ap_ready);
      call_U0->ap_idle(call_U0_ap_idle);
      call_U0->ap_continue(call_U0_ap_continue);
  
      SC_METHOD(thread_ap_done);
      sensitive << ( call_U0_ap_done );
  
      SC_METHOD(thread_ap_idle);
      sensitive << ( call_U0_ap_idle );
  
      SC_METHOD(thread_ap_ready);
      sensitive << ( call_U0_ap_ready );
  
      SC_METHOD(thread_ap_sync_continue);
      sensitive << ( ap_continue );
  
      SC_METHOD(thread_ap_sync_done);
      sensitive << ( call_U0_ap_done );
  
      SC_METHOD(thread_ap_sync_ready);
      sensitive << ( call_U0_ap_ready );
  
      SC_METHOD(thread_call_U0_ap_continue);
      sensitive << ( ap_continue );
  
      SC_METHOD(thread_call_U0_ap_start);
      sensitive << ( ap_rst );
      sensitive << ( ap_start );
  
      SC_METHOD(thread_call_U0_start_full_n);
  
      SC_METHOD(thread_call_U0_start_write);
  
      SC_METHOD(thread_in_stream_V_value_V_read);
      sensitive << ( call_U0_in_stream_V_value_V_read );
  
      SC_METHOD(thread_out_stream_V_value_V_din);
      sensitive << ( call_U0_out_stream_V_value_V_din );
  
      SC_METHOD(thread_out_stream_V_value_V_write);
      sensitive << ( call_U0_out_stream_V_value_V_write );
  
      static int apTFileNum = 0;
      stringstream apTFilenSS;
      apTFilenSS << "linebuffer_sc_trace_" << apTFileNum ++;
      string apTFn = apTFilenSS.str();
      mVcdFile = sc_create_vcd_trace_file(apTFn.c_str());
      mVcdFile->set_time_unit(1, SC_PS);
      if (1) {
  #ifdef __HLS_TRACE_LEVEL_PORT_HIER__
      sc_trace(mVcdFile, in_stream_V_value_V_dout, "(port)in_stream_V_value_V_dout");
      sc_trace(mVcdFile, in_stream_V_value_V_empty_n, "(port)in_stream_V_value_V_empty_n");
      sc_trace(mVcdFile, in_stream_V_value_V_read, "(port)in_stream_V_value_V_read");
      sc_trace(mVcdFile, out_stream_V_value_V_din, "(port)out_stream_V_value_V_din");
      sc_trace(mVcdFile, out_stream_V_value_V_full_n, "(port)out_stream_V_value_V_full_n");
      sc_trace(mVcdFile, out_stream_V_value_V_write, "(port)out_stream_V_value_V_write");
      sc_trace(mVcdFile, ap_clk, "(port)ap_clk");
      sc_trace(mVcdFile, ap_rst, "(port)ap_rst");
      sc_trace(mVcdFile, ap_done, "(port)ap_done");
      sc_trace(mVcdFile, ap_start, "(port)ap_start");
      sc_trace(mVcdFile, ap_ready, "(port)ap_ready");
      sc_trace(mVcdFile, ap_idle, "(port)ap_idle");
      sc_trace(mVcdFile, ap_continue, "(port)ap_continue");
  #endif
  #ifdef __HLS_TRACE_LEVEL_INT__
      sc_trace(mVcdFile, call_U0_in_stream_V_value_V_read, "call_U0_in_stream_V_value_V_read");
      sc_trace(mVcdFile, call_U0_out_stream_V_value_V_din, "call_U0_out_stream_V_value_V_din");
      sc_trace(mVcdFile, call_U0_out_stream_V_value_V_write, "call_U0_out_stream_V_value_V_write");
      sc_trace(mVcdFile, call_U0_ap_done, "call_U0_ap_done");
      sc_trace(mVcdFile, call_U0_ap_start, "call_U0_ap_start");
      sc_trace(mVcdFile, call_U0_ap_ready, "call_U0_ap_ready");
      sc_trace(mVcdFile, call_U0_ap_idle, "call_U0_ap_idle");
      sc_trace(mVcdFile, call_U0_ap_continue, "call_U0_ap_continue");
      sc_trace(mVcdFile, ap_sync_continue, "ap_sync_continue");
      sc_trace(mVcdFile, ap_sync_done, "ap_sync_done");
      sc_trace(mVcdFile, ap_sync_ready, "ap_sync_ready");
      sc_trace(mVcdFile, call_U0_start_full_n, "call_U0_start_full_n");
      sc_trace(mVcdFile, call_U0_start_write, "call_U0_start_write");
  #endif
  
      }
  }
  
  linebuffer::~linebuffer() {
      if (mVcdFile) 
          sc_close_vcd_trace_file(mVcdFile);
  
      delete call_U0;
  }
  
  void linebuffer::thread_ap_done() {
      ap_done = call_U0_ap_done.read();
  }
  
  void linebuffer::thread_ap_idle() {
      ap_idle = call_U0_ap_idle.read();
  }
  
  void linebuffer::thread_ap_ready() {
      ap_ready = call_U0_ap_ready.read();
  }
  
  void linebuffer::thread_ap_sync_continue() {
      ap_sync_continue = ap_continue.read();
  }
  
  void linebuffer::thread_ap_sync_done() {
      ap_sync_done = call_U0_ap_done.read();
  }
  
  void linebuffer::thread_ap_sync_ready() {
      ap_sync_ready = call_U0_ap_ready.read();
  }
  
  void linebuffer::thread_call_U0_ap_continue() {
      call_U0_ap_continue = ap_continue.read();
  }
  
  void linebuffer::thread_call_U0_ap_start() {
      if ( ap_rst.read() == ap_const_logic_1) {
          call_U0_ap_start = ap_const_logic_0;
      } else {
          call_U0_ap_start = ap_start.read();
      }
  }
  
  void linebuffer::thread_call_U0_start_full_n() {
      call_U0_start_full_n = ap_const_logic_0;
  }
  
  void linebuffer::thread_call_U0_start_write() {
      call_U0_start_write = ap_const_logic_0;
  }
  
  void linebuffer::thread_in_stream_V_value_V_read() {
      in_stream_V_value_V_read = call_U0_in_stream_V_value_V_read.read();
  }
  
  void linebuffer::thread_out_stream_V_value_V_din() {
      out_stream_V_value_V_din = call_U0_out_stream_V_value_V_din.read();
  }
  
  void linebuffer::thread_out_stream_V_value_V_write() {
      out_stream_V_value_V_write = call_U0_out_stream_V_value_V_write.read();
  }
  
  }
  
  