Android的DDMS中的Threads的各個欄位的含義

來源:互聯網
上載者:User

在使用DDMS調試代碼時,Threads視窗中各個欄位的含義從網上搜了下,如下所示:

該標籤頁顯示了如下資訊:

  • ID

    – a VM-assigned unique thread ID. In Dalvik, these are odd numbers starting from 3.

    – 虛擬機器分配的唯一線程ID. 在 Dalvik, 該數字是一個從3開始的奇數.

  • Tid

    – the Linux thread ID. For the main thread in a process, this will match the process ID.

    – Linux 線程 ID. 進程中主線程的ID, 會同進程的ID相匹配.

  • Status

    – the VM thread status. Daemon threads are shown with a ‘*’. This will be one of the following:

    – 虛擬機器線程狀態. 守護進程會附帶一個’*’. 狀態資訊列表如下:

    • running – executing application code  – 正在執行應用程式
    • sleeping – called Thread.sleep()  – 執行了Thread.sleep() 方法
    • monitor – waiting to acquire a monitor lock – 在正等待擷取一個監聽鎖
    • wait – in Object.wait() – 在Object.wait() 方法中
    • native – executing native code  – 執行了原生代碼
    • vmwait – waiting on a VM resource – 正在等待一個虛擬機器資源
    • zombie – thread is in the process of dying  – 該線程已死
    • init – thread is initializing (you shouldn’t see this) – 線程正在初始化 (你不會看到這個)
    • starting – thread is about to start (you shouldn’t see this either) – 線程正在啟動中 (這個你也不會看到)
  • utime

    – cumulative time spent executing user code, in “jiffies” (usually 10ms). Only available under Linux.

    – 執行使用者代碼的累計時間, 單位為”jiffies(表示系統啟動以來的tick數)” (通常是 10ms). 僅在Linux系統中適用.

  • stime

    – cumulative time spent executing system code, in “jiffies” (usually 10ms).

    – 執行系統代碼的累計時間, 單位為”jiffies(表示系統啟動以來的tick數)”.

  • Name

    – the name of the thread

    – 線程的名字

“ID” and “Name” are set when the thread is started. The remaining fields are updated periodically (default is every 4 seconds).

“ID” 和 “Name” 在進程啟動的時候就會顯示. 其餘的欄位每個一段時間更新一次(預設是4秒鐘)

參考:http://goodhank.blog.163.com/blog/static/599726902010129304242/

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.