scons: Use Kconfig to configure gem5.
These are not yet consumed by anything, but convert all the settings from SCons variables to Kconfig variables. If you have existing SConsopts files which need to be converted, you should take a look at KCONFIG.md to learn about how kconfig is used in gem5. You should decide if any variables need to be available to C++ or kconfig itself, and whether those are options which should be detected automatically, or should be up to the user. Options which should be measured automatically should still be in SConsopts files, while user facing options should be added to new or existing Kconfig files. Generally, make sure you're storing c++/kconfig visible options in env['CONF'][...]. Also remove references to sticky_vars since persistent options should now be handled with kconfig, and export_vars since everything in env['CONF'] is now exported automatically. Switch SCons/gem5 to use Kconfig for configuration, except EXTRAS which is still a sticky SCons variable. This is necessary because EXTRAS also controls what config options exist. If it came from Kconfig itself, then there would be a circular dependency. This dependency could theoretically be handled by reparsing the Kconfig when EXTRAS directories were added or removed, but that would be complicated, and isn't supported by kconfiglib. It wouldn't be worth the significant effort it would take to add it, just to use Kconfig more purely. Change-Id: I29ab1940b2d7b0e6635a490452d05befe5b4a2c9
This commit is contained in:
53
src/Kconfig
Normal file
53
src/Kconfig
Normal file
@@ -0,0 +1,53 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
mainmenu "$(MAIN_MENU_TEXT)"
|
||||
|
||||
config BATCH
|
||||
bool "Use batch pool for build and test"
|
||||
default n
|
||||
|
||||
config BATCH_CMD
|
||||
string "Batch pool submission command name"
|
||||
default "qdo"
|
||||
depends on BATCH
|
||||
|
||||
config M5_BUILD_CACHE
|
||||
string "Cache built objects in this directory"
|
||||
default ""
|
||||
|
||||
config USE_EFENCE
|
||||
bool "Link with Electric Fence malloc debugger"
|
||||
default n
|
||||
|
||||
rsource "base/Kconfig"
|
||||
rsource "mem/ruby/Kconfig"
|
||||
rsource "learning_gem5/part3/Kconfig"
|
||||
rsource "proto/Kconfig"
|
||||
rsource "dev/net/Kconfig"
|
||||
rsource "arch/Kconfig"
|
||||
rsource "cpu/kvm/Kconfig"
|
||||
rsource "systemc/Kconfig"
|
||||
rsource "gpu-compute/Kconfig"
|
||||
37
src/arch/Kconfig
Normal file
37
src/arch/Kconfig
Normal file
@@ -0,0 +1,37 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config TARGET_GPU_ISA
|
||||
string
|
||||
|
||||
rsource "amdgpu/Kconfig"
|
||||
|
||||
rsource "arm/Kconfig"
|
||||
rsource "mips/Kconfig"
|
||||
rsource "null/Kconfig"
|
||||
rsource "power/Kconfig"
|
||||
rsource "riscv/Kconfig"
|
||||
rsource "sparc/Kconfig"
|
||||
rsource "x86/Kconfig"
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2021 Google, Inc.
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
@@ -23,6 +23,11 @@
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
Import('*')
|
||||
sticky_vars.Add(BoolVariable('USE_POWER_ISA', 'Enable POWER ISA support',
|
||||
False))
|
||||
if BUILD_GPU
|
||||
choice "TARGET_GPU_ISA"
|
||||
prompt "GPU ISA"
|
||||
endchoice
|
||||
endif
|
||||
|
||||
rsource "gcn3/Kconfig"
|
||||
rsource "vega/Kconfig"
|
||||
33
src/arch/amdgpu/gcn3/Kconfig
Normal file
33
src/arch/amdgpu/gcn3/Kconfig
Normal file
@@ -0,0 +1,33 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config TARGET_GPU_ISA
|
||||
default "gcn3" if GCN3_GPU_ISA
|
||||
|
||||
cont_choice "TARGET_GPU_ISA"
|
||||
config GCN3_GPU_ISA
|
||||
depends on BUILD_GPU
|
||||
bool "GCN3"
|
||||
endchoice
|
||||
33
src/arch/amdgpu/vega/Kconfig
Normal file
33
src/arch/amdgpu/vega/Kconfig
Normal file
@@ -0,0 +1,33 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config TARGET_GPU_ISA
|
||||
default 'vega' if VEGA_GPU_ISA
|
||||
|
||||
cont_choice "TARGET_GPU_ISA"
|
||||
config VEGA_GPU_ISA
|
||||
depends on BUILD_GPU
|
||||
bool "VEGA"
|
||||
endchoice
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2021 Google, Inc.
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
@@ -23,5 +23,7 @@
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
Import('*')
|
||||
sticky_vars.Add(BoolVariable('USE_X86_ISA', 'Enable X86 ISA support', False))
|
||||
config USE_ARM_ISA
|
||||
bool "ARM ISA support"
|
||||
|
||||
rsource "fastmodel/Kconfig"
|
||||
@@ -40,7 +40,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['USE_ARM_ISA']:
|
||||
if env['CONF']['USE_ARM_ISA']:
|
||||
env.TagImplies('arm isa', 'gem5 lib')
|
||||
|
||||
# The GTest function does not have a 'tags' parameter. We therefore apply this
|
||||
@@ -48,7 +48,7 @@ if env['USE_ARM_ISA']:
|
||||
#
|
||||
# Note: This will need reconfigured for multi-isa. E.g., if this is
|
||||
# incorporated: https://gem5-review.googlesource.com/c/public/gem5/+/52491
|
||||
if env['USE_ARM_ISA']:
|
||||
if env['CONF']['USE_ARM_ISA']:
|
||||
GTest('aapcs64.test', 'aapcs64.test.cc',
|
||||
'../../base/debug.cc',
|
||||
'../../cpu/reg_class.cc',
|
||||
|
||||
60
src/arch/arm/fastmodel/Kconfig
Normal file
60
src/arch/arm/fastmodel/Kconfig
Normal file
@@ -0,0 +1,60 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
menu "Fast Model"
|
||||
|
||||
config USE_ARM_FASTMODEL
|
||||
bool "Fast Model integration"
|
||||
default n
|
||||
depends on USE_ARM_ISA
|
||||
depends on USE_SYSTEMC
|
||||
|
||||
if USE_ARM_FASTMODEL
|
||||
config PVLIB_HOME
|
||||
string "Fast Model portfolio directory"
|
||||
default "$(PVLIB_HOME)"
|
||||
|
||||
config PVLIB_FLAVOR
|
||||
string "What build flavor of the Fast Model pvlib to use"
|
||||
default "Linux64_GCC-7.3"
|
||||
|
||||
config MAXCORE_HOME
|
||||
string "Fast Model tools directory"
|
||||
default "$(MAXCORE_HOME)"
|
||||
|
||||
config ARMLMD_LICENSE_FILE
|
||||
string "ARM license file location"
|
||||
default "$(ARMLMD_LICENSE_FILE)"
|
||||
|
||||
config ARMLMD_LICENSE_COUNT
|
||||
int "The maximum number of ARM licenses to use concurrently"
|
||||
default 1
|
||||
|
||||
config SIMGEN
|
||||
string "simgen executable (leave unset for MAXCORE_HOME/bin/simgen"
|
||||
default ""
|
||||
endif
|
||||
|
||||
endmenu
|
||||
@@ -302,6 +302,10 @@ for header in common_headers:
|
||||
header_src = examples_common_dir.Dir('include').File(header)
|
||||
Command(header_target, header_src, Copy('${TARGET}', '${SOURCE}'))
|
||||
|
||||
if not env['CONF']['SIMGEN']:
|
||||
env['CONF']['SIMGEN'] = os.path.join(
|
||||
env['CONF']['MAXCORE_HOME'], 'bin', 'simgen')
|
||||
|
||||
class ArmFastModelComponent(object):
|
||||
def __init__(self, project_file, *extra_deps, tags=None):
|
||||
if not tags:
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
# Copyright 2019 Google, Inc.
|
||||
# All rights reserved.
|
||||
# Copyright 2019,2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
@@ -28,20 +27,12 @@ Import('*')
|
||||
|
||||
import os
|
||||
|
||||
default_simgen = os.path.join('${MAXCORE_HOME}', 'bin', 'simgen')
|
||||
def extract_var(name):
|
||||
val = os.environ.get(name, None)
|
||||
if val is not None:
|
||||
main['CONF'][name] = val
|
||||
|
||||
sticky_vars.AddVariables(
|
||||
BoolVariable('USE_ARM_FASTMODEL',
|
||||
'Build support for integrating ARM Fast Models', False),
|
||||
('PVLIB_HOME', 'Fast Model portfolio directory',
|
||||
os.environ.get('PVLIB_HOME', '')),
|
||||
('PVLIB_FLAVOR', 'What build flavor of the Fast Model pvlib to use',
|
||||
'Linux64_GCC-7.3'),
|
||||
('MAXCORE_HOME', 'Fast Model tools directory',
|
||||
os.environ.get('MAXCORE_HOME', '')),
|
||||
('ARMLMD_LICENSE_FILE', 'ARM license file location',
|
||||
os.environ.get('ARMLMD_LICENSE_FILE', '')),
|
||||
('ARMLMD_LICENSE_COUNT',
|
||||
'The maximum number of ARM licenses to use concurrently', 1),
|
||||
('SIMGEN', 'simgen executable', os.environ.get('SIMGEN', default_simgen)),
|
||||
)
|
||||
# Make these environment variables in the host environment available when
|
||||
# running kconfig tools by putting them in env['CONF'].
|
||||
for var in 'PVLIB_HOME', 'MAXCORE_HOME', 'ARMLMD_LICENSE_FILE':
|
||||
extract_var(var)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2021 Google, Inc.
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
@@ -23,5 +23,5 @@
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
Import('*')
|
||||
sticky_vars.Add(BoolVariable('USE_ARM_ISA', 'Enable ARM ISA support', False))
|
||||
config USE_MIPS_ISA
|
||||
bool "MIPS ISA support"
|
||||
@@ -29,7 +29,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['USE_MIPS_ISA']:
|
||||
if env['CONF']['USE_MIPS_ISA']:
|
||||
env.TagImplies('mips isa', 'gem5 lib')
|
||||
|
||||
Source('decoder.cc', tags='mips isa')
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2021 Google, Inc.
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
@@ -23,5 +23,5 @@
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
Import('*')
|
||||
sticky_vars.Add(BoolVariable('USE_MIPS_ISA', 'Enable MIPS ISA support', False))
|
||||
config USE_NULL_ISA
|
||||
bool "Null ISA support"
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2021 Google, Inc.
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
@@ -23,5 +23,5 @@
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
Import('*')
|
||||
sticky_vars.Add(BoolVariable('USE_NULL_ISA', 'Enable NULL ISA support', False))
|
||||
config USE_POWER_ISA
|
||||
bool "POWER ISA support"
|
||||
@@ -30,7 +30,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['USE_POWER_ISA']:
|
||||
if env['CONF']['USE_POWER_ISA']:
|
||||
env.TagImplies('power isa', 'gem5 lib')
|
||||
|
||||
Source('decoder.cc', tags='power isa')
|
||||
|
||||
27
src/arch/riscv/Kconfig
Normal file
27
src/arch/riscv/Kconfig
Normal file
@@ -0,0 +1,27 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config USE_RISCV_ISA
|
||||
bool "RISC-V ISA support"
|
||||
@@ -43,7 +43,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['USE_RISCV_ISA']:
|
||||
if env['CONF']['USE_RISCV_ISA']:
|
||||
env.TagImplies('riscv isa', 'gem5 lib')
|
||||
|
||||
Source('decoder.cc', tags='riscv isa')
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
# Copyright 2021 Google, Inc.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
Import('*')
|
||||
sticky_vars.Add(BoolVariable('USE_RISCV_ISA', 'Enable RISC-V ISA support',
|
||||
False))
|
||||
27
src/arch/sparc/Kconfig
Normal file
27
src/arch/sparc/Kconfig
Normal file
@@ -0,0 +1,27 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config USE_SPARC_ISA
|
||||
bool "SPARC ISA support"
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['USE_SPARC_ISA']:
|
||||
if env['CONF']['USE_SPARC_ISA']:
|
||||
env.TagImplies('sparc isa', 'gem5 lib')
|
||||
|
||||
Source('asi.cc', tags='sparc isa')
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
# Copyright 2021 Google, Inc.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
Import('*')
|
||||
sticky_vars.Add(BoolVariable('USE_SPARC_ISA', 'Enable SPARC ISA support',
|
||||
False))
|
||||
27
src/arch/x86/Kconfig
Normal file
27
src/arch/x86/Kconfig
Normal file
@@ -0,0 +1,27 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config USE_X86_ISA
|
||||
bool "X86 ISA support"
|
||||
@@ -40,7 +40,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['USE_X86_ISA']:
|
||||
if env['CONF']['USE_X86_ISA']:
|
||||
env.TagImplies('x86 isa', 'gem5 lib')
|
||||
|
||||
Source('cpuid.cc', tags='x86 isa')
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2020 Google, Inc.
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
@@ -23,11 +23,23 @@
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
Import('*')
|
||||
config HAVE_FENV
|
||||
def_bool $(HAVE_FENV)
|
||||
|
||||
def add_isa_lists():
|
||||
sticky_vars.AddVariables(
|
||||
EnumVariable('TARGET_GPU_ISA', 'Target GPU ISA', 'gcn3',
|
||||
sorted(set(main.Split('${ALL_GPU_ISAS}')))),
|
||||
)
|
||||
AfterSConsopts(add_isa_lists)
|
||||
config HAVE_PNG
|
||||
def_bool $(HAVE_PNG)
|
||||
|
||||
config HAVE_VALGRIND
|
||||
def_bool $(HAVE_VALGRIND)
|
||||
|
||||
config HAVE_DEPRECATED_NAMESPACE
|
||||
def_bool $(HAVE_DEPRECATED_NAMESPACE)
|
||||
|
||||
config HAVE_POSIX_CLOCK
|
||||
def_bool $(HAVE_POSIX_CLOCK)
|
||||
|
||||
config USE_POSIX_CLOCK
|
||||
depends on HAVE_POSIX_CLOCK
|
||||
bool "Use POSIX clocks"
|
||||
|
||||
rsource "stats/Kconfig"
|
||||
@@ -81,6 +81,3 @@ with gem5_scons.Configure(werror_env) as conf:
|
||||
warning("Deprecated namespaces are not supported by this compiler.\n"
|
||||
"Please make sure to check the mailing list for deprecation "
|
||||
"announcements.")
|
||||
|
||||
sticky_vars.Add(BoolVariable('USE_POSIX_CLOCK', 'Use POSIX Clocks',
|
||||
'${CONF["HAVE_POSIX_CLOCK"]}'))
|
||||
|
||||
27
src/base/stats/Kconfig
Normal file
27
src/base/stats/Kconfig
Normal file
@@ -0,0 +1,27 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config HAVE_HDF5
|
||||
def_bool $(HAVE_HDF5)
|
||||
34
src/cpu/kvm/Kconfig
Normal file
34
src/cpu/kvm/Kconfig
Normal file
@@ -0,0 +1,34 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config KVM_ISA
|
||||
string
|
||||
default "$(KVM_ISA)"
|
||||
|
||||
config USE_KVM
|
||||
depends on KVM_ISA != ""
|
||||
bool "Enable hardware virtualized (KVM) CPU models"
|
||||
default y if KVM_ISA != ""
|
||||
default n
|
||||
@@ -61,13 +61,5 @@ with gem5_scons.Configure(main) as conf:
|
||||
warning("perf_event headers lack support for the exclude_host "
|
||||
"attribute. KVM instruction counts will be inaccurate.")
|
||||
|
||||
|
||||
def create_use_kvm_var():
|
||||
if main['CONF']['HAVE_KVM'] and main['CONF']['KVM_ISA']:
|
||||
sticky_vars.Add(BoolVariable('USE_KVM',
|
||||
'Enable hardware virtualized (KVM) CPU models', True))
|
||||
else:
|
||||
main['CONF']['USE_KVM'] = False
|
||||
warning("Cannot enable KVM, host seems to lack KVM support")
|
||||
|
||||
AfterSConsopts(create_use_kvm_var)
|
||||
if not main['CONF']['KVM_ISA']:
|
||||
warning("Can not enable KVM, host seems to lack KVM support")
|
||||
|
||||
@@ -35,7 +35,7 @@ Import('*')
|
||||
# When this dependency is removed, the ruby tester should be compiled
|
||||
# independently from Ruby
|
||||
#
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
SimObject('RubyDirectedTester.py', sim_objects=[
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
SimObject('GarnetSyntheticTraffic.py', sim_objects=['GarnetSyntheticTraffic'])
|
||||
|
||||
@@ -34,7 +34,7 @@ Import('*')
|
||||
if not env['CONF']['BUILD_GPU']:
|
||||
Return()
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
SimObject('ProtocolTester.py', sim_objects=['ProtocolTester'])
|
||||
|
||||
@@ -35,7 +35,7 @@ Import('*')
|
||||
# When this dependency is removed, the ruby tester should be compiled
|
||||
# independently from Ruby
|
||||
#
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
SimObject('RubyTester.py', sim_objects=['RubyTester'])
|
||||
|
||||
27
src/dev/net/Kconfig
Normal file
27
src/dev/net/Kconfig
Normal file
@@ -0,0 +1,27 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config HAVE_TUNTAP
|
||||
def_bool $(HAVE_TUNTAP)
|
||||
28
src/gpu-compute/Kconfig
Normal file
28
src/gpu-compute/Kconfig
Normal file
@@ -0,0 +1,28 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
menuconfig BUILD_GPU
|
||||
bool "Build the compute-GPU model"
|
||||
default n
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2020 Google, Inc.
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
@@ -23,7 +23,10 @@
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
Import('*')
|
||||
config PROTOCOL
|
||||
default "MSI" if RUBY_PROTOCOL_MSI
|
||||
|
||||
sticky_vars.Add(BoolVariable('BUILD_GPU', 'Build the compute-GPU model',
|
||||
False))
|
||||
cont_choice "Ruby protocol"
|
||||
config RUBY_PROTOCOL_MSI
|
||||
bool "MSI"
|
||||
endchoice
|
||||
@@ -2,8 +2,5 @@ Import('*')
|
||||
|
||||
# NOTE: All SLICC setup code found in src/mem/ruby/protocol/SConscript
|
||||
|
||||
# Register this protocol with gem5/SCons
|
||||
main.Append(ALL_PROTOCOLS=['MSI'])
|
||||
|
||||
# Add this directory to the search path for SLICC
|
||||
main.Append(PROTOCOL_DIRS=[Dir('.')])
|
||||
|
||||
50
src/mem/ruby/Kconfig
Normal file
50
src/mem/ruby/Kconfig
Normal file
@@ -0,0 +1,50 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
menu "Ruby"
|
||||
menuconfig RUBY
|
||||
bool "Enable"
|
||||
|
||||
if RUBY
|
||||
config PROTOCOL
|
||||
string
|
||||
|
||||
config NEED_PARTIAL_FUNC_READS
|
||||
bool
|
||||
|
||||
choice "Ruby protocol"
|
||||
prompt "Ruby protocol"
|
||||
endchoice
|
||||
|
||||
config SLICC_HTML
|
||||
bool 'Create HTML files'
|
||||
|
||||
config NUMBER_BITS_PER_SET
|
||||
int 'Max elements in set'
|
||||
default 64
|
||||
endif
|
||||
endmenu
|
||||
|
||||
rsource "protocol/Kconfig"
|
||||
@@ -49,7 +49,7 @@ from gem5_scons import Transform
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
DebugFlag('ProtocolTrace')
|
||||
@@ -112,7 +112,7 @@ MakeInclude('structures/PerfectCacheMemory.hh')
|
||||
MakeInclude('structures/PersistentTable.hh')
|
||||
MakeInclude('structures/RubyPrefetcher.hh')
|
||||
MakeInclude('structures/TBEStorage.hh')
|
||||
if env['PROTOCOL'] == 'CHI':
|
||||
if env['CONF']['PROTOCOL'] == 'CHI':
|
||||
MakeInclude('structures/MN_TBEStorage.hh')
|
||||
MakeInclude('structures/MN_TBETable.hh')
|
||||
MakeInclude('structures/TBETable.hh')
|
||||
|
||||
@@ -25,12 +25,4 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
main.SetDefault(ALL_PROTOCOLS=[], PROTOCOL_DIRS=[], SLICC_INCLUDES=[])
|
||||
|
||||
def add_protocols_var():
|
||||
sticky_vars.Add(EnumVariable('PROTOCOL', 'Coherence protocol for Ruby',
|
||||
'None', main['ALL_PROTOCOLS']))
|
||||
AfterSConsopts(add_protocols_var)
|
||||
|
||||
sticky_vars.Add(('NUMBER_BITS_PER_SET', 'Max elements in set (default 64)',
|
||||
64))
|
||||
main.SetDefault(PROTOCOL_DIRS=[], SLICC_INCLUDES=[])
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
env.Append(CPPDEFINES={'NUMBER_BITS_PER_SET':
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
SimObject('BasicLink.py', sim_objects=[
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
SimObject('FaultModel.py', sim_objects=['FaultModel'])
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
SimObject('GarnetLink.py', enums=['CDCType'], sim_objects=[
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
SimObject('SimpleLink.py', sim_objects=['SimpleExtLink', 'SimpleIntLink'])
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
Source('AccessTraceForAddress.cc')
|
||||
|
||||
62
src/mem/ruby/protocol/Kconfig
Normal file
62
src/mem/ruby/protocol/Kconfig
Normal file
@@ -0,0 +1,62 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config PROTOCOL
|
||||
default "GPU_VIPER" if RUBY_PROTOCOL_GPU_VIPER
|
||||
default "MOESI_AMD_Base" if RUBY_PROTOCOL_MOESI_AMD_BASE
|
||||
default "MESI_Two_Level" if RUBY_PROTOCOL_MESI_TWO_LEVEL
|
||||
default "MESI_Three_Level" if RUBY_PROTOCOL_MESI_THREE_LEVEL
|
||||
default "MESI_Three_Level_HTM" if RUBY_PROTOCOL_MESI_THREE_LEVEL_HTM
|
||||
default "MI_example" if RUBY_PROTOCOL_MI_EXAMPLE
|
||||
default "MOESI_CMP_directory" if RUBY_PROTOCOL_MOESI_CMP_DIRECTORY
|
||||
default "MOESI_CMP_token" if RUBY_PROTOCOL_MOESI_CMP_TOKEN
|
||||
default "MOESI_hammer" if RUBY_PROTOCOL_MOESI_HAMMER
|
||||
default "Garnet_standalone" if RUBY_PROTOCOL_GARNET_STANDALONE
|
||||
|
||||
cont_choice "Ruby protocol"
|
||||
config RUBY_PROTOCOL_GPU_VIPER
|
||||
bool "GPU VIPER"
|
||||
depends on BUILD_GPU
|
||||
config RUBY_PROTOCOL_MOESI_AMD_BASE
|
||||
bool "MOESI AMD base"
|
||||
config RUBY_PROTOCOL_MESI_TWO_LEVEL
|
||||
bool "MESI two level"
|
||||
config RUBY_PROTOCOL_MESI_THREE_LEVEL
|
||||
bool "MESI three level"
|
||||
config RUBY_PROTOCOL_MESI_THREE_LEVEL_HTM
|
||||
bool "MESI three level HTM"
|
||||
config RUBY_PROTOCOL_MI_EXAMPLE
|
||||
bool "MI example"
|
||||
config RUBY_PROTOCOL_MOESI_CMP_DIRECTORY
|
||||
bool "MOESI CMP directory"
|
||||
config RUBY_PROTOCOL_MOESI_CMP_TOKEN
|
||||
bool "MOESI CMP token"
|
||||
config RUBY_PROTOCOL_MOESI_HAMMER
|
||||
bool "MOESI hammer"
|
||||
config RUBY_PROTOCOL_GARNET_STANDALONE
|
||||
bool "Garnet standalone"
|
||||
endchoice
|
||||
|
||||
rsource "chi/Kconfig"
|
||||
@@ -36,7 +36,7 @@ from gem5_scons import Transform
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
output_dir = Dir('.')
|
||||
|
||||
@@ -30,23 +30,6 @@ import os
|
||||
|
||||
Import('*')
|
||||
|
||||
main.Append(ALL_PROTOCOLS=[
|
||||
'GPU_VIPER',
|
||||
'MOESI_AMD_Base',
|
||||
'MESI_Two_Level',
|
||||
'MESI_Three_Level',
|
||||
'MESI_Three_Level_HTM',
|
||||
'MI_example',
|
||||
'MOESI_CMP_directory',
|
||||
'MOESI_CMP_token',
|
||||
'MOESI_hammer',
|
||||
'Garnet_standalone',
|
||||
'None'
|
||||
])
|
||||
|
||||
opt = BoolVariable('SLICC_HTML', 'Create HTML files', False)
|
||||
sticky_vars.Add(opt)
|
||||
|
||||
main.Append(PROTOCOL_DIRS=[Dir('.')])
|
||||
|
||||
protocol_base = Dir('.')
|
||||
|
||||
35
src/mem/ruby/protocol/chi/Kconfig
Normal file
35
src/mem/ruby/protocol/chi/Kconfig
Normal file
@@ -0,0 +1,35 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config PROTOCOL
|
||||
default "CHI" if RUBY_PROTOCOL_CHI
|
||||
|
||||
config NEED_PARTIAL_FUNC_READS
|
||||
default y if RUBY_PROTOCOL_CHI
|
||||
|
||||
cont_choice "Ruby protocol"
|
||||
config RUBY_PROTOCOL_CHI
|
||||
bool "CHI"
|
||||
endchoice
|
||||
@@ -37,11 +37,4 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
# Register this protocol with gem5/SCons
|
||||
|
||||
main.Append(ALL_PROTOCOLS=['CHI'])
|
||||
|
||||
# CHI requires Ruby's inerface to support partial functional reads
|
||||
main.Append(NEED_PARTIAL_FUNC_READS=['CHI'])
|
||||
|
||||
main.Append(PROTOCOL_DIRS=[Dir('.')])
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
SimObject('Controller.py', sim_objects=['RubyController'])
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
SimObject('RubyCache.py', sim_objects=['RubyCache'])
|
||||
@@ -57,5 +57,5 @@ Source('TimerTable.cc')
|
||||
Source('BankedArray.cc')
|
||||
Source('ALUFreeListArray.cc')
|
||||
Source('TBEStorage.cc')
|
||||
if env['PROTOCOL'] == 'CHI':
|
||||
if env['CONF']['PROTOCOL'] == 'CHI':
|
||||
Source('MN_TBETable.cc')
|
||||
|
||||
@@ -40,12 +40,12 @@
|
||||
|
||||
Import('*')
|
||||
|
||||
if env['CONF']['PROTOCOL'] == 'None':
|
||||
if not env['CONF']['RUBY']:
|
||||
Return()
|
||||
|
||||
env.Append(CPPDEFINES=['PROTOCOL_' + env['CONF']['PROTOCOL']])
|
||||
|
||||
if env['CONF']['PROTOCOL'] in env['NEED_PARTIAL_FUNC_READS']:
|
||||
if env['CONF']['NEED_PARTIAL_FUNC_READS']:
|
||||
env.Append(CPPDEFINES=['PARTIAL_FUNC_READS'])
|
||||
|
||||
if env['CONF']['BUILD_GPU']:
|
||||
|
||||
27
src/proto/Kconfig
Normal file
27
src/proto/Kconfig
Normal file
@@ -0,0 +1,27 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config HAVE_PROTOBUF
|
||||
def_bool $(HAVE_PROTOBUF)
|
||||
28
src/systemc/Kconfig
Normal file
28
src/systemc/Kconfig
Normal file
@@ -0,0 +1,28 @@
|
||||
# Copyright 2022 Google LLC
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met: redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer;
|
||||
# redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution;
|
||||
# neither the name of the copyright holders nor the names of its
|
||||
# contributors may be used to endorse or promote products derived from
|
||||
# this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
config USE_SYSTEMC
|
||||
bool "Enable SystemC API support"
|
||||
default $(USE_SYSTEMC)
|
||||
@@ -45,6 +45,3 @@ def use_systemc_check(env, warn=False):
|
||||
main.AddMethod(use_systemc_check, 'UseSystemcCheck')
|
||||
|
||||
main['CONF']['USE_SYSTEMC'] = main.UseSystemcCheck()
|
||||
|
||||
sticky_vars.Add(BoolVariable('USE_SYSTEMC', 'Enable SystemC API support',
|
||||
main.UseSystemcCheck()))
|
||||
|
||||
Reference in New Issue
Block a user