Abstract
Prior to their deployment on an embedded system, operating systems are commonly tailored to reduce code size and improve runtime performance. Program specialization is a promising match for this process: it is predictable and modules, and it allows the reuse of previously implemented specializations. A specialization engine for embedded systems must overcome three main obstacles: (i) Reusing existing compilers for embedded systems, (ii) supporting specialization on a resource-limited system and (iii) coping with dynamic applications by supporting specialization on demand.
In this article, we describe a runtime specialization infrastructure that addresses these problems. Our solution proposes: (i) Specialization in two phases of which the former generates specialized C templates and the latter uses a dedicated compiler to generate efficient native code. (ii) A virtualization mechanism that facilitates specialization of code at a remote location. (iii) An API and supporting OS extensions that allow applications to produce, manage and dispose of specialized code.
We evaluate our work through two case studies: (i) The TCP/IP implementation of Linux and (ii) The TUX embedded web server. We report appreciable improvements in code size and performance. We also quantify the overhead of specialization and argue that a specialization server can scale to support a sizable workload.
- Adams, S., Ball, T., Das, M., Lerner, S., Rajamani, S. K., Seigle, M., and Weimer, W. 2002. Speeding up dataflow analysis using flow-insensitive pointer analysis. In Proceedings of the International Static Analysis Symposium. 230--246.]] Google Scholar
Digital Library
- Bershad, B., Savage, S., Pardyak, P., Gün Sirer, E., Fiuczynski, M., Becker, D., Chambers, C., and Eggers, S. 1995. Extensibility, safety and performance in the SPIN operating system. In Proceedings of the 15th ACM Symposium on Operating System Principles (SOSP'95). 267--283.]] Google Scholar
Digital Library
- Bhatia, S., Consel, C., Le Meur, A.-F., and Pu, C. 2004. Automatic specialization of protocol stacks in OS kernels. In Proceedings of the 29th Annual IEEE Conference on Local Computer Networks. Tampa, FL.]] Google Scholar
Digital Library
- Bhatia, S., Consel, C., and Pu, C. 2004. Remote customization of systems code for embedded devices. In Proceedings of the 4th ACM International Conference on Embedded Software (EMSOFT'04). ACM Press, New York, NY, 7--15.]] Google Scholar
Digital Library
- Bonwick, J. 1994. The slab allocator: An object-caching kernel memory allocator. In Proceedings of the USENIX.]] Google Scholar
Digital Library
- Consel, C., Lawall, J., and Le Meur, A.-F. 2004. A tour of Tempo: A program specializer for the C language. Sci. Comput. Program.]] Google Scholar
Digital Library
- Consel, C. and Noël, F. 1996. A general approach for run-time specialization and its application to C. In Conference Record of the 23rd ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages. St. Petersburg Beach, FL, 145--156.]] Google Scholar
Digital Library
- Denys, G. and Piessens, F. M. 2002. Survey of customizability in operating systems research. ACM Comput. Surv. 34, 4, 450--468.]] Google Scholar
Digital Library
- Engler, D., Kaashoek, M., and O'Toole, J. 1995. Exokernel: An operating system architecture for application-level resource management. In Proceedings of the 15th ACM Symposium on Operating System Principles (SOSP'95). 251--266.]] Google Scholar
Digital Library
- Evans Data Corporation. 2003. Embedded systems development survey.]]Google Scholar
- Ford, B., Back, G., Benson, G., Lepreau, J., Lin A., and Shivers, O. 1997. The Flux OS-Kit: A substrate for kernel and language research. In Proceedings of the 16th Symposium on Operating System Principles. St-Malo, France, 38--51.]] Google Scholar
Digital Library
- Hewlett-Packard. 1996. Netperf: A network performance benchmark.]]Google Scholar
- Hornof, L. and Noyé J. 2000. Accurate binding-time analysis for imperative languages: Flow, context, and return sensitivity. Theo. Comput. Sci. 248, 1--2, 3--27.]] Google Scholar
Digital Library
- Jones, N., Gomard, C., and Sestoft, P. 1993. Partial Evaluation and Automatic Program Generation. International Series in Computer Science. Prentice-Hall.]] Google Scholar
Digital Library
- Lawall, J. L., Muller, G., and Barreto, L. P. 2002. Capturing OS expertise in a modular type system: the Bossa experience. In Proceedings of the ACM SIGOPS European Workshop (EW'02). Saint-Emilion, France, 54--62.]] Google Scholar
Digital Library
- Le Meur, A.-F., Lawali, J., and Consel, C. 2004. Specialization scenarios: A pragmatic approach to declaring program specialization. High.-Oder Symb. Comput. 17, 1, 47--92.]] Google Scholar
Digital Library
- Lee, H. B., Diwan, A., and Moss, J. E. B. 2004. Design, implementation, and evaluation of a compilation server. Technical rep. CU-CS-978-04, University of California at Boulder.]]Google Scholar
- Linux Devices Magazine. 2003. Wind river's bruggeman defines Device Software Optimization (DSO).]]Google Scholar
- Linux Devices Magazine. 2003. New linksys wireless ap runs 3rd-party embedded linux. http://www.linuxdevices.com/news/NS3238024255.html.]]Google Scholar
- LXR. The LXR source-code cross-referencing system for Linux. URL: http://lxr.linux.no/.]]Google Scholar
- Mathis, M., Mahdavi, J., Floyd, S., and Romanow, A. 1996. RFC 2018: TCP selective acknowledgment options.]] Google Scholar
Digital Library
- McNamee, D., Walpole, J., Pu, C., Cowan, C., Krasic, C., Goel, A., Wagle, P., Consel, C., Muller, G., and Marlet, R. 2001. Specialization tools and techniques for systematic optimization of system software. ACM Trans. Comput. Syst. 19, 2, 217--251.]] Google Scholar
Digital Library
- Muller, G., Marlet, R., Volanschi, E., Consel, C., Pu, C., and Goel, A. 1998. Fast, optimized Sun RPC using automatic program specialization. In Proceedings of the 18th International Conference on Distributed Computing Systems. IEEE Computer Society Press. 240--249.]] Google Scholar
Digital Library
- Nagle, J. 1984. RFC 896: Congestion control in IP/TCP Internetworks.]] Google Scholar
Digital Library
- Necula, G. C., McPeak, S., Rahul, S. P., and Weimer, W. 2002. CIL: Intermediate language and tools for analysis and transformation of C programs. Lecture Notes in Computer Science, vol. 2304, 213--229.]] Google Scholar
Digital Library
- Owens, K. 2006. kbuild. URL: http://kbuild.sourceforge.net/.]]Google Scholar
- PicoFreeBSD. Pico freebsd. URL: http://people.freebsd.org/picobsd/.]]Google Scholar
- Pu, C., Autrey, T., Black, A., Consel, C., Cowan, C., Inouye, J., Kethana, L., Walpole, J., and Zhang, K. 1995. Optimistic incremental specialization: Streamlining a commercial operating system. In Proceedings of the 15th ACM Symposium on Operating Systems Principles. ACM Press, 314--324.]] Google Scholar
Digital Library
- Seltzer, M. I., Endo, Y., Small, C., and Smith, K. A. 1996. Dealing with disaster: Surviving misbehaved kernel extensions. In Proceedings of the 2nd Symposium on Operating Systems Design and Implementation. Seattle, WA, 213--227.]] Google Scholar
Digital Library
- TinyLinux. Tinylinux. URL: http://tiny.seul.org/en/.]]Google Scholar
- Veitch, A. C. and Hutchinson, N. C. 1996. Kca—dynamically extensible and configurable operating system kernel. In Proceedings of the 3rd International Conference on Configurable Distributed System (ICCDS).]] Google Scholar
Digital Library
- Voss, M. J. and Eigenmann, R. 2000. A framework for remote dynamic program optimization. In Proceedings of the ACM SIGPLAN Workshop on Dynamic and Adaptive Compilation and Optimization (DYNAMO'00). ACM Press, New York, NY, 32--40.]] Google Scholar
Digital Library
Index Terms
Remote specialization for efficient embedded operating systems
Recommendations
Feedback-directed specialization of code
Based on feedback information, a large number of optimizations can be performed by the compiler. This information actually indicates the changing behavior of the applications and can be used to specialize code accordingly. Code specialization is a way ...
Remote customization of systems code for embedded devices
EMSOFT '04: Proceedings of the 4th ACM international conference on Embedded softwareDedicated operating systems for embedded systems are fast being phased out due to their use of manual optimization, which provides high performance and small footprint, but also requires high maintenance and portability costs every time hardware ...
A Generative Middleware Specialization Process for Distributed Real-Time and Embedded Systems
ISORC '11: Proceedings of the 2011 14th IEEE International Symposium on Object/Component/Service-Oriented Real-Time Distributed ComputingGeneral-purpose middleware must often be specialized for resource-constrained, real-time and embedded systems to improve their response-times, reliability, memory footprint, and even power consumption. Software engineering techniques, such as aspect-...






Comments