New instantiates a new Model instance, but it is not saved until the save method is called. Create does the same as new, but also saves it to the database. Sometimes you want to do stuff before saving something to the database, sometimes you just want to create and save it straight away.
uvm_components are "static-like" in that they are created during build_phase() and persist throughout the simulation. Think of them as the class-based equivalent of modules. uvm_objects are transient, such as transactions that are created when needed and disappear when not used anymore.
The create function goes through the UVM factory and checks for registered type or instance overrides. This allows for objects or components to be replaced by derived types using the factory. I would suggest reading up on Factory Pattern, which is a key concept in UVM.
A super. new call shall be the first statement executed in the constructor. This is because the superclass shall be initialized before the current class and, if the user code does not provide an initialization, the compiler shall insert a call to super. new automatically.
I did:
resources :posts
What's the difference between the 'create' and the 'new' urls?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With