# Overview of processes in MOP3 ## What is a process? A process is a structure defined to represent an internal state of a user application's environment. This includes the necessary stacks, code, data and other resources. A process (usually) has it's own address, but in certain circumstances may share it with another process. ## Only processes vs. processes-threads model ### Overview MOP3 doesn't have a process-thread separation. Ususally in operating systems you'd have a "process", which consists of multiple worker threads. For eg. a single-threaded application is a process, which consists of one worker. In MOP3 we do things a little differently. We only have processes, but some processes may work within the same pool of (generally speaking) "resources", such as a shared address space, shared memory allocations, mutexes and so on. An application then consists of not threads, but processes, which are loosely tied together via shared data. #### Processes-threads model diagram ![Processes-threads model](assets/images/processes-threads.png) #### Only processes model diagram ![Only processes model](assets/images/only-processes.png) ## Scheduling MOP3 uses a round-robin based scheduler. For now priorities are left unimplemented, ie. every processes has equal priority, but this may change in the future. A good explaination of round-robin scheduling can be found on the OSDev wiki: [the article](https://wiki.osdev.org/Scheduling_Algorithms#Round_Robin)