data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh
1: b'%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:23: Unsupported: classes\nclass spi_env extends uvm_env;\n^~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:23: syntax error, unexpected IDENTIFIER, expecting TYPE-IDENTIFIER\nclass spi_env extends uvm_env;\n                      ^~~~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:27: Define or directive not defined: \'`uvm_component_utils\'\n`uvm_component_utils(spi_env)\n^~~~~~~~~~~~~~~~~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:49: Unsupported: new constructor\nextern function new(string name = "spi_env", uvm_component parent = null);\n                ^~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:49: syntax error, unexpected IDENTIFIER, expecting \')\'\nextern function new(string name = "spi_env", uvm_component parent = null);\n                                                           ^~~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:50: syntax error, unexpected IDENTIFIER, expecting \')\'\nextern function void build_phase(uvm_phase phase);\n                                           ^~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:51: syntax error, unexpected IDENTIFIER, expecting \')\'\nextern function void connect_phase(uvm_phase phase);\n                                             ^~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:55: Unsupported: Hierarchical class references\nfunction spi_env::new(string name = "spi_env", uvm_component parent = null);\n                ^~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:55: Unsupported: scoped class reference\nfunction spi_env::new(string name = "spi_env", uvm_component parent = null);\n                     ^\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:55: Unsupported: scoped new constructor\nfunction spi_env::new(string name = "spi_env", uvm_component parent = null);\n                  ^~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:55: syntax error, unexpected IDENTIFIER, expecting \')\'\nfunction spi_env::new(string name = "spi_env", uvm_component parent = null);\n                                                             ^~~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:59: Unsupported: Hierarchical class references\nfunction void spi_env::build_phase(uvm_phase phase);\n                     ^~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:59: Unsupported: scoped class reference\nfunction void spi_env::build_phase(uvm_phase phase);\n                       ^~~~~~~~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:55: Unsupported: Out of class block function declaration\nfunction spi_env::new(string name = "spi_env", uvm_component parent = null);\n                  ^~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:59: syntax error, unexpected IDENTIFIER, expecting \')\'\nfunction void spi_env::build_phase(uvm_phase phase);\n                                             ^~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:61: Define or directive not defined: \'`uvm_error\'\n                                                                                      : ... Suggested alternative: \'`error\'\n    `uvm_error("build_phase", "Failed to find spi_env_config")\n    ^~~~~~~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:81: Unsupported: Hierarchical class references\nfunction void spi_env::connect_phase(uvm_phase phase);\n                     ^~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:81: Unsupported: scoped class reference\nfunction void spi_env::connect_phase(uvm_phase phase);\n                       ^~~~~~~~~~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:59: Unsupported: Out of class block function declaration\nfunction void spi_env::build_phase(uvm_phase phase);\n                       ^~~~~~~~~~~\n%Error: data/full_repos/permissive/506636840/block_level_tbs/spi_tb/env/spi_env.svh:81: syntax error, unexpected IDENTIFIER, expecting \')\'\nfunction void spi_env::connect_phase(uvm_phase phase);\n                                               ^~~~~\n%Error: Exiting due to 20 error(s)\n        ... See the manual and https://verilator.org for more assistance.\n'
function void spi_env::connect_phase(uvm_phase phase);
  if(m_cfg.m_apb_agent_cfg.active == UVM_ACTIVE) begin
    reg2apb = apb2reg_adapter::type_id::create("reg2apb");




    if(m_cfg.spi_rm.get_parent() == null) begin
      m_cfg.spi_rm.APB_map.set_sequencer(m_apb_agent.m_sequencer, reg2apb);
    end






    apb2reg_predictor.map = m_cfg.spi_rm.APB_map;

    apb2reg_predictor.adapter = reg2apb;

    m_cfg.spi_rm.APB_map.set_auto_predict(0);

    m_apb_agent.ap.connect(apb2reg_predictor.bus_in);
  end
  if(m_cfg.has_spi_functional_coverage) begin
    m_apb_agent.ap.connect(m_func_cov_monitor.analysis_export);
    m_func_cov_monitor.spi_rm = m_cfg.spi_rm;
  end
  if(m_cfg.has_spi_scoreboard) begin
    m_spi_agent.ap.connect(m_scoreboard.spi.analysis_export);
    m_scoreboard.spi_rm = m_cfg.spi_rm;
  end

  uvm_config_db #(apb_sequencer)::set(null, "*", "apb_sequencer", m_apb_agent.m_sequencer);
  uvm_config_db #(spi_sequencer)::set(null, "*", "spi_sequencer", m_spi_agent.m_sequencer);
endfunction
function void spi_env::connect_phase(uvm_phase phase);

  if(m_cfg.m_apb_agent_cfg.active == UVM_ACTIVE) begin
    reg2apb = apb2reg_adapter::type_id::create("reg2apb");




    if(m_cfg.spi_rm.get_parent() == null) begin
      m_cfg.spi_rm.APB_map.set_sequencer(m_apb_agent.m_sequencer, reg2apb);
    end






    apb2reg_predictor.map = m_cfg.spi_rm.APB_map;

    apb2reg_predictor.adapter = reg2apb;

    m_cfg.spi_rm.APB_map.set_auto_predict(0);

    m_apb_agent.ap.connect(apb2reg_predictor.bus_in);
  end
  if(m_cfg.has_spi_functional_coverage) begin
    m_apb_agent.ap.connect(m_func_cov_monitor.analysis_export);
    m_func_cov_monitor.spi_rm = m_cfg.spi_rm;
  end
  if(m_cfg.has_spi_scoreboard) begin
    m_spi_agent.ap.connect(m_scoreboard.spi.analysis_export);
    m_scoreboard.spi_rm = m_cfg.spi_rm;
  end

  uvm_config_db #(apb_sequencer)::set(null, "*", "apb_sequencer", m_apb_agent.m_sequencer);
  uvm_config_db #(spi_sequencer)::set(null, "*", "spi_sequencer", m_spi_agent.m_sequencer);
endfunction