UnityChipForXiangShan/scripts/build_ut_backend_ctrl_block...

37 lines
1.2 KiB
Python

# coding=utf8
# ***************************************************************************************
# This project is licensed under Mulan PSL v2.
# You can use this software according to the terms and conditions of the Mulan PSL v2.
# You may obtain a copy of Mulan PSL v2 at:
# http://license.coscl.org.cn/MulanPSL2
#
# THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
# EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
# MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
#
# See the Mulan PSL v2 for more details.
# **************************************************************************************/
import os
from comm import info
from comm.export_dut import picker_export
TARGET_NAME = "DecodeStage"
def build(cfg):
# import base modules
from comm import exe_cmd, get_root_dir
# Build disasm
if not os.path.exists(get_root_dir("tools/disasm/build")):
info("Building disasm")
s, _, _ = exe_cmd("make -C %s" % get_root_dir("tools/disasm"))
assert s, "Failed to build disasm"
return picker_export(TARGET_NAME, cfg)
def line_coverage_files(cfg):
return ["PreDecode.v", "DecodeStage.v"]