NAND_M_PERF_UBIFS_CPU_LOAD source 'common.sh';/opt/ltp/runltp -f ddt/nand_perf_ubifs -s "NAND_S_PERF_UBIFS " -P $PLATFORM -c 8
 
runltp -c
 
in runltp:
 
do  case $arg in
    c)       
            NUM_PROCS=$(($OPTARG))
            if   [ "$NUM_PROCS" -eq 0 ]; then
                # User Did not Define the Value ,or, User Defined Zero,
                # hence, prevent from creating infinite processes
                NUM_PROCS=1
            fi
            $LTPROOT/testcases/bin/genload --cpu $NUM_PROCS >/dev/null 2>&1 &
            GENLOAD=1 ;;
 
 
genload --cpu $NUM_PROCS >/dev/null 2>&1 &
 
-c, --cpu n           spawn n procs spinning on sqrt()\n"
genload in ltp-ddt-backup-servergit\tools\genload
 
->main
else if (strcmp(arg, "--cpu") == 0 || strcmp(arg, "-c") == 0) {
            do_cpu = 1;
            assert_arg("--cpu");
            do_cpu_forks = atoll_b(arg);
 
/* Hog CPU option.  */
    if (do_cpu) {
        out(stdout, "dispatching %lli hogcpu forks\n", do_cpu_forks);

switch (pid = fork()) {
        case 0:    /* child */
            if (do_dryrun)
                exit(0);
            exit(hogcpu(do_cpu_forks));
        case -1:    /* error */
            err(stderr, "hogcpu dispatcher fork failed\n");
            exit(1);
        default:    /* parent */
            children++;
            dbg(stdout, "--> hogcpu dispatcher forked (%i)\n", pid);
        }
    }

 
in hogcpu
 
for (i = 0; forks == 0 || i < forks; i++) {
        switch (pid = fork()) {
        case 0:    /* child */
            alarm(timeout);

/* Use a backoff sleep to ensure we get good fork throughput.  */
            usleep(backoff);

while (1)
                d = sqrt(rand());

/* This case never falls through; alarm signal can cause exit.  */
        case -1:    /* error */
            if (ignore) {
                ++retval;
                wrn(stderr,
                    "hogcpu worker fork failed, continuing\n");
                usleep(retry);
                continue;
            }

err(stderr, "hogcpu worker fork failed\n");
            return 1;
        default:    /* parent */
            dbg(stdout, "--> hogcpu worker forked (%i)\n", pid);
        }
    }

 
 
 
 
 
 
 

ltp-ddt nand_perf_ubifs_w_cpuload的更多相关文章

  1. LTP随笔——本地调用ltp之ltp4j

    关于ltp本地调用的相关参考请见LTP的Git项目:https://github.com/HIT-SCIR 以下以/home/lion/Desktop路径为例下面教程中出现的具体路径以你实际配置的为准 ...

  2. ZH奶酪:自然语言处理工具LTP语言云调用方法

    前言 LTP语言云平台 不支持离线调用: 支持分词.词性标注.命名实体识别.依存句法分析.语义角色标注: 不支持自定义词表,但是你可以先用其他支持自定义分词的工具(例如中科院的NLPIR)把文本进行分 ...

  3. Eclipse DDT

    http://www.eclipse.org/downloads/ https://github.com/DDT-IDE/DDT/blob/latest/documentation/UserGuide ...

  4. ASP.NET中常用的几个李天平开源公共类LTP.Common,Maticsoft.DBUtility,LtpPageControl

    ASP.NET中常用的几个开源公共类: LTP.Common.dll: 通用函数类库     源码下载Maticsoft.DBUtility.dll 数据访问类库组件     源码下载LtpPageC ...

  5. 很好的一篇讲LTP在编解码中的作用的文章

    原文链接 LONG-TERM PREDICTION by: Adit Aviv       Kfir Grichman introduction: The speech signal has been ...

  6. ASP.NET中常用的几个李天平开源公共类LTP.Common,Maticsoft.DBUtility,LtpPageControl (转)

    ASP.NET中常用的几个开源公共类: LTP.Common.dll: 通用函数类库     源码下载Maticsoft.DBUtility.dll 数据访问类库组件     源码下载LtpPageC ...

  7. 编译哈工大语言技术平台云LTP(C++)源码及LTP4J(Java)源码

    转自:编译哈工大语言技术平台云LTP(C++)源码及LTP4J(Java)源码 JDK:java version “1.8.0_31”Java(TM) SE Runtime Environment ( ...

  8. LTP学习

    下载LTP源码和模型文件: https://github.com/linux-test-project/ltp 官方说明文档 http://ltp.readthedocs.org/zh_CN/late ...

  9. LTP 分词算法实践

    参考链接: https://github.com/HIT-SCIR/ltp/blob/master/doc/install.rst http://www.xfyun.cn/index.php/serv ...

随机推荐

  1. Windows环境下使用Mycat模拟分库分表-读写分离案例

    一.基本环境 W7 64位.Mycat1.6.MySQL8.0 二.Mycat核心配置文件配置 解压Mycat1.6,并对server.xml.schema.xml.rule.xml三个核心配置文件做 ...

  2. C# WinFrom 发送邮件

    C# WinFrom 发送邮件 C# Winforms 发送邮件 发送邮件时用到以下来个命名空间: using System.Net; using System.Net.Mail; 发送邮件的发信人邮 ...

  3. 前端通过axios和FormData实现文件上传功能遇到的坑

    使用element-ui中的upload上传组件,前端上传数据参数已经传过去了,但是后端 (java) 接不到数据 (null) [解决方案] html部分: <el-button type=& ...

  4. 在浏览器地址栏中查看cookie

    在IE地址栏中输入javascript:alert(document.cookie) 或者地址栏直接打javascript:document.write(document.cookie);

  5. 【转】excel音标乱码

    源地址:https://zhidao.baidu.com/question/204553900.html 百度一个音标字体文件,下载后再拷贝到C:\WINDOWS\FONTS目录下面就可以了 下载地址 ...

  6. jmeter 命令行运行与生成报告

    一.     使用命令行方式运行Jmeter 1.1 为什么 使用GUI方式启动jmeter,运行线程较多的测试时,会造成内存和CPU的大量消耗,导致客户机卡死. 所以正确的打开方式是在GUI模式下调 ...

  7. ubuntu更换源

    1.备份源 cd  /etc/apt/ sudo cp sources.list sources.list.bak 2.更换阿里源 sudo vim /etc/apt/sources.list   中 ...

  8. Oracle 数据库优化

    Oracle 数据库优化 参考网址

  9. Eclipse总是自动跳到ThreadPoolExecutor

    出现这种状况是因为Eclipse默认开启挂起未捕获的异常(Suspend execution on uncaught exceptions),只要关闭此项就可以了.解决方法:在eclipse中选择Wi ...

  10. AppiumLibrary库倒入后显示红色,日志报错:ImportError: cannot import name 'InvalidArgumentException'

    AppiumLibrary安装后,robotframe worke 倒入后一直显示红色,查看日志报错:ImportError: cannot import name 'InvalidArgumentE ...