0 Replies Latest reply on Jul 10, 2008 2:22 PM by ilsh

    CPU/memory usage of AIR application under Mac 10.4.10

    ilsh Level 1
      As my AIR application uses a lot of CPU/memory under Mac (seems better in Windows), I decide to do some basic testing. I create several applications with different level of complexities. Below is a table of CPU/memory usage when the application is simply sitting there. A brief description of the application can be found in the end of each line.

      Here are some results:
      [1] Even for an empty application, CPU usage is not zero (most non-AIR application has 0 CPU usage when doing nothing). Also the memory usage is huge, comparable to Finder on my computer.
      [2] Empty application has 7 threads running.
      [3] Indetermined progress bar costs a lot of CPU; and I guess any other animation costs a lot of CPU too. But if they are invisible they are fine.
      [4] running timer costs CPU.

      PID COMMAND %CPU TIME #TH #PRTS #MREGS RPRVT RSHRD RSIZE VSIZE application
      10093 adl 1.8% 0:01.85 7 100 292 15.0M 13.8M+ 22.8M 444M empty
      10094 adl 1.9% 0:01.55 7 100 299 15.2M 14.0M+ 23.1M 444M label
      10097 adl 1.9% 0:01.48 7 100 302 15.3M 13.4M 23.7M 445M progress bar
      10095 adl 5.7% 0:02.40 7 100 302 15.4M- 13.2M 23.5M 445M progress bar (indetermined)
      10125 adl 15.9% 0:03.66 7 100 304 15.7M- 13.4M 23.9M 445M 5 progress bar (indetermined)
      10126 adl 29.7% 0:10.39 7 100 325 16.7M+ 13.4M+ 24.9M+ 445M 10 progress bar (indetermined)
      10128 adl 1.9% 0:01.34 7 100 324 16.1M 13.7M 24.3M 445M 10 progress bar (indetermined), visible=false
      10136 adl 1.8% 0:00.76 7 100 323 16.5M+ 13.9M+ 24.7M- 450M Empty datagrid
      10147 adl 1.9% 0:01.60 7 101 328 16.1M 13.8M+ 24.5M- 447M TabNavigator with two empty VBox children
      10138 adl 1.8% 0:01.59 7 100 372 19.4M 13.9M 27.7M 453M datagrid with 10000 simple rows
      10131 adl 3.1% 0:02.38 7 110 348 25.7M 19.3M 34.8M 458M 10 Empty native windows
      10143 adl 1.9% 0:00.99 7 100 296 15.1M 13.9M+ 23.2M- 444M Timer, delay = 100ms, calling an empty function
      10145 adl 4.1% 0:02.35 7 100 298 15.0M 14.0M+ 23.2M- 444M Timer, delay = 100ms, calling function update label position

      As to my own application, it's much bigger than these simple ones. The CPU usually stablizes to 20% and VSIZE is about 1G. There is no timer running. When I leave the application open for a few hours, the application will eventually freeze and I have to kill it.

      I am wondering if there are any articles or documents explaining AIR's CPU/memory usage. And also if AIR is planning to improve the performance in the next release.