Episode #125 of the Stack Overflow podcast is here. We talk Tilde Club and mechanical keyboards. Listen now

Questions tagged [operating-systems]

An operating system (OS) is a basic software whose rule is to intermediate software requisitions for resources and the hardware available, manage input/output, memory allocation/deallocation, file systems, among other basic tasks a device should do.

Filter by
Sorted by
Tagged with
3
votes
1answer
106 views

How exactly are drivers developed, distributed, & utilized?

If operating systems use 'drivers' to community with external devices, does that then mean that OS's (like windows, linux, & osx) have to come prepackaged with drivers for every single external ...
0
votes
1answer
73 views

How swap space works in this example?

Say I have total RAM memory of 1GB , HD of 10 GB with 250 MB swap space Say I have two files(f1 and f2) each of 500 MB opened on my my laptop. Now both files are in memory and have consumed 1 GB of ...
1
vote
1answer
45 views

What is the difference between a Page Table Entry and a Memory Descriptor List?

The definition of a MDL from Microsoft is: The operating system uses a memory descriptor list (MDL) to describe the physical page layout for a virtual memory buffer. The definition of a Page ...
-1
votes
2answers
148 views

Relationship between the C standard libraries and Java standard libraries

Which is the relationship between the standard libraries of C language and the standard libraries of other software platforms, e.g. Java, .NET, Python? Do the Java (.NET and Python) standard libraries ...
0
votes
1answer
495 views

System Call Interface and operating system API

What is the difference between operating system API and system-call interface ? I have read at many places that both act as interface between program and the kernel. Then what is the actual ...
-2
votes
1answer
47 views

Interested in contributing to ChromiumOS: What steps should I take to prepare? [closed]

I'm a hobbyist developer of 16 years and would like to start contributing to the ChromiumOS project. I have extensive experience in developing for mobile and embedded devices, so my skill set is ...
0
votes
1answer
86 views

Making execution of Python script fool-proof beyond adding shebang

Assume that a Python package (available via PyPI) is too difficult for novice users to utilize. Specifically, typing python2 path_to_package/start_GUI.py in the command line, which opens a TKinter GUI,...
0
votes
1answer
165 views

Is memory allocation hardware handled or OS?

I am currently working on a bare metal project with an arm processor using GCC arm compiler. If I call malloc, is the allocated memory tracked in the MMU? For some reason I had assumed an OS typically ...
3
votes
1answer
231 views

Why non-mainstream OSes don't adopt Linux hardware drivers?

Non-mainstream OSes (Genode, BSD, Haiku, etc.) tend to have problems with drivers availability/support. Why don't they reuse Linux drivers? I would imagine they could provide some ABI compatibility ...
0
votes
2answers
106 views

How did old OSs create or expand a segment in memory without issues?

On an 8086 CPU before the flat memory model had been adopted, when the OS wanted to create a new segment for a process, how did it know what virtual memory ranges were already covered by existing ...
4
votes
2answers
211 views

Do operating systems implement techniques to ask programs to give up non-vital memory in times of shortages?

When a system is running low on available memory can it ask programs in general to give up any non-vital memory without shutting down. Like a process signal which causes the processes to yield any ...
-3
votes
0answers
71 views

How does an Operating System gets allocated its first memory space [duplicate]

Going through osDev.org, I managed to write a small kernel that outputs a memory address, similar to this: #include <stdio.h> int main() { size_t a = 2; size_t *p = &a; printf("...
1
vote
0answers
203 views

Daemon vs worker and when to use what?

(Note that, below, I am frequently using term "daemon or worker" just to indicate that I dont know which word to use as I dont know the exact difference between them in the context explained below.) ...
2
votes
1answer
195 views

What is the difference between writing in assembly vs converting high level language into assembly using compiler?

So i heard that in modern operating systems and device drivers, some parts of them are still written in assembly for better memory optimisation and speed but do developers actually write it in ...
2
votes
2answers
210 views

producer-Consumer with Signaling Architecture in a Real-Time Operating System (RTOS)

I'm developing a real-time system by making use of an mbed-OS (RTOS for ARM architecture). I'm not a software engineer and I want to know whether the following solution is practical or not, and how to ...
3
votes
1answer
119 views

Regarding system interrupts and timers. Why programs sometimes still run when OS asks you to terminate or keep it going?

I'm reading (just started) "Operating systems concepts" by Silberschatz, Galvin and Gagner and something called my attention when reading a basic primer on "timer" (1.5.2 on the book). It says: As ...
2
votes
2answers
206 views

Designing a Way for Process to Communicate with Kernel

I've got a project that is sort of a virtual operating system. In this project, the Kernel class is responsible for creating Process classes. The process class consists of Thread classes and the ...
3
votes
1answer
229 views

What are the risks of relying on the O.S layer (commands and shells) as programming platform?

Context I'm about to start a new project for my company1 which architecture will comprise several elements. There are 2 mobile applications (Android and iOS), a web API (Java) and an ETL (still ...
0
votes
1answer
628 views

Asynchronous communication from synchronous communication

Studying Inter Processes Communication in Operating System, I've discovered that asynchronous communication can be built on top of synchronous communication. But, it's not clear to me how can it be ...
-2
votes
1answer
305 views

Is operating system Universal Turing Machine?

The definition of UTM(Universal Turing Machine) is a Turing machine that can simulate other Turing machines, so as far as I can guess operating system is a UTM, since it can run multiple programs on a ...
-2
votes
1answer
855 views

First Fit Algorithm Memory Allocation

I am currently reviewing memory partitions and I have a problem that is really confusing me. Suppose you have 5 memory partitions: 100K, 500K, 200K, 300K, and 600K. Also suppose you have 4 ...
6
votes
3answers
3k views

What does “address space” means when talking about IO devices?

The following quote is from this page: While some CPU manufacturers implement a single address space in their chips, others decided that peripheral devices are different from memory and, ...
4
votes
1answer
670 views

What is so different about RTOS compared to normal programming?

Classical programs run a loop with prioritized ISRs. How do RTOS do this differently of better?
0
votes
1answer
147 views

When working in a multi operating system team, what are some of the pitfalls to bear in mind?

I'm working in a team where there are several different OS present (windows, various linux distributions (Ubuntu, Mint) as well as Macintosh). Projects are passed around and we have already come ...
12
votes
2answers
603 views

Does a file system “see” the storage device as a (very large) byte array?

I want to know how does a file system write to and read from a storage device. I think this is how it works: A file system doesn't access the storage device directly, but rather the storage device ...
3
votes
2answers
424 views

Can file systems be designed and implemented in an OS-portable way?

Given the interfaces that major OSes (Windows, macOS/OS X/Mac OS X, Linux) provide to file systems, can file systems be designed and implemented in a way that is largely independent of OS? I'm not at ...
12
votes
8answers
13k views

Are C strings always null terminated, or does it depend on the platform?

Right now I am working with embedded systems and figuring out ways to implement strings on a microprocessor with no operating system. So far what I am doing is just using the idea of having NULL ...
4
votes
3answers
4k views

Why system calls are limited to C language as far as I see?

From my Operating System textbook, application and library interact with kernel by system calls. But as far as I can see, Windows, OS X and Linux, we can only use C Language to post system calls. ...
4
votes
2answers
251 views

Criteria for a language (Terra as a tricky example) to be usable for operating system development, and how to meet missing criteria

For example, a language that I was looking at recently- Terra. You can address the question in the context of any language, I'm just most comfortable with Lua so I'm starting from there. The Terra ...
3
votes
4answers
2k views

How does a program make a system call

I'm reading Tanenbaum's Modern Operating Systems and I really can't grasp the following concept: how does a program make a system call? I mean, i got the very basics down (correct me if I'm wrong): ...
2
votes
4answers
299 views

Is it possible for a computer system to have constant/zero CPU load?

For example, a simple program in a simulated environment that waits for user input seems to be doing no work, so I guess it uses CPU only for the time. I'd like to know if computer systems (that don'...
4
votes
2answers
1k views

GO - Goroutine and Concurrency

Background: pthreads follow pre-emptive scheduling, whereas C++ fibers follow cooperative scheduling. With Pthreads: the current execution path may be interrupted or preempted at any time This ...
0
votes
1answer
153 views

How are low-level I/O models mapped into stream I/O abstraction?

High-level languages often expose stream-based I/O abstraction to the programmer, where blocking or non-blocking streams offer select/read/write operations. (AFAIK, message-based I/O seems is usually ...
0
votes
4answers
785 views

Why are computer systems still insecure? [closed]

After 50 years of software engineering, why are computer systems still insecure? I don't get it. Two questions: (i) What's so hard about just denying or restricting networked access to bad actors who ...
0
votes
4answers
676 views

Is there a way to see how many operations a function, block of code or a statement costs?

Let's say I have a phone that can process 1 million operations per second and a micro controller that can perform 1000. Is there a way to tell how many operations a performed by a function or block ...
90
votes
12answers
18k views

What is meant by the phrase “Software can replace hardware”?

Studying beginners course on hardware/software interface and operating systems, often come up the topic of if it would be better to replace some hardware parts with software and vice-versa. I can't ...
1
vote
3answers
783 views

Why is call stack not implemented as a dynamic array in modern OS? [duplicate]

When a modern OS loads a process, it pre-allocates a certain amount of space for stack. This means that the programmer has to be careful to avoid stack overflow by limiting call depth and/or by ...
2
votes
1answer
1k views

Are some operation system (kernels) more efficient with hardware than others?

When comparing the Windows, macOS, and Linux kernel to each other, do some make better use of hardware in terms of cache efficiently, page lookups, or power consumption? I noticed this after ...
4
votes
1answer
5k views

Implement a monitor in terms of semaphores

From Operating System Concepts by Abraham Silberschatz, Peter B. Galvin, Greg Gagne 5.8.3 Implementing a Monitor Using Semaphores We now consider a possible implementation of the monitor ...
0
votes
1answer
65 views

Windows Console App vs Service, Part II

Windows Console App vs Service I would like to extend the question at the above post, as the previous answers did a great job of helping me understand the difference between a service and not a ...
-2
votes
1answer
116 views

Loading My Custom OS from USB flash drive

Suppose I want to create a portable OS, that needs a USB flash drive only to work. and i wrote my boatloader in the first sector to be loaded by the BIOS, from here on, what can I do to load my OS ...
-1
votes
1answer
120 views

How to understand an OS's source? [closed]

I usually understand code by fiddling around, or by inserting printfs here and there, but this time around, that isn't possible, since the end product is an OS, so any suggestions on how to tackle ...
-3
votes
1answer
108 views

Operating System Licensing: Open Source License with reciprocity but built-in exceptions?

In a recent internship, I worked on a project involving traffic detection using radar. The company developed their own unique hardware and ran Windows Compact Embedded on an ARM processor. I thought ...
3
votes
2answers
48 views

Executable verification in user mode

I am posting this here instead of on Stack Overflow because this is more conceptual. I am primarily thinking of this a Linux context, but this can be extended to other operating systems. When I didn'...
5
votes
1answer
456 views

Concept of push notifications - why is it only on mobile platforms? OSX/Windows/Linux?

At an operating system level, mobile operating systems support the notion of push notifications or a socket level 'persistent' communication with an app, whenever it is online. Why have the major ...
0
votes
1answer
109 views

Can a zombie process get scheduled?

Since zombie processes are processes having all resources freed but still existing in process table because their parent might ask for their return status, is it a separate state in Linux like ready, ...
-2
votes
5answers
3k views

Is learning about operating systems useful for a software developer? [closed]

Most of the underlying workings of the operating system is hidden from the programmer. I believe that is also one of the purposes of an operating system. Then what are the reasons a software developer ...
0
votes
1answer
300 views

Two C program sharing same addresses

I was trying to understand structure padding , so i wrote a simple program as written below and i executed it . just to make clear i made two copy of this program program1.c and program2.c and ...
-2
votes
1answer
3k views

Can an OS be created with Python?

I have been pondering over the idea of a Python-based Operating System on top of the Linux kernel, much like how Android uses Java. What if most of the system components were built using Python, this ...
1
vote
4answers
4k views

What is the relationship between a program and processes in the Operating System?

A program, I am referring to any program written in any programming language. It could be a Java program which has only one method to do the multiplication, and a main method executes that ...