# Regarding usage of uvm\_config\_db :: set (cntxt, "inst\_name\*", field\_name, T value)

**URL:** <https://verificationacademy.com/forums/t/regarding-usage-of-uvm-config-db-set-cntxt-inst-name-field-name-t-value/33215>\
**Category:** UVM\
**Tags:** UVM, uvm\_config\_db-set\
**Created:** [June 15, 2017, 6:47am UTC](https://verificationacademy.com/forums/t/regarding-usage-of-uvm-config-db-set-cntxt-inst-name-field-name-t-value/33215 "2017-06-15T06:47:33Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![desaivs1994](https://verificationacademy.com/forums/letter_avatar_proxy/v4/letter/d/a698b9/32.png) [@desaivs1994](https://verificationacademy.com/forums/u/desaivs1994)\
**Post date:** [June 15, 2017, 6:47am UTC](https://verificationacademy.com/forums/t/regarding-usage-of-uvm-config-db-set-cntxt-inst-name-field-name-t-value/33215/1 "2017-06-15T06:47:33Z")

</div>

Hello,

I was reading about the set() method of uvm\_config\_db in CookBook. In one of the examples, an asterik was used along with instance name:

uvm\_config\_db #( ahb\_agent\_config )::set( this , “m\_ahb\_agent\*” , “ahb\_agent\_config” , ahb\_agent\_config\_h );

Following was the explanation given for this usage:  
We use “m\_ahb\_agent\*” to ensure that we config both the agent and its children. Without the ‘\*’ we would only  
configure the agent itself and not the driver, sequencer and monitor inside it.

Question :

Does this mean that m\_ahb\_agent need not set ahb\_agent\_config\_h for m\_ahb\_driver and m\_ahb\_monitor again, since they can obtain the config handle due to the use of Asterik?

---

<div class="post-metadata">

**Author:** ![chr\_sue](https://verificationacademy.com/forums/user_avatar/verificationacademy.com/chr_sue/32/1199_2.png) [@chr\_sue](https://verificationacademy.com/forums/u/chr_sue)\
**Post date:** [June 15, 2017, 1:19pm UTC](https://verificationacademy.com/forums/t/regarding-usage-of-uvm-config-db-set-cntxt-inst-name-field-name-t-value/33215/2 "2017-06-15T13:19:28Z")

</div>

_In reply to [desaivs1994](https://verificationacademy.com/forums/t/regarding-usage-of-uvm-config-db-set-cntxt-inst-name-field-name-t-value/33215):_

The first and the second argument are Building the context. ‘this’ menas always a relative path, relative to the component where you are executing the corresponding command. If you want to Limit the Access to a certain component you can do this through the second Argument. In your case only blocks with the name ‘m\_ahb\_agent’ can retrieve the data. If you do not want to Limit this, use the wildcard ‘\*’. uvm\_config\_db is also supporting globbing.

---

<div class="post-metadata">

**Author:** ![desaivs1994](https://verificationacademy.com/forums/letter_avatar_proxy/v4/letter/d/a698b9/32.png) [@desaivs1994](https://verificationacademy.com/forums/u/desaivs1994)\
**Post date:** [June 15, 2017, 2:31pm UTC](https://verificationacademy.com/forums/t/regarding-usage-of-uvm-config-db-set-cntxt-inst-name-field-name-t-value/33215/3 "2017-06-15T14:31:22Z")

</div>

_In reply to [chr\_sue](https://verificationacademy.com/forums/t/regarding-usage-of-uvm-config-db-set-cntxt-inst-name-field-name-t-value/33215/2):_

> _In reply to [desaivs1994](https://verificationacademy.com/forums/t/regarding-usage-of-uvm-config-db-set-cntxt-inst-name-field-name-t-value/33215/2):_  
> The first and the second argument are Building the context. ‘this’ menas always a relative path, relative to the component where you are executing the corresponding command. If you want to Limit the Access to a certain component you can do this through the second Argument. In your case only blocks with the name ‘m\_ahb\_agent’ can retrieve the data. If you do not want to Limit this, use the wildcard ‘\*’. uvm\_config\_db is also supporting globbing.

Thank you for the reply chr\_sue,

So in my case, I guess “m\_ahb\_agent\*” is an example of globbing.

---

<div class="post-metadata">

**Author:** ![chr\_sue](https://verificationacademy.com/forums/user_avatar/verificationacademy.com/chr_sue/32/1199_2.png) [@chr\_sue](https://verificationacademy.com/forums/u/chr_sue)\
**Post date:** [June 15, 2017, 3:21pm UTC](https://verificationacademy.com/forums/t/regarding-usage-of-uvm-config-db-set-cntxt-inst-name-field-name-t-value/33215/4 "2017-06-15T15:21:22Z")

</div>

_In reply to [desaivs1994](https://verificationacademy.com/forums/t/regarding-usage-of-uvm-config-db-set-cntxt-inst-name-field-name-t-value/33215/3):_

No this is not globbing. This is another way as using Wildcards, but more specific, differentiating between characters, numbers etc.
