Stickyminds.com link:
http://app.en25.com/e/es.aspx?s=1156&e=41722&elq=d56f0d59072b44d2a931ed9cbf0938b9
Mobile Testing Enterprise Apps: A Practical Guide
Mobile QA/Test: Real devices or Emulators?
Top 10 Reasons Why Enterprises Should Adopt a Cloud-based Approach for Mobile Application Testing
Learn How to Extend Your Functional and Regression Testing to Mobile Using QTP
Showing posts with label mobility domain. Show all posts
Showing posts with label mobility domain. Show all posts
Wednesday, February 15, 2012
Good read: about mobile emulators
Don't put all your trust in mobile emulators
Steve Souders on how he reduces the development risks of mobile emulators.
Wednesday, January 25, 2012
Mobile web browsers
Browser | Key Features | Operating System | Price |
Opera Mobile | Multiple tabs, Zoom-in | Windows Mobile, Symbian | Not Free |
Opera Mini | Compressed downloads for fast browsing, Zoom-in | Java | Free |
Skyfire | Display rich websites with Flash or widgets like YouTube, customizable zoom feature | Android, iPhone, Symbian, Windows Mobile | Free |
Safari | Display rich websites like YouTube, zoom feature, excellent touch-based user interface | iPhone | Free with iPhone |
Google Android | Display rich websites like YouTube, zoom feature, touch screen interface | Google Android | Free with Android |
Microsoft IE for Mobile | Standard browser features | Windows Mobile | Free with Windows Mobile |
Firefox Mobile | Multiple tabs, Awesomebar, password manager, Add-on support, PC-syncing | Nokia Maemo, Windows Mobile 6.0 (alpha) | Free |
Bolt | Split screen mode, Widgets | Java MIDP 2.0 | Free |
Teashark | Compressed downloads, Multiple tabs | Java MIDP 2.0 | Free |
Blazer | Standard browser features | Palm OS | Free with Palm OS |
Mozilla's Minimo | Multiple tabs, social bookmarking | Windows Mobile | Free (open source) |
Bitstream's Thunderhawk | Compressed downloads for fast browsing, Zoom-in | Symbian S60, Windows Mobile, Java | Not Free |
S60 Web Browser | Standard browser features | S60 | Free with S60 |
Mobile application development Environment
Programming language | Debuggers available | Emulator available | Integrated development environment available | Cross-platform deployment | Installer packaging options | Development tool cost | |
Adobe AIR | Action Script, HTML, CSS, JavaScript | Yes | Yes | Flash Builder, Flash Professional | iOS (iPhone, iPad, iPod touch), Android, BlackBerry | The native distribution format of each platform | Flash Builder, Flash Professional - Commercial licenses available Adobe AIR SDK (command line tool) - Free |
Airplay SDK (Now Marmalade) | C, C++ | Yes | Yes | Visual Studio, XCode | All native: Android, BlackBerry, BREW, iOS (iPhone), Maemo, Palm/webOS, Samsung bada, Symbian, Windows Mobile 6.x and desktop, OSX | The native distribution format of each platform | Commercial licenses available |
alcheMo | Java | Debugger integrated in Visual Studio, Eclipse or XCode | Emulator is available in corresponding IDE | Visual Studio, Eclipse, XCode | Android, BREW, iOS (iPhone), Windows Mobile | The native distribution format of each platform | Commercial licenses available |
Android | Java but portions of code can be in C, C++ | Debugger integrated in Eclipse, standalone debugging monitor available | Yes | Eclipse, Project Kenai Android plugin for NetBeans | Android only, because of Dalvik VM, March 2009 | apk | Free |
Application Craft | JavaScript, HTML5, CSS | Yes | Yes, Emulator used is Ripple | Cloud Based IDE | All platforms: Android, iOS, Blackberry, Windows Mobile, Bada, WebOS, Symbian. Mobile, Desktop and Tablet | Cloud/ browser based | Free and Open Source |
Appcelerator | JavaScript | Yes, in Titanium Studio, currently in beta. | Emulator is available using 3rd party tools | Internal SDK | Android, iPhone; BlackBerry planned | The native distribution format of each platform | Apache 2.0 license, commercial licenses available |
Appception | HTML5, CSS, JavaScript | Yes | Yes | Cloud-based IDE | Android | The native distribution format of each platform | Free and Commercial licenses available |
appMobi | HTML5 (JavaScript,CSS3,HTML5) | Yes, XDK (Google Chrome App Store) | Yes, In XDK | Integrates with developer's preferred tool (VS, Notepad ++, VI) | iOs, Android, HTML5 Web Apps, HTML5 Hybrid Apps | The native distribution format of each platform | No Charge |
Aqua | C, C++, JavaScript | Yes | Yes | Visual Studio, XCode, Eclipse | Android, BlackBerry Playbook, iOS, Palm/webOS, Samsung bada, Windows Mobile 6.x, Windows Desktop | The native distribution format of each platform | Free & commercial licenses available |
Basic4android | Visual Basic | Yes | Yes | Yes | Android | apk | Commercial licenses available |
BatteryTech | C, C++ | Yes | Native Platform Emulators (iOS, Android...) | Eclipse, Visual Studio, XCode | Android, iOS (iPhone), Windows, OSX | The native distribution format of each platform | Commercial licenses available |
Bedrock now webMethods Mobile Designer | Java | Yes | Yes | Eclipse | Java ME, Android, BREW, BlackBerry, Nintendo DS, iOS (iPhone/iPad), Palm/webOS, Sony PSP, Samsung bada, Symbian, Windows Mobile, Windows Phone 7, Windows Desktop, OSX | The native distribution format of each platform | Commercial licenses available |
BlackBerry | Java | Debugger integrated in IDE | Yes | Eclipse | BlackBerry only, because of RIM API | alx, cod | Free |
Blueprint | XML routed through Yahoo Mobile servers and displayed in native browsers | None beyond a schema check | N/A, translates to web or mobile as needed | N/A, any XML editor | N/A, translates to web or mobile as needed | Combined config upload at Yahoo with self-hosted dynamic XML | Any XML editor |
BREW | C; the APIs are provided in C with a C++ style interface | Debugger support for the native ARM target code.Can use Visual Studio to debug the x86 testing code | No Emulator for the target ARM code, has a simulator for the x86 testing code | Visual Studio 6.0, Visual Studio 2003 .NET, Visual Studio 2005 | Compile for the specific BREW version available on the handset | OTA | Related dev fees typically needed for Brew App Certification - VeriSign annual fee for becoming a certified developer. Realview ARM compiler for BREW (the free GNU C/C++ is available, but with limited function and support). TRUE BREW testing fee for distributing the application. |
Canappi | mdsl, easy to learn programming language dedicated to mobile solutions, from which iOS, Android, ... code is generated | Native Platform Debuggers (iOS, Android...) | Native Platform Emulators (iOS, Android...) | Eclipse, with mdsl plugin, Apple Interface Builder and Balsamiq for graphical UI design | iOS, Android. Design tools like Interface Builder can be used in a cross-platform way. You create your GUI once in Interface Builder you generate code for all platform, all resolutions from a single file. | Native deployment for each platform | Free & commercial licenses available |
Celsius | Java | Yes | Yes | Eclipse | Java ME, Android, BlackBerry, iPhone, Symbian, Windows Mobile | The native distribution format of each platform of a Java binary | Commercial licenses available |
CloudPact | HTML, CSS, JavaScript | Yes | Yes | Web based IDE both on Cloud and as downloadable version | Android, BlackBerry, iPhone, Windows Mobile | OTA deployment or the native distribution format of each platform | Free limited trial and Enterprise plans available |
CoStore | Web-based drag-and-drop | N/A | Yes | Web-based app builder | iOS, Android, HTML5 | Native deployment for each platform or web-based | Free unlimited trial; commercial licenses available for deployment |
Corona SDK | Lua | Yes | Yes | Xcode | iOS, Android, NOOK Color | Native deployment for each platform | Free unlimited trial; commercial licenses available for deployment |
DragonRAD | Visual drag & drop tiles | Yes | Uses 3rd party emulators | Proprietary IDE | Android, BlackBerry, Windows Mobile | OTA deployment | Free & commercial licenses available |
FeedHenry | HTML, CSS, JavaScript | Yes | Yes | Studio includes full IDE and Eclipse Plug-in | Apple iPhone & iPad, Android, Windows Phone 7, Blackberry, Nokia WRT. | The native distribution format of each platform | Free, Professional and Enterprise Plans available |
GeneXus for Mobile and Smart Devices | Knowledge Representation and Declarative Modeling for easy development, then code is automatically generated for each platform | No | Publish in the Cloud, test native in the device (No emulator required) | Proprietary IDE | Android, Apple iOS (iPhone, iPad), BlackBerry and even HTML5 if desired | The native distribution format of each platform and also Cloud/browser based | Free to try, Commercial and Enterprise licenses available |
Gideros Mobile | Lua | No | Yes | Proprietary IDE | iPhone, iPad, iPod Touch, Android | The native distribution format of each platform | Free & commercial licenses available |
iOS SDK | Objective-C | Debugger integrated in Xcode IDE | Bundled with iPhone SDK, integrated with Xcode IDE | Xcode | iPhone, iPad, iPod Touch | Only via App Store, needs review and approval by Apple Inc. | Tools are free for an Intel-based Mac. Simulator testing is free, but installing on a device needs a fee for a developer signing key |
iOS SDK | Object Pascal | Debugger integrated in Xcode IDE | Included in Delphi XE2 professional or higher | Embarcadero Delphi XE2 | iPhone, iPad, iPod Touch | Only via App Store, needs review and approval by Apple Inc. | Development requires Intel-based Mac besides the IDE on Windows. Design is on Windows, Compilation and deployment has to be done on Mac. Simulator testing is free, but installing on a device needs a fee for a developer signing key |
IwGame Engine | C/C++ | Visual Studio / XCode debuggers | Yes, via the Marmalade SDK simulator | Visual Studio / XCode | [iPhone, iPod and iPad, Android, Bada, Blackberry BBX (Playbook), Symbian, WebOS, Windows Mobile, Mobile Linux, LG-TV, Windows Desktop, Mac OSX] | The native distribution format of each platform | Engine is free and open source, uses the Marmalade SDK - [1] |
Java ME | Java | Yes | Free emulator, Sun Java Wireless Toolkit, mpowerplayer | Eclipse, LMA NetBeans Mobility Pack | Yes although many VM implementations have device specific bugs necessitating separate builds | Jad/Jar packaging; PRC files under Palm OS | Free |
JMango | JMango | N/A | N/A | JMango Flash IDE | Java ME, Android, Bada, BlackBerry, iPhone, Windows Mobile 6, Windows Phone 7 | The native distribution format of each platform | Free |
July Systems Mi™ Platform | Java, HTML, Groovy, FreeMarker, Java Script | Yes | Yes | IDE – Eclipse with GUI Editor | iOS, Android, Blackberry, WP7, Mobile Web, HTML5, QT | Native distribution format for each platform | Commercial licenses available |
Kony | Graphical Drag and Drop | Yes | Yes, utilizes Native Platform Emulators( iOS, Android, BlackBerry, Windows Phone 7) | Eclipse-based | Yes. Support for full OS-native, hybrid, and wrapper applications. Includes Android, BlackBerry, iOS, Java ME, Palm/webOS, Symbian, Windows Phone 7. Mobile web browser support (WML through to device-optimized HTML5) | The native distribution format of each platform | Commercial licenses available |
Lazarus | Object Pascal | Yes, can debug in IDE via ActiveSync for Windows CE | Uses the emulators of the platforms | Lazarus IDE, including integrated GUI designer and debugger | Compiled language available for Windows CE, Linux-based devices, SymbianOS port in development | The native distribution format of each platform | Free |
Macromedia Flash Lite | ActionScript | Yes | Bundled with IDE | Macromedia Flash MX2004/8, Eclipse | Yes | SIS / CAB deployment or OTA/IR/Bluetooth SWF files | Varies, free but limited with MTASC |
Microbrowser based | XHTML (WAP 2.0), WML (WAP 1.2) | Yes | Many | Many | Basic page rendering with per page customizations for different browsers | N/A | Free |
Meme IDE | Memescript easy to learn programming language | Validation is provided in the problems view | Yes, Android emulator can be integrated | Eclipse RCP | Android, Windows Mobile | The native distribution format if each platform | Free for development |
MobiFlex | Visual drag & drop tiles | N/A | N/A, runs on phone in seconds | Web Portal, comes with data management add-ins | Android, iPhone | N/A | Free for development only |
MobileNationHQ | Visual paradigm/javascript | N/A | N/A instant cloud-based deployment | Integrated SaaS environment | Android, iPhone | N/A | Free and Commercial licenses available |
Moscrif | JavaScript | N/A | Bundled with Moscrif SDK | Internal SDK (Mono based) | All native: Android, iOS (iPhone), Samsung bada, Symbian, Windows Mobile | The native distribution format of each platform | Free & commercial licenses available |
Mono for Android | C# | Yes | Yes | Visual Studio 2005 and MonoDevelop | Android | The native distribution format of the platform | |
MonoTouch | C# | Yes | Yes | Visual Studio 2005 and MonoDevelop | iOS | The native distribution format of the platform | |
MoSync | C, C++, Lua, HTML5, CSS, JavaScript | Yes | Yes | Eclipse, Visual Studio 2005 and later, MoBuild w/ text editors | Android, Java ME, Moblin, iOS (iPhone), Smartphone 2003, Symbian, Windows Mobile (Pocket PC), Blackberry (experimental) | SIS, CAB, JAD, JAR, APK, OTA deployment | Free, GPL 2.0, Free Indie Subscription; commercial subscription available |
NeoMAD | Java | Yes | Uses 3rd party emulators | Eclipse and Netbeans plugin | Java ME, Android, BlackBerry, Windows Phone 7, iOS (iPhone) and Samsung bada coming soon | The native distribution format of each platform | Commercial licenses available |
.NET Compact Framework | C#, VB.NET, Basic4ppc | Yes | Free emulator, source code available, also bundled with IDE | Visual Studio 2008, 2005, 2003, Basic4ppc IDE | Windows Mobile, Windows CE, Symbian-based devices via third party tools | OTA deployment, CAB files, ActiveSync | Most tools free, but commercial editions of Visual Studio needed for visual designers |
NS BASIC/App Studio | Visual Basic | Yes | No, Test in Chrome or Safari Browser | Proprietary IDE | iPhone, iPad, iPad Touch, Android 2.1+ | Java Web App or native deployment using Phonegap | Evaluation Version & Commercial Licenses available |
OpenPlug | ActionScript, XML | Yes | Yes | OpenPlug ELIPS plugin for Adobe Flash Builder | Android, iOS (iPad, iPhone, iPod Touch), Symbian, Windows Mobile | The native distribution format of each platform | Free & commercial licenses available |
Palm OS | C, C++, Pascal | Yes | OS 1.0 - 4.1: Free Emulator provided by PalmSource (Access); OS 5.0: - 5.4 Device-specific Simulators provided by Palm (palmOne) | Palm OS Development System (Eclipse), CodeWarrior, PocketStudio, HB++, Satellite Forms | Palm OS handhelds, or Windows Mobile with StyleTap emulator | PRC files, PalmSource Installer (.psi) | Free (POSE or GCC for Palm OS), or commercial (CodeWarrior), or various commercial rapid-development frameworks |
Particle SDK | Java, ActionScript | Yes | Yes | Eclipse plugin with GUI editor | Android, BlackBerry, iOS, webOS, and Windows Phone 7 mobile devices plus Flash, HTML5 web apps | The native distribution format of each platform | Currently in free beta. Commercial license will be available. |
PhoneGap | HTML, CSS, JavaScript | Yes | No, 3rd party tools | No, 3rd party tools | iPhone, Android, BlackBerry, Symbian, Palm | The native distribution format of each platform | MIT license |
Python | Python | Yes | Add-on to Nokia Emulator | Several, including plugins for Eclipse | Interpreted language available natively only on Nokia Series60 (and desktops) though ports exist to other mobile platforms, including PalmOS | Sis deployment with py2sis or can use Python Runtime | Free |
Qt SDK | C++, QML | Yes | Yes | Qt Creator | Symbian platform, Maemo, MeeGo, Linux, Windows, Mac OS X | The native distribution format of each platform | Free & commercial licenses available |
Resco MobileForms Toolkit | C# | Yes | Yes | Visual Studio | Windows Mobile (Pocket PC), Windows CE, Android, iOS, Smartphone | The native distribution format of each platform | Free & commercial licenses available |
Rhomobile | Ruby with HTML interface features compiled through an interpreter into native applications. | Yes | N/A, applications can run in Win32 runner, or in device emulators for supported platforms. | xCode or Eclipse, on-demand RhoHub version includes full IDE | Yes, supports iOS (incl. 3.0) on iPhone and iPad, Windows Mobile 6.1 Professional, Mobile Windows 6.0 Standard, BlackBerry 4.6, 4.7, 5.0, 6.0 (BlackBerry 4.2 and 4.5 supported but database access is very slow on these devices), Symbian and Android 1.6 and higher | OTA deployment, iOS through App store, .SIS, .CAB, .APK, .COD | Rhodes is free and open source under the MIT License, RhoSync is under GPL or commercial, Commercial support available. Subscription for RhoHub |
Smartface Platform | Drag-and-drop tools and action editing | No, not needed | Yes | Smartface Designer | Yes: Android, BlackBerry, J2ME, Symbian S60 | The native distribution format of each platform | Community licenses available |
Symbian | C++ | Yes | Free Emulator | Many choices | Compile per target | SIS deployment | Commercial and free tools available |
TotalCross | Java | Yes | Yes | Eclipse, TKN Mobile Studio for TotalCross | Android, BlackBerry, iOS (iPhone, iPad), Palm OS, Windows Mobile. Windows Phone 7, Symbian planned | The native distribution format of each platform (cab, jad, apk, pdb/prc, deb) | SDK is open source and free for desktop development. VM for target devices must be licensed |
Unity | C#, JavaScript, Boo, other .NET based languages | Yes | Remote used to simulate device interaction before app is uploaded to the device. | Unity Editor, also works with Visual Studios and MonoDevelop. | Android, iOS (iPhone/iPad), PC, Mac, desktop browser, XBOX360, PS3, Wii. BlackBerry Playbook, Nokia Symbian, Roku 2 and others available through company's Union program. | The native distribution format of each platform. | Free and commercial development licenses. |
WebORB Integration Server | C#,VB.NET, Java, PHP, ActionScript, JavaScript, Objective-C, XML | Yes | Uses emulator for corresponding mobile SDKs | Works with Eclipse, Visual Studio, intelliJ IDEA and Amethyst IDE | Android, iOS (iPhone/iPad), BlackBerry Playbook, Windows Phone7 | The native distribution format of each platform | Free development licenses; Free and Commercial deployment licenses |
webOS | JavaScript, CSS, HTML, C and C++ through the PDK | Yes | Free emulator | Eclipse | webOS, Palm only | OTA deployment, webOS through App store, Web URL, Precentral, .ipk | Free |
WinDev Mobile | WLanguage | Yes | Yes | WinDev Mobile, Android DSK | Android, Windows Mobile | OTA deployment, apk, CAB files, ActiveSync | Commercial licenses available |
Windows Mobile | C, C++ | Yes | Free emulator (source code available), also bundled with IDE | Visual Studio 2010, 2008, 2005, eMbedded VC++ (free), Satellite Forms | Windows Mobile, Windows FU, Windows CE | OTA deployment, CAB files, ActiveSync | Free command-line tools or eMbedded VC++, or Visual Studio (Standard edition or better) |
Windows Phone | C# | Yes | Free emulator, also bundled with IDE | Visual Studio 2010 | Windows Phone | OTA deployment, XAP files | |
Worklight | Choice of standard HTML5, CSS and JavaScript, native languages or a combination of both | Yes | Bundled with the IDE as well as device SDK integration | Eclipse-based plug-in | Yes, supports Android, BlackBerry, iOS and Windows Phone 7, as well as modern mobile browsers for web apps | The native distribution format of each platform | Free evaluation version, commercial licenses available |
Fivespark | Web-based point and click | N/A | Preview in desktop browser | Web-based app builder | Android, BlackBerry, iOS and Windows Phone 7 plus other modern mobile browsers | HTML5 OTA | Free for development |
Tiggr - Mobile Apps Builder | Web-based, visual editor, HTML5, CSS, JavaScript, jQuery Mobile, PhoneGap | Yes, in special debug window | No need, test right in browser or device | Web-based, can also export to Eclipse or Maven project | Mobile Web (HTML/JS/CSS), iOS, Android, BlackBerry, Windows Phone 7 | The native distribution format of each platform or mobile Web (HTML/JS/CSS) | In free beta, subscription will be available in the future |
Tuesday, January 24, 2012
Monitor performance using DDMS (Android)
Performance monitoring:
DDMS provides Threads, VMHeap, Allocation Tracker, Emulator control and other tabs to monitor application performance. The following sections describe how to use DDMS and the various tabs and panes that are part of the DDMS GUI
Examining thread information
The Threads tab in DDMS shows you the currently running threads for a selected process.

Heap and non-Heap memory
The device JVM memory consists of the following segments:
Viewing heap usage for a process
DDMS allows you to view how much heap memory process is using. This information is useful in tracking heap usage at a certain point of time during the execution of your application.
The Dalvik virtual machine can produce a complete dump of the contents of the virtual heap. This is very useful for debugging memory usage and looking for memory leaks.
To view heap usage for a process:
There are many types of objects that are identified by DVM which are categorized as below.
Allocation Tracker
In a performance-sensitive code path, such as the layout or drawing method of a view or the logic code of a game, any allocation comes at a price. After too many allocations, the garbage collector will kick in and stop your application to let it free some memory. Most of the time, garbage collections happen fast enough for you not to notice. However, if a collection happens while you are scrolling through a list of items or while you are trying to defeat a foe in a game, you may suddenly see a drop in performance/responsiveness of the application. It's not unusual for a garbage collection to take 100 to 200 ms. For comparison, a smooth animation needs to draw each frame in 16 to 33 ms. If the animation is suddenly interrupted for 10 frames, you can be certain that your users will notice.
Most of the time, garbage collection occurs because of tons of small, short-lived objects and some garbage collectors, like generational garbage collectors, can optimize the collection of these objects so that the application does not get interrupted too often. The Android garbage collector is unfortunately not able to perform such optimizations and the creation of short-lived objects in performance critical code paths is thus very costly for your application.
To help you avoid frequent garbage collections, the Android SDK ships with a very useful tool called allocation tracker. This tool is part of DDMS, which you must have already used for debugging purposes. To start using the allocation tracker, you must first launch the standalone version of DDMS, which can be found in the tools/ directory of the SDK. The version of DDMS included in the Eclipse plugin does not offer you ability to use the allocation tracker yet. Once DDMS is running, simply select your application process and then click the Allocation Tracker tab. In the new view, click Start Tracking and then use your application to make it execute the code paths you want to analyze. When you are ready, click Get Allocations. A list of allocated objects will be shown in the first table. By clicking on a line you can see, in the second table, the stack trace that led to the allocation. Not only you will know what type of object was allocated, but also in which thread, in which class, in which file and at which line.
File System
DDMS provides a File Explorer tab that allows you to view, copy, and delete files on the device. You can view this tab by going to the ‘Device’ menu and clicking on the ‘File Explorer’ tab. Using this feature the user can examine files that are created by your application or if you want to transfer files to and from the emulator/device to the local machine.
To work with an emulator or device's file system:
DDMS provides Threads, VMHeap, Allocation Tracker, Emulator control and other tabs to monitor application performance. The following sections describe how to use DDMS and the various tabs and panes that are part of the DDMS GUI
Examining thread information
The Threads tab in DDMS shows you the currently running threads for a selected process.
- Select the process that you want to examine the threads for.
- Click the Update Threads button.
- In the Threads tab, you can view the thread information for the selected process.
- “main” (see name column) thread is your applications process
- Click on refresh button to view class and method information.
- If Native = false, method/class is from application, else method/class is from Android OS.
Heap and non-Heap memory
The device JVM memory consists of the following segments:
- Heap Memory, which is the storage for Java objects
- Non-Heap Memory, which is used by Java to store loaded classes and other meta-data
- JVM code itself, JVM internal structures, loaded profiler agent code and data, etc.
Viewing heap usage for a process
DDMS allows you to view how much heap memory process is using. This information is useful in tracking heap usage at a certain point of time during the execution of your application.
The Dalvik virtual machine can produce a complete dump of the contents of the virtual heap. This is very useful for debugging memory usage and looking for memory leaks.
To view heap usage for a process:
- Select the process that you want to see the heap information for.
- Click the Show Heap Updates button to enable heap information for the process.
- In the VM Heap tab, click Cause GC to invoke garbage collection, which enables the collection of heap data. When the operation completes, you will see a group of object types and the memory that has been allocated for each type. You can click Cause GC again to refresh the data.
- Click on an object type in the list to see a bar graph that shows the number of objects allocated for a particular memory size in bytes.
There are many types of objects that are identified by DVM which are categorized as below.
- Class Objects are instances of Class, e.g. what you'd get from java.lang.String.class or myObject.getClass().
- The arrays are binned by size. For example, 2-byte arrays could be short[] or char[]. 4-byte arrays include float[], int[], and all Object[].
- A non-Java Object is a piece of memory that isn't actually accessible from code written in Java. Essentially it's a blob of stuff that got stuck on the virtual heap but has no meaning to interpreted code. Shouldn't be much of that.
- Data Objects are objects that don't fall into one of the special categories. ArrayList, HashMap, whatever.
Allocation Tracker
In a performance-sensitive code path, such as the layout or drawing method of a view or the logic code of a game, any allocation comes at a price. After too many allocations, the garbage collector will kick in and stop your application to let it free some memory. Most of the time, garbage collections happen fast enough for you not to notice. However, if a collection happens while you are scrolling through a list of items or while you are trying to defeat a foe in a game, you may suddenly see a drop in performance/responsiveness of the application. It's not unusual for a garbage collection to take 100 to 200 ms. For comparison, a smooth animation needs to draw each frame in 16 to 33 ms. If the animation is suddenly interrupted for 10 frames, you can be certain that your users will notice.
Most of the time, garbage collection occurs because of tons of small, short-lived objects and some garbage collectors, like generational garbage collectors, can optimize the collection of these objects so that the application does not get interrupted too often. The Android garbage collector is unfortunately not able to perform such optimizations and the creation of short-lived objects in performance critical code paths is thus very costly for your application.
To help you avoid frequent garbage collections, the Android SDK ships with a very useful tool called allocation tracker. This tool is part of DDMS, which you must have already used for debugging purposes. To start using the allocation tracker, you must first launch the standalone version of DDMS, which can be found in the tools/ directory of the SDK. The version of DDMS included in the Eclipse plugin does not offer you ability to use the allocation tracker yet. Once DDMS is running, simply select your application process and then click the Allocation Tracker tab. In the new view, click Start Tracking and then use your application to make it execute the code paths you want to analyze. When you are ready, click Get Allocations. A list of allocated objects will be shown in the first table. By clicking on a line you can see, in the second table, the stack trace that led to the allocation. Not only you will know what type of object was allocated, but also in which thread, in which class, in which file and at which line.
File System
DDMS provides a File Explorer tab that allows you to view, copy, and delete files on the device. You can view this tab by going to the ‘Device’ menu and clicking on the ‘File Explorer’ tab. Using this feature the user can examine files that are created by your application or if you want to transfer files to and from the emulator/device to the local machine.
To work with an emulator or device's file system:
- In the File explorer tab, select the file that you want ot view.
- To copy a file from the device/emulator, locate the file in the File Explorer and click the Pull file button.
- To copy a file to the device/emulator, click the Push file button on the File Explorer tab.
Labels:
android,
emulator,
mobile application testing,
mobility domain
Subscribe to:
Posts (Atom)