研究生: |
魏浩倫 Wei, Hao Lun |
---|---|
論文名稱: |
在Android-QEMU上針對APP具服務元件感知的執行軌跡追蹤機制 App-Based, Component-Service-Aware Trace Generation on Android-QEMU |
指導教授: |
金仲達
King, Chung Ta |
口試委員: |
陳添福
Chen, Tien Fu 李哲榮 Lee, Che Rung |
學位類別: |
碩士 Master |
系所名稱: |
電機資訊學院 - 資訊工程學系 Computer Science |
論文出版年: | 2016 |
畢業學年度: | 104 |
語文別: | 英文 |
論文頁數: | 37 |
中文關鍵詞: | 執行軌跡追蹤 、Android Binder IPC 、Android 應用程式 |
外文關鍵詞: | Trace generation, execution traces, Android Binder IPC, Android application profiling |
相關次數: | 點閱:2 下載:0 |
分享至: |
查詢本校圖書館目錄 查詢臺灣博碩士論文知識加值系統 勘誤回報 |
對行動作業系統的功能、性能和電池壽命週期不斷增長的需求,讓其設計和開發越來越困難。現今的程式設計員倚重使用虛擬平台來紓緩開發工作的難度,如Android-QEMU,虛擬平台讓他們能夠構建和測試其應用程序以及系統軟體。由於虛擬平台是一個以軟體實現的硬體架構,它可以作為一個很好的行動系統開發工具。例如,利用添加追蹤模組的方式產生虛擬系統的執行軌跡,並結合適當的系統時序模型、RTL、SystemC模組等等,我們可以藉此測量和評估不同系統設置的性能。但問題在於,這樣的虛擬平台軌跡追蹤機制所產生的軌跡是架構層級的,缺乏了應用層級的資訊使得我們難以針對特定應用程序去產生執行軌跡。在Android這個行動作業系統底下,此問題變得更加具有挑戰性。Android應用程式採用了單位元件的設計策略,在此機制底下的應用程序會向其他元件(程序)請求遠端服務,而不是含括所有函數庫在其自身的記憶體空間。因此,若要產生特定應用程式的執行軌跡,必須追蹤目標應用程序進行服務調用的執行流程並產生相對應的軌跡。本論文提出一個建立在Android-QEMU上的全新軌跡追蹤系統,它跟蹤了服務元件之間的調用並針對感興趣的特定應用程式產生具元件服務感知的執行軌跡。我們的實驗結果顯示此追蹤系統只需耗費不到1%的模擬時間,增進平均152%的模擬時間,並且節省平均33%的儲存空間。
The increasing demands for functionalities, performance, and battery life cycles have placed very stringent design and development requirements on mobile systems. To ease the development efforts, programmers have relied heavily on virtual platforms, such as Android-QEMU, to build and test their applications as well as system software. Being a software implementation of hardware architecture, virtual platforms are also valuable for mobile system designs. For example, it is easy to add tracing modules to the virtual platforms to dump the execution trace of the guest system, which can then be used to estimate and evaluate the performance of alternative system designs by coupling with appropriate system timing models, RTL or SystemC models, etc. The problem is that tracing in such virtual platforms is basically performed at the architecture level, which makes it difficult to generate trace for specific applications due to a lack of high-level software information. For mobile systems running Android, the problem becomes even more challenging, because Android follows a component-based design strategy, in which applications request services from other components (processes) instead of including everything in its own addressing space. It is thus necessary to track the execution flow of the target application through the service invocations and dump the corresponding execution trace. This thesis presents a novel tracing system on Android-QEMU, which follows the invocations among the service components and generates component-service-aware trace only for the specific applications of interest. Our evaluation results show that the proposed tracing system induces less than 1% overhead in terms of simulation time and improves in average 152% in simulation time and 33% in storage space.
[1] Tran Van Dung, Ittetsu Taniguchi, and Hiroyuki Tomiyama, “Cache simulation for instruction set simulator qemu”, in Dependable, Autonomic and Secure Computing (DASC), 2014 IEEE 12th International Conference on. IEEE, 2014, pp. 441–446.
[2] Michael Backes, Sven Bugiel, and Sebastian Gerling, “Scippa: system-centric ipc prove- nance on android”, in Proceedings of the 30th Annual Computer Security Applications Conference. ACM, 2014, pp. 36–45.
[3] Katalin Popovici and A Jerraya, “Virtual platforms in system-on-chip design”.
[4] Fabrice Bellard, “Qemu, a fast and portable dynamic translator.”.
[5] C.H. Lai Y.H Chen M.L. Chi Z.H. Chen S.C. Lin Y.C. Lin J.M. Lu H.L. Huang, C.C. Wang, “The design of system level power analysis platform”, in Journal of Information and Communication Technology, No.165, Mar 2016, pp. 16–24.
[6] Bojan Mihajlović, Željko Žilić, and Warren J Gross, “Dynamically instrumenting the qemu emulator for linux process trace generation with the gdb debugger”, ACM Trans- actions on Embedded Computing Systems (TECS), vol. 13, no. 5s, pp. 167, 2014.
35[7] “Android fundamentals”, https://developer.android.com/guide/components/ fundamentals.html, [Online; accessed 06-July-2016].
[8] Brad Alexander, Sean Donnellan, Andrew Je ries, Travis Olds, and Nicholas Sizer, “Boosting instruction set simulator performance with parallel block optimisation and replacement”, in Proceedings of the Thirty- fth Australasian Computer Science Conference-Volume 122. Australian Computer Society, Inc., 2012, pp. 11–20.
[9] David Thach, Yutaka Tamiya, Shin’ya Kuwamura, and Atsushi Ike, “Fast cycle estima- tion methodology for instruction-level emulator”, in 2012 Design, Automation & Test in Europe Conference & Exhibition (DATE). IEEE, 2012, pp. 248–251.
[10] Thorsten Schreiber, “Android binder”, 2011.
[11] Amitabh Srivastava and Alan Eustace, ATOM: A system for building customized pro-
gram analysis tools, vol. 29, ACM, 1994.
[12] James R Larus and Eric Schnarr, “Eel: Machine-independent executable editing”, in
ACM Sigplan Notices. ACM, 1995, vol. 30, pp. 291–300.
[13] Ted Romer, Geo Voelker, Dennis Lee, Alec Wolman, Wayne Wong, Hank Levy, Brian Bershad, and Brad Chen, “Instrumentation and optimization of win32/intel executables using etch”.
36
[14] Xiaolan Zhang, Zheng Wang, Nicholas Gloy, J Bradley Chen, and Michael D Smith, “System support for automatic pro ling and optimization”, in ACM SIGOPS Operating Systems Review. ACM, 1997, vol. 31, pp. 15–26.
[15] Chi-Keung Luk, Robert Cohn, Robert Muth, Harish Patil, Artur Klauser, Geo Lowney, Steven Wallace, Vijay Janapa Reddi, and Kim Hazelwood, “Pin: building customized program analysis tools with dynamic instrumentation”, in ACM Sigplan Notices. ACM, 2005, vol. 40, pp. 190–200.
[16] Derek L Bruening, E cient, transparent, and comprehensive runtime code manipula- tion, PhD thesis, Massachusetts Institute of Technology, 2004.
[17] Jonas Maebe, Michiel Ronsse, and Koen De Bosschere, “Diota: Dynamic instrumenta- tion, optimization and transformation of applications”.
[18] Nicholas Nethercote and Julian Seward, “Valgrind: A program supervision framework”, Electronic notes in theoretical computer science, vol. 89, no. 2, pp. 44–66, 2003.
[19] Kevin Scott, Naveen Kumar, Siva Velusamy, Bruce Childers, Jack W Davidson, and Mary Lou So a, “Retargetable and recon gurable software dynamic translation”, in Proceedings of the international symposium on Code generation and optimization: feedback-directed and runtime optimization. IEEE Computer Society, 2003, pp. 36–47.