• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Python sst.setProgramOption函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Python中sst.setProgramOption函数的典型用法代码示例。如果您正苦于以下问题:Python setProgramOption函数的具体用法?Python setProgramOption怎么用?Python setProgramOption使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了setProgramOption函数的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Python代码示例。

示例1: build

def build(root):
    paramSets = root.find("param_include")
    vars = root.find("variables")
    cfg = root.find("config")
    timebase = root.find("timebase")
    graph = root.find("sst")


    if None != vars:
        processVars(vars)
    if None != paramSets:
        processParamSets(paramSets)
    if None != timebase:
        sst.setProgramOption('timebase', timebase.text.strip())
    if None != cfg:
        processConfig(cfg)
    if None != graph:
        buildGraph(graph)
开发者ID:GrantMackey-WDC,项目名称:sst-core,代码行数:18,代码来源:xmlToPython.py


示例2: read_arguments

[g_config_file_list, g_overrided_list] = read_arguments()
g_params = setup_config_params(g_config_file_list, g_overrided_list)
if "dumpConfig" in g_params and int(g_params["dumpConfig"]):
        print "\n###########################\nDumping global config parameters:"
        for key in g_params:
                print key + " " + g_params[key]
        print "###########################\n"

numChannels = int(g_params["numChannels"])
maxOutstandingReqs = numChannels*64
numTxnPerCycle = numChannels
maxTxns = 100000 * numChannels


# Define SST core options
sst.setProgramOption("timebase", g_params["clockCycle"])
sst.setProgramOption("stopAtCycle", g_params["stopAtCycle"])
sst.setStatisticLoadLevel(7)
sst.setStatisticOutput("sst.statOutputConsole")


#########################################################################################################

## Configure transaction generator
comp_txnGen = sst.Component("TxnGen", "CramSim.c_TxnGen")
comp_txnGen.addParams(g_params)
comp_txnGen.addParams({
	"maxTxns" : maxTxns,
	"numTxnPerCycle" : numTxnPerCycle,
	"maxOutstandingReqs" : maxOutstandingReqs,
	"readWriteRatio" : 0.5
开发者ID:allevin,项目名称:sst-elements,代码行数:31,代码来源:test_txngen.py


示例3:

# Automatically generated SST Python input
import sst
import os

# Define SST core options
sst.setProgramOption("timebase", "1ps")
sst.setProgramOption("stopAtCycle", "5s")

# Define the simulation components
comp_cpu = sst.Component("cpu", "prospero.prosperoCPU")
comp_cpu.addParams({
      	"verbose" : "0",
	"reader" : "prospero.ProsperoBinaryTraceReader",
	"readerParams.file" : "sstprospero-0-0-bin.trace"
})
comp_l1cache = sst.Component("l1cache", "memHierarchy.Cache")
comp_l1cache.addParams({
      "access_latency_cycles" : "1",
      "cache_frequency" : "2 Ghz",
      "replacement_policy" : "lru",
      "coherence_protocol" : "MESI",
      "associativity" : "8",
      "cache_line_size" : "64",
      "L1" : "1",
      "cache_size" : "64 KB"
})
comp_memory = sst.Component("memory", "memHierarchy.MemController")
comp_memory.addParams({
      "coherence_protocol" : "MESI",
      "clock" : "1GHz",
      "backend.access_time" : "1000 ns",
开发者ID:allevin,项目名称:sst-elements,代码行数:31,代码来源:trace-binary-withdramsim.py


示例4: path

# scheduler simulation input file
import sst

# Define SST core options
sst.setProgramOption("run-mode", "both")
sst.setProgramOption("partitioner", "self")

# Define the simulation components
scheduler = sst.Component("myScheduler", "scheduler.schedComponent")
scheduler.addParams({
      "traceName" : "test_scheduler_0003.sim", # job trace path (required)
      "scheduler" : "easy", # cons, delayed, easy, elc, pqueue, prioritize. (default: pqueue)
      "machine" : "mesh[4,5,2]", # mesh[xdim, ydim, zdim], simple. (default: simple)
      "allocator" : "energy", # bestfit, constraint, energy, firstfit, genalg,
                              # granularmbs, hybrid, mbs, mc1x1, mm, nearest,
                              # octetmbs, oldmc1x1,random, simple, sortedfreelist.
                              # (default: simple)
      "taskMapper" : "simple", # simple, rcb, random (default: simple)
      "FST" : "none", # none, relaxed, strict. (default: none)
      "timeperdistance" : ".001865[.1569,0.0129]", # communication overhead params (default: none)
      "runningTimeSeed" : "42", # communication overhead randomization seed (default: none)
      "dMatrixFile" : "DMatrix4_5_2", # heat recirculation matrix path (default: none)
      "coresPerNode" : "1" # default: 1
})

# nodes
n0 = sst.Component("n0", "scheduler.nodeComponent")                    
n0.addParams({                                                         
        "nodeNum" : "0",                                               
})                                                                     
n1 = sst.Component("n1", "scheduler.nodeComponent")                    
开发者ID:GrantMackey-WDC,项目名称:sst-sqe,代码行数:31,代码来源:sdl-3.py


示例5:

import sst
import os

sst.setProgramOption("timebase", "1ps")

sst_root = os.getenv( "SST_ROOT" )

l2PrefetchParams = {
        "prefetcher": "cassini.NextBlockPrefetcher"
        }

ariel = sst.Component("a0", "ariel.ariel")
ariel.addParams({
        "verbose" : "0",
        "maxcorequeue" : "256",
        "maxissuepercycle" : "2",
        "pipetimeout" : "0",
        "executable" : sst_root + "/sst/elements/ariel/frontend/simple/examples/stream/stream",
        "arielmode" : "1",
        "arieltool" : sst_root + "/sst/elements/ariel/fesimple.so",
        "memorylevels" : "1",
        "defaultlevel" : "0"
        })

corecount = 1;

l1cache = sst.Component("l1cache", "memHierarchy.Cache")
l1cache.addParams({
        "cache_frequency" : "2 Ghz",
        "cache_size" : "64 KB",
        "coherence_protocol" : "MSI",
开发者ID:gthparch,项目名称:sst-elements,代码行数:31,代码来源:runstreamNB.py


示例6:

# scheduler simulation input file
import sst

# Define SST core options
sst.setProgramOption("run-mode", "both")

# Define the simulation components
scheduler = sst.Component("myScheduler",             "scheduler.schedComponent")
scheduler.addParams({
      "traceName" : "test_scheduler_Atlas.sim",
      "machine" : "mesh[4,3,6]",
      "coresPerNode" : "8",
      "scheduler" : "easy",
      "allocator" : "bestfit",
      "taskMapper" : "rcb",
      "timeperdistance" : ".001865[.1569,0.0129]",
      "dMatrixFile" : "none",
      "runningTimeSeed" : "42"
})

# nodes
n0 = sst.Component("n0", "scheduler.nodeComponent")
n0.addParams({
      "nodeNum" : "0",
})
n1 = sst.Component("n1", "scheduler.nodeComponent")
n1.addParams({
      "nodeNum" : "1",
})
n2 = sst.Component("n2", "scheduler.nodeComponent")
n2.addParams({
开发者ID:GrantMackey-WDC,项目名称:sst-sqe,代码行数:31,代码来源:test_scheduler_0004.py


示例7: makeAriel

        nextPort += 1
        nextAddr += 1

    # connect to chain
    wrapLink = sst.Link("p%d"%pimNum)
    wrapLink.connect((prevRtr,"port0", netLat),
                     (rtr, "port1", netLat))
    
    sst.popNamePrefix()
    return rtr
        

# "MAIN"

# Define SST core options
sst.setProgramOption("partitioner", "self")
#sst.setProgramOption("stopAtCycle", "2000 us")

#if needed, create the ariel component
if useAriel:
    ariel = makeAriel()

#make the CPU
cpuRtr = doCPU()

#make the PIMs
prevRtr = cpuRtr
for x in range(PIMs):
    prevRtr = doPIM(x, prevRtr)

# complete the torus
开发者ID:GrantMackey-WDC,项目名称:sst-elements,代码行数:31,代码来源:pimExper.py


示例8:

# Automatically generated SST Python input
import sst


#global system params
g_clockCycle  = "1ps"

# Define SST core options
sst.setProgramOption("timebase", g_clockCycle)
sst.setProgramOption("stopAtCycle", "10us")


# Define technology parameters
g_txnParams = {
    "numTxnGenReqQEntries":"""50""",
    "numTxnGenResQEntries":"""50""",
    "numTxnUnitReqQEntries":"""50""",
    "numTxnUnitResQEntries":"""50""",
    "numTxnDrvBufferQEntries":"""50""",
    "relCommandWidth":"""1""",
    "numCmdDrvBufferQEntries":"""50""",
    "readWriteRatio":"""0.5"""
}

# Define the simulation components

# txn gen
comp_txnGen0 = sst.Component("TxnGen0", "CramSim.c_TxnGenSeq")
comp_txnGen0.addParams(g_txnParams)

# txn driver
开发者ID:shavvn,项目名称:sst-elements,代码行数:31,代码来源:test_txngenseq1.py


示例9: MyObject

import sst
from sst.pyproto import *


sst.setProgramOption("stopAtCycle", "10s")


class MyObject(PyProto):
    def __init__(self, name):
        PyProto.__init__(self, name)
        self.name = name
        self.countdown = 10

    def setActiveLink(self, link):
        self.myActiveLink = self.addLink(link, "1us", self._linkHandle)

    def _linkHandle(self, event):
        print self.name, "LinkHandle %s"%event.type
        print self.name, "LinkHandle: ", event.sst


    def construct(self):
        print self.name, "Construct()"

    def init(self, phase):
        print self.name, "init(%d)"%phase

    def setup(self):
        print self.name, "setup()"

    def finish(self):
开发者ID:allevin,项目名称:sst-elements,代码行数:31,代码来源:convertFromSST.py


示例10: makeAriel

        nextAddr += 1

    # connect to chain
    wrapLink = sst.Link("p%d"%pimNum)
    wrapLink.connect((prevRtr,"port0", netLat),
                     (rtr, "port1", netLat))
    
    sst.popNamePrefix()
    return rtr
        

# "MAIN"

# Define SST core options
#sst.setProgramOption("partitioner", "self")
sst.setProgramOption("stopAtCycle", "300 us")
sst.setStatisticLoadLevel(7)   
sst.setStatisticOutput("sst.statOutputConsole")

#if needed, create the ariel component
if useAriel:
    ariel = makeAriel()

#make the CPU
cpuRtr = doCPU()

#make the PIMs
prevRtr = cpuRtr
for x in range(PIMs):
    prevRtr = doPIM(x, prevRtr)
开发者ID:allevin,项目名称:sst-elements,代码行数:30,代码来源:sdl3.py


示例11: processConfig

def processConfig(cfg):
    for line in cfg.text.strip().splitlines():
        var, val = line.split('=')
        sst.setProgramOption(var, processString(val)) # strip quotes
开发者ID:GrantMackey-WDC,项目名称:sst-core,代码行数:4,代码来源:xmlToPython.py


示例12:

# Automatically generated SST Python input
import sst
import os

# Define SST core options
sst.setProgramOption("timebase", "1ns")
sst.setProgramOption("stopAtCycle", "100000ns")

# Define the simulation components
comp_cpu0 = sst.Component("cpu0", "memHierarchy.trivialCPU")
comp_cpu0.addParams({
      "workPerCycle" : """1000""",
      "do_write" : """1""",
      "commFreq" : """100""",
      "memSize" : """0x1000"""
})
comp_c0_l1cache = sst.Component("c0.l1cache", "memHierarchy.Cache")
comp_c0_l1cache.addParams({
      "access_latency_cycles" : """2""",
      "cache_frequency" : """2 Ghz""",
      "replacement_policy" : """lru""",
      "coherence_protocol" : """MSI""",
      "associativity" : """4""",
      "cache_line_size" : """64""",
      "cache_size" : """4 KB""",
      "printStats" : """1""",
      "L1" : """1""",
      "debug" : """"""
})
comp_cpu1 = sst.Component("cpu1", "memHierarchy.trivialCPU")
comp_cpu1.addParams({
开发者ID:GrantMackey-WDC,项目名称:sst-sqe,代码行数:31,代码来源:sdl3-2-edit.py



注:本文中的sst.setProgramOption函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Python sst.setStatisticLoadLevel函数代码示例发布时间:2022-05-27
下一篇:
Python sst.enableAllStatisticsForComponentType函数代码示例发布时间:2022-05-27
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap