
The **Design Hierarchy View** presents recursively the instances in a Verilog module or the instances in a VHDL entity or component implementation. Cross-language design hierarchies are also supported.

Position the editor cursor on the name of a design element and press :kbd:`Shift+F4` or right-click and choose :menuselection:`Show --> Design Hierarchy` from the context menu.

The Design Hierarchy View opens with the chosen element set as the top of the hierarchy. You can also go to menu :menuselection:`Window --> Show View --> Design Hierarchy` to open the view.

.. figure:: ../../images/common/design-hierarchy-presentation.png
	:align: center

.. |cancel-current-operation| image:: ../../images/icons/act16/terminate_enable.png
   :class: inline

.. |design-hierarchy-top| image:: ../../images/icons/act16/design_hierarchy_top.png
   :class: inline

.. |history-list| image:: ../../images/icons/act16/history_list.png
   :class: inline

.. |show-hide-ports| image:: ../../images/icons/act16/show_hide_ports.png
   :class: inline

.. |show-pd| image:: ../../images/icons/obj16/power_domain.png
   :class: inline

.. |prepend-library| image:: ../../images/icons/act16/prepend_library.png
   :class: inline

- |cancel-current-operation| **Cancel Current Operation** Stops the view operation in progress, for example a search.
- |design-hierarchy-top| **Select Top** A drop-down menu/pop-up dialog to select from *top* modules for Verilog or *top* architectures for VHDL. For Verilog, a *top* element is a module that instantiates other design elements and it is not itself instantiated. Similar for VHDL *top* architectures.
- |history-list| **History List** Click to see the previously inspected elements.
- |show-hide-ports| **Show/Hide Ports** Shows or hides the ports of the selected element. You can set the ports panel to the right or below the hierarchy.
- |show-pd| **Show PD** Shows or hides power domain information. You can choose to see the power domain names in the node labels, and distinctive foreground or background colors for all nodes belonging to the same power domain.
- |prepend-library| **Prepend Library** Prepend to the node label the name of the library to which the instance belongs.


.. |go-to-top| image:: ../../images/common/lzv_slider_top.png
   :class: inline

.. |up-one-page| image:: ../../images/common/lzv_slider_pgup.png
   :class: inline

.. |up| image:: ../../images/common/lzv_slider_up.png
   :class: inline

.. |down| image:: ../../images/common/lzv_slider_down.png
   :class: inline

.. |down-one-page| image:: ../../images/common/lzv_slider_pgdn.png
   :class: inline

.. |go-to-bottom| image:: ../../images/common/lzv_slider_bottom.png
   :class: inline

You can scroll through the tree of instances using:

-  the mouse scroll wheel
-  the :kbd:`Up arrow`, :kbd:`Down arrow`, :kbd:`PgUp`, :kbd:`PgDn` keys
-  the vertical button bar on the right side of the tree
    -   |go-to-top| go to top of tree
    -   |up-one-page| up one page
    -   |up| up one element
    -   |down| down one element
    -   |down-one-page| down one page
    -   |go-to-bottom| go to bottom of tree

.. note::

	The :guilabel:`up/down` buttons are grayed out when reaching the top/bottom of the tree. 



You can **double-click** on an instance to go to its declaration. **Double-click** on a port to go to where it is connected.

**Right-click** on an instance in the hierarchy and you have the following options :

.. figure:: ../../images/common/design-hierarchy-menu.png
	:align: center




-  **Show Usages (References)** Search for the references of the selected instance. More details :ref:`Show Usages, Readers or Writers`
-  **Show Design Hierarchy** Show the design hierarchy starting from the selection.
-  **Show Diagram** Show the design diagram for the current selection. More details :ref:`Design Diagrams`
-  **Copy**  Copy the label text of the selected instance to clipboard.
-  **Copy Hierarchy Path** Copy the hierarchy path of the selected instance to clipboard. You can change the segment separator from :menuselection:`Window --> Preferences --> DVT`. 

*Right-click* on a port and you have the following options :

.. figure:: ../../images/common/design-hierarchy-ports-menu.png
	:align: center




-  **Trace Drive / Load / Drive and Load / In Subinstance** See :ref:`Trace Connections View`.
-  **Show Usages (References)** Search for the references of the selected port. More details :ref:`Show Usages, Readers or Writers`
-  **Readers / Writers** See :ref:`Show Usages, Readers or Writers`
-  **Show Diagram** Show the Finite-State Machine for the current selection. More details :ref:`Finite-State Machine Diagrams`
-  **Show Connections Diagram** Show the Schematic Diagram of the selected port and all the instances connected to it
-  **Copy**  Copy the label text of the selected port to clipboard.
-  **Copy Hierarchy Path**  Copy the hierarchy path of the selected port to clipboard. You can change the segment separator from :menuselection:`Window --> Preferences --> DVT`.



You can use the filters to locate a specific instance or port. You may use slash '/' characters to filter hierarchically one level and '//' to filter hierarchically all the levels. You may use the dot '.' character to filter instances that contain a specific port. The ports that match the filter are promoted to the top of the ports panel. See :ref:`Quick Search in Views` for more details.

.. list-table::
   :widths: auto

   * - No filter.
     - .. figure:: ../../images/common/design-hierarchy-filtering-no-filter.png
   * - Filter by instance name. All instances that contain the filter text are shown.
     - .. figure:: ../../images/common/design-hierarchy-filtering_filter_instance_name.png
   * - Filter strict hierarchy. All instances that contain the filter text and are in a direct hierarchical relationship (father/son) are shown.
     - .. figure:: ../../images/common/design-hierarchy-filtering_filter_strict_hierarchy.png
   * - Filter non-strict hierarchy. All instances that contain the filter text and are in a direct or indirect hierarchical relationship (ancestor/../../descendant) are shown.
     - .. figure:: ../../images/common/design-hierarchy-filtering-filter-non-strict-hierarchy.png
   * - Filter strict hierarchy and show all descendants. Same results as for filter strict hierarchy, but including all descendants of the matched instances.
     - .. figure:: ../../images/common/design-hierarchy-filtering-filter-strict-hierarchy-descendants.png
   * - Filter strict hierarchy and show direct descendants. Same results as for filter strict hierarchy, but including the sons of the matched instances.
     - .. figure:: ../../images/common/design-hierarchy-filtering-filter-strict-hierarchy-sons.png
   * - Filter by port name. All instances with ports that contain the filter text are shown.
     - .. figure:: ../../images/common/design-hierarchy-filtering-filter-port.png
   * - Filter by hierarchy and port name. Hierarchical filtering and port filtering may be combined.
     - .. figure:: ../../images/common/design-hierarchy-filtering-filter-hierarchy-and-port.png


.. note::

	To switch to the Old Design Hierarchy View  (pre DVT 20.1.1) go to  **Window > Preferences > DVT** and enable **Switch to Old Design Hierarchy View**
