中文字幕 另类精品,亚洲欧美一区二区蜜桃,日本在线精品视频免费,孩交精品乱子片免费

<sup id="3hn2b"></sup>

    1. <sub id="3hn2b"><ol id="3hn2b"></ol></sub><legend id="3hn2b"></legend>

      1. <xmp id="3hn2b"></xmp>

      2. 新聞中心

        EEPW首頁 > 嵌入式系統(tǒng) > 設(shè)計應(yīng)用 > 多線程編程之:Linux線程編程

        多線程編程之:Linux線程編程

        作者: 時間:2013-09-13 來源:網(wǎng)絡(luò) 收藏


        本文引用地址:http://www.antipu.com.cn/article/257101.htm

        接下來可以在線程運(yùn)行前后使用“free”命令查看內(nèi)存的使用情況。以下是運(yùn)行結(jié)果:


        $ ./thread_attr

        Create tread success

        Waiting for thread to finish...

        Thread is starting

        Waiting for thread to finish...

        Thread : job 0 delay = 3

        Waiting for thread to finish...

        Thread : job 1 delay = 2

        Waiting for thread to finish...

        Waiting for thread to finish...

        Waiting for thread to finish...

        Waiting for thread to finish...

        Thread : job 2 delay = 9

        Thread finished


        /* 程序運(yùn)行之前 */

        $ free

        total used free shared buffers cached

        Mem: 255556 191940 63616 10 5864 61360

        -/+ buffers/cache: 124716 130840

        Swap: 377488 18352 359136


        /* 程序運(yùn)行之中 */

        $ free

        total used free shared buffers cached

        Mem: 255556 191948 63608 10 5888 61336

        -/+ buffers/cache: 124724 130832

        Swap: 377488 18352 359136


        /* 程序運(yùn)行之后 */

        $ free

        total used free shared buffers cached

        Mem: 255556 191940 63616 10 5904 61320

        -/+ buffers/cache: 124716 130840

        Swap: 377488 18352 359136


        可以看到,線程在運(yùn)行結(jié)束后就收回了系統(tǒng)資源,并釋放內(nèi)存。

        linux操作系統(tǒng)文章專題:linux操作系統(tǒng)詳解(linux不再難懂)

        linux相關(guān)文章:linux教程



        上一頁 1 2 3 4 5 6 7 8 下一頁

        評論


        相關(guān)推薦

        技術(shù)專區(qū)

        關(guān)閉