zoukankan      html  css  js  c++  java
  • MCPS & MIPS

    MIPS:Million Instructions Per Second

    MCPS:Million Cycles Per Second

    MIPS = Total Instructions*Sampling frequency/(No of frames * Samples per frame*1000000)

    MCPS = Total Cycles*Sampling frequency/(No of frames * Samples per frame*1000000)
    MHz is same as MCPS

    And as we know , some instructions may take more than 1 cycle ,so sometimes MIPS >= MCPS.

    But as the Parallel Processing technique developing, one cycle can excute more than one  instruction, so sometime MCPS>=MIPS

    Also some time the frame length is not uniform, so the they will be

    MIPS = Total Instructions/(Total playout time *1000000)

    MHz=MCPS = Total Cycles/(Total playout time*1000000)

    For example:

    struct timespec start, end;

    unsinged long diff_ns;

    clock_gettime(CLOCK_THREAD_CPUTIME_ID, &start);

    process()// process fixed in CPU core, process N samples;

    clock_gettime(CLOCK_THREAD_CPUTIME_ID, &end);

    diff_ns = (end.tv_sec - start.tv_sec) * 1000000000 + (end.tv_nsec - start.tv_nsec) ;

    cpu_freq: 1GHz. 1秒钟经过的时钟周期

    Cycles是处理N个samples所需要的时钟周期

    Cyles:diff_ns * cpu_freq = (diff_ns / 1000000000) * 1 GHz =  (diff_ns / 1000000000) * 1000000000Hz;

    处理N个samples所需要的时间为:N samples / sampling frequency

    MCPS = (Cycles / (N Samples / Sample Frequency)) / 1000000;

  • 相关阅读:
    Spark概念介绍
    KVM web管理工具——WebVirtMgr(一)
    Spark集群搭建
    阿里云DTS VS MySQLdump
    MySQL性能分析和优化-part 1
    为什么logstash进程的CPU使用率100%?
    技本功丨互联网+工业视觉异常检测分析
    Spark集群管理器介绍
    某云下系统上云方案及成本计算
    企业混合云架构设计
  • 原文地址:https://www.cnblogs.com/fellow1988/p/12283539.html
Copyright © 2011-2022 走看看