VMM - (expanded) HAL/vmm_hw.sv

Expanded versions of source files are the output of the preprocessor. Lines subject to conditional compilation are not shown and all compiler pragmas have been stripped. Macros have been completely expanded.

HAL/vmm_hw.sv unexpanded source

00001: // 
00002: // -------------------------------------------------------------
00003: //    Copyright 2004-2008 Synopsys, Inc.
00004: //    All Rights Reserved Worldwide
00005: // 
00006: //    Licensed under the Apache License, Version 2.0 (the
00007: //    "License"); you may not use this file except in
00008: //    compliance with the License.  You may obtain a copy of
00009: //    the License at
00010: // 
00011: //        http://www.apache.org/licenses/LICENSE-2.0
00012: // 
00013: //    Unless required by applicable law or agreed to in
00014: //    writing, software distributed under the License is
00015: //    distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
00016: //    CONDITIONS OF ANY KIND, either express or implied.  See
00017: //    the License for the specific language governing
00018: //    permissions and limitations under the License.
00019: // -------------------------------------------------------------
00020: // 
00021: 
00022: 
00024: `define VMM_HW__SV
00025: 
00027: `define VMM_HW_MAX_MSG_WIDTH 1024
     : 
00029: 
00034: 
00038:    class vmm_hw_version;
00039:       extern function int major();
00040:       extern function int minor();
00041:       extern function int patch();
00042:       extern function string vendor();
00043:       extern function void display(string prefix = "");
00044:       extern function string psdisplay(string prefix = "");
00045:    endclass: vmm_hw_version
00046: 
00051: 
00052: 
00053: function int vmm_hw_version::major();
00054:    major = 1;
00055: endfunction: major
00056: 
00057: function int vmm_hw_version::minor();
00058:    minor = 1;
00059: endfunction: minor
00060: 
00061: function int vmm_hw_version::patch();
00062:    patch = 1;
00063: endfunction: patch
00064: 
00065: function string vmm_hw_version::vendor();
00066:    vendor = "Synopsys";
00067: endfunction: vendor
00068: 
00069: function void vmm_hw_version::display(string prefix);
00070:    $write("%s\n", this.psdisplay(prefix));
00071: endfunction: display
00072: 
00073: function string vmm_hw_version::psdisplay(string prefix);
00074:    $sformat(psdisplay, "%sVMM HAL Version %0d.%0d.%0d (%s)",
00075:             prefix, this.major(), this.minor(), this.patch(), this.vendor());
00076: endfunction: psdisplay
00077:   
00079: