Abstract
This article discusses the differences between processes and threads in the Linux operating system. Both are represented by the same data structures and similarly scheduled, and both are called tasks. It tries to answer whether the names Heavy-weight Process and Light Weight Process (LWP) are appropriate in Linux. It focuses on the time required to create a process or thread. First, the mechanism of creating a new process and thread is explained, and then several measurements are performed under different conditions. A fragments of source code which is used in the measurement are attached. Finally, the advantages and disadvantages of processes and threads are summarized with a recommendation when it is better to use processes or threads in the Linux operating system.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
References
Stallings, W.: Operating systems: internals and design principles. In: 8th ed., Pearson Education Limited (2014)
Sarath, P.: Difference Between Process and Thread in Linux. Slashroot.in. https://www.slashroot.in/difference-between-process-and-thread-linux Accessed 07 June 2020
Silberschatz, A., Galvin, P.B., Gagne, G.: Operating system concepts, 9th edn. Wiley, Hoboken, NJ (2013)
Bendersky, E.: Launching Linux Threads and Processes with clone. Eli Bendersky’s website. https://eli.thegreenplace.net/2018/launching-linux-threads-and-processes-with-clone/ Accessed 16 April 2020
Linux manual page. https://man7.org/linux/man-pages/man3/pthread_create.3.html Accessed 30 June 2020
Farrell, J., Buttlar, D., Nichols, B.: PThreads Programming. O’Reilly online learning. https://www.oreilly.com/library/view/pthreads-programming/9781449364724/ch01.html Accessed 25 June 2020
Intel Product Specifications, Intel® Core™ i7–1065G7 Processor https://ark.intel.com/content/www/us/en/ark/products/196597/intel-core-i7-1065g7-processor-8m-cache-up-to-3-90-ghz.html Accessed 30 June 2020
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2020 The Editor(s) (if applicable) and The Author(s), under exclusive license to Springer Nature Switzerland AG
About this paper
Cite this paper
Sysel, M. (2020). A Comparison of Processes and Threads Creation. In: Silhavy, R., Silhavy, P., Prokopova, Z. (eds) Software Engineering Perspectives in Intelligent Systems. CoMeSySo 2020. Advances in Intelligent Systems and Computing, vol 1294. Springer, Cham. https://doi.org/10.1007/978-3-030-63322-6_85
Download citation
DOI: https://doi.org/10.1007/978-3-030-63322-6_85
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-030-63321-9
Online ISBN: 978-3-030-63322-6
eBook Packages: Intelligent Technologies and RoboticsIntelligent Technologies and Robotics (R0)