Jump to content


  • Content Count

  • Joined

  • Last visited

About mpeer

  • Rank
    Junior Member
  • Birthday 10/20/1982
  1. Hi enchanter, I made change in run_phase(). I moved trans t = new() inside repeat(10); Below is the code after change. task run_phase(uvm_phase phase); // trans t = new(); // Removed from this line trans t2; $display("Fifo capacity is %0d", fifo.size()); $display("Putting elements.."); repeat(10) begin trans t = new(); // Moved here; Now for each item there will be new handle. t.randomize(); t.print(); pp.put(t); // Putting into the fifo. $display("Fifo is filled with %0d element(s)", fifo.used()); end $di
  2. Thanks Janick for quick reply. Now its working fine.. Thanks Peer Mohammed
  3. Hi All, I am trying to use tlm fifo. At first putting 10 elements after that I tried getting those elements but I always get the last data from uvm_tlm_fifo. Below is the complete code and the simulation result. Please let me know how should I use it so that I can retrieve all the elements which are being fed into it. I know, I have put_port, get_port and fifo all three inside single component and have connections here itself. It is done intentionally. ===================================================================== Code Here ========================
  4. Hi, Have you used "-full64 -debug_all" options in your compilation command? If not, try with these options. If still it doesn't work add another option "-picarchive" Regards Peer Mohammed
  5. Hi mrforever, One of my colleague had similar issue. try the same code without "typedef" chpp_sigif duv_if(); // SystemVerilog Interface ... initial begin uvm_config_db#(virtual interface chpp_vif)::set(uvm_root::get(), "*", "duv_if", duv_if); run_test(); end Regards Peer Mohammed
  6. Hi All, I am trying to keep my testbench scale able as we do in RTL files using genvars. I want to have queues of a transaction class inside my scoreboard class. e.g. monitor_trans exp_trans_port1[$]; monitor_trans exp_trans_port2[$]; monitor_trans exp_trans_port3[$]; monitor_trans exp_trans_port4[$]; .... I want to scale them in such a way that if you modify the parameters then such instantiations may increase or decrease. To achieve this I cannot use "for loop" here (It gives compilation error). I tried using `define portname(name) monitor_trans name`` [$] ==> This al
  7. Hi Peter, I am using VCS Version F-2011.12. I downloaded UVM package from Accelara site: UVM version uvm-1.1c. When I compile this package using VCS tool. I get such error. Regards Peer Mohammed
  8. Hi SeanChou, If you are using vcs tool, there are some examples in <INSTALL_PATH>/doc/examples/systemc/vcs/SV_SC_analysis and <INSTALL_PATH>/doc/examples/systemc/vcs/SC_SV_analysis These examples might be useful for you. Regards Peer Mohammed
  9. Hi All, I am using VCS Version F-2011.12. While compiling uvm-1.1c package, I am getting compilation in some of the macro files. Error comes in next line where single line comment is present (in between the definition of `define) E.g. File: $UVM_PKG_PATH/uvm-1.1c/src/macros/uvm_object_defines.svh 1. `define uvm_field_utils_end \ 2. if(what__ inside {UVM_SETINT,UVM_SETSTR,UVM_SETOBJ}) begin \ 3. // remove all scopes recorded (through super and other objects visited before) \ 4. void'(__current_scopes.pop_back()); \ 5. __m_uvm_status_container.m_uvm_cycle_sco
  10. Finally... That is not a bug. The default entry for an object is ‘null’. The comment “a new item is created with that key” refers to the pool entry, not the object in the pool. Regards, Peer Mohammed
  11. Hi, In my example I am using uvm_pool as a pool of type uvm_event (similar to ovm_event_pool as in OVM). In OVM also, If no event exists by that name, a new event is created with that name and returned. Please refer to OVM code. I am expecting the similar code in UVM. Otherwise we must change the comment for the "get" function and must have to new() our item then add to the pool before using it(Other Way to achieve the same functionality). Regards Peer Mohammed
  12. Hi All, I tried using uvm_pool in my environment. Class: uvm_pool Below is the code in uvm package uvm-1.0-p1: // Function: get // // Returns the item with the given ~key~. // // If no item exists by that key, a new item is created with that key // and returned. virtual function T get (KEY key); if (!pool.exists(key)) begin T default_value; pool[key] = default_value; end return pool[key]; endfunction In above code, default_value is added to the pool without making it new() (Bold lines above). As per the comments, I am exp
  13. Hi You may probably use the following code: my_class obj[]; obj = new[10]; for(int i=0;i<10;i++) begin $sformat(str,"obj_%0d",i); obj = my_class::type_id::create(str, this); end The above code will create the obj_0, obj_1, obj_2, obj_3 ..... obj_9. I hope this is what you required. This code was working without any error. Regards Peer Mohammed
  • Create New...