I have never understood what system programming meant. The usual definition given is "...doing something close to the Os or extending Os features...".
Does using Windows API directly rather than some libraries to say do file i/o make it system programming? Was writing Android OS system programming? If I write something that would expose linux kernel through a console like app on Android am I doing system programming? If I am writing software to control a washing machine am I writing system programming?
I am a beginner in programming and this is confusing me to no end. Please explain contrasting it with "application programming".
In the software development world, very often people hear, learn and even use terms and phrases interchangeably, not knowing exactly what they mean. Like DevOps and Agile or multi-cloud and hybrid cloud. Although knowing these terms is important, what’s more important is what they really mean. An example that we particularly find galling is that of systems programming and application programming. So, what is systems programming? How is it different from application programming? And why is systems programming so hard? Let’s find out!
Before diving into what systems programming is, it’s important to understand what system software is. System software is any software that provides a platform for applications to be built; one that can be easily modified (or uninstalled) without affecting the functioning of other software. These comprise operating system (OS) programs and services including settings, device drivers, file libraries, and other configuration items that provide services to applications.
Systems programming is the process of programming system software. One of the main requirements for systems programming is a high degree of hardware awareness. Since the core job of systems programming is to ensure high speed and performance of apps, if the most central part of your application – the system software – is slow, then the whole application that runs on it will offer sluggish performance -a deal breaker in today’s fast-paced world.
System software is the layer flanked by the hardware on one side and the application software on the other; it is the layer that controls the hardware and provides services to applications. The primary differentiating factor between systems programming and application programming is that application programming involves developing software with which the user directly interacts, whereas systems programming aims to develop software which make hardware services available to the applications.
Application programming seldom involves writing code that directly interacts with the OS; instead, it relies on features that have been built into the programming language runtimes and system libraries by systems programming. Therefore, systems programming includes developing OSes, drivers, compilers, runtime services, system libraries, file systems, database managers, networking, utilities to configure and perform maintenance, and command shells that end users use to run applications.
Today’s OSes do not allow application software to manage system resources directly; instead, they provide interfaces (APIs) for managing resources. System programs, on the other hand, can access system resources directly. They can also be written to extend the functionality of the OS and provide functions that applications can use.
Systems programming is a crucial aspect of software development, requiring hardware planning and capacity planning, software system upgrades, installation scripts, integration testing and system-wide performance tuning. It is also an incredibly challenging task:
Unlike in application programming where advanced algorithms can be used to write beautiful code, system programming requires programmers to manage everything themselves: from memory and devices, OSes and life cycles, communications, and integration – the absence of abstraction layer in systems programming makes coding extremely difficult.
Since systems programming generally involves programming at a lower level of abstraction, it requires programmers to have deep knowledge of hardware and platform-specific APIs in order to interface more directly with them.
Because limited programming facilities are available, debugging is hard; programmers need to be skilled at debugging problems with system software and need to be adept with specialized debugging tools to determine where components have failed, to analyze the cause, and to apply a patch if available.
Programmers are also required to install and manage the middleware between the OS and end-user application such as database management systems and web servers.
Because programs need to operate in resource-constrained environments, systems programming requires adopting a low-level programming language.
Since systems programming acts as the building block of high performing mobile or web applications, programmers have to continuously drive efforts to improve the speed and performance of the system software, which with limited programming facilities and limited resources – is tough.
In contrast to application programming where myriad resources are available to provide help in coding, the references and resources available for systems programming are minuscule.
The runtime library is usually not available; and in cases where it is, it is not very powerful and does not provide efficient error checking.
In a modern world where mobile and web apps are taking the world by storm, systems programming plays a crucial role in ensuring high speed and appropriate performance. By installing, customizing, and maintaining the OS and related hardware, databases, libraries, and configuration files, systems programming makes efficient use of available resources to improve app performance and allows small efficiency improvements to directly transform into app success. It’s like we said, it’s a hard job -but someone’s got to do it!