SlideShare uma empresa Scribd logo
1 de 13
Operating Systems Team: Jonathan Arturo Alvarado Mata   1441616 Obed David  Guevara Ibarra        1447478 Carlos Eduardo Triana Sarmiento    1412573 Blog: http://os-ocj.blogspot.com/
First Point  ,[object Object],[object Object],[object Object],[object Object]
what we did?... ,[object Object],[object Object]
what we did?... ,[object Object],[object Object]
CODE ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
CONSUMER(){ while(1){ try to aquire the lock if(l1->TRYAQUIRE()){ if the array is empty, wait                            if it isn’t, continue...                    WHILE(ARRAY == FULL){                               C->WAIT(L1);                      consume the next unit of data                         }decreae the number of items in the array               CONSUME(int dummy);                       C-> SIGNALl();   Enables the waiting thread                        L1->RELEASE();           }end of if       }end of while }//end of function consumer
void main(){ L1 = new lock(“L1”); C = new condition(“C”); Thread *t = new Thread(“producer”);   t->Fork(producer, 1); Thread * t= new Thread(“consumer”); t->Fork(consumer, 1); }end main
Second Point ,[object Object],[object Object],[object Object]
The solution... ,[object Object],[object Object],[object Object]
CODE ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
[object Object],[object Object]
[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Bibliography ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]

Mais conteúdo relacionado

Mais procurados

Lec11 semaphores
Lec11 semaphoresLec11 semaphores
Lec11 semaphores
anandammca
 

Mais procurados (20)

Python Flow Control
Python Flow ControlPython Flow Control
Python Flow Control
 
Learning php 7
Learning php 7Learning php 7
Learning php 7
 
Control flow statements in java
Control flow statements in javaControl flow statements in java
Control flow statements in java
 
Control structures repetition
Control structures   repetitionControl structures   repetition
Control structures repetition
 
Python loops
Python loopsPython loops
Python loops
 
Iteration
IterationIteration
Iteration
 
Lec11 semaphores
Lec11 semaphoresLec11 semaphores
Lec11 semaphores
 
Exception handlingpdf
Exception handlingpdfException handlingpdf
Exception handlingpdf
 
Appsec obfuscator reloaded
Appsec obfuscator reloadedAppsec obfuscator reloaded
Appsec obfuscator reloaded
 
Control Structures in Python
Control Structures in PythonControl Structures in Python
Control Structures in Python
 
M C6java6
M C6java6M C6java6
M C6java6
 
Chap05
Chap05Chap05
Chap05
 
Introduction to Erlang Part 2
Introduction to Erlang Part 2Introduction to Erlang Part 2
Introduction to Erlang Part 2
 
Threads
ThreadsThreads
Threads
 
Control statements
Control statementsControl statements
Control statements
 
Sstic 2015 detailed_version_triton_concolic_execution_frame_work_f_saudel_jsa...
Sstic 2015 detailed_version_triton_concolic_execution_frame_work_f_saudel_jsa...Sstic 2015 detailed_version_triton_concolic_execution_frame_work_f_saudel_jsa...
Sstic 2015 detailed_version_triton_concolic_execution_frame_work_f_saudel_jsa...
 
How Functions Work
How Functions WorkHow Functions Work
How Functions Work
 
Introduction to Erlang Part 1
Introduction to Erlang Part 1Introduction to Erlang Part 1
Introduction to Erlang Part 1
 
Control structures in java
Control structures in javaControl structures in java
Control structures in java
 
Java 14 features
Java 14 featuresJava 14 features
Java 14 features
 

Destaque

Rosa montero
Rosa monteroRosa montero
Rosa montero
Malena
 
Apa sexta edicion-2009-
Apa sexta edicion-2009-Apa sexta edicion-2009-
Apa sexta edicion-2009-
James Melenge
 
Privaatrecht
PrivaatrechtPrivaatrecht
Privaatrecht
Ytomyth
 
Apa sexta edicion-2009-
Apa sexta edicion-2009-Apa sexta edicion-2009-
Apa sexta edicion-2009-
James Melenge
 
Que importa (1)
Que importa (1)Que importa (1)
Que importa (1)
Bernardita
 
Presentación miguel de cervantes
Presentación miguel de cervantesPresentación miguel de cervantes
Presentación miguel de cervantes
Elisadelengua
 
Open day presentation 2
Open day presentation 2Open day presentation 2
Open day presentation 2
sallyross
 
Revisión web ajustes
Revisión web ajustesRevisión web ajustes
Revisión web ajustes
solbarreira
 

Destaque (20)

Autoestima
AutoestimaAutoestima
Autoestima
 
Rosa montero
Rosa monteroRosa montero
Rosa montero
 
Verdadabsoluta
VerdadabsolutaVerdadabsoluta
Verdadabsoluta
 
Pruebas de escritorio con objetos
Pruebas de escritorio con objetosPruebas de escritorio con objetos
Pruebas de escritorio con objetos
 
Apa sexta edicion-2009-
Apa sexta edicion-2009-Apa sexta edicion-2009-
Apa sexta edicion-2009-
 
Google
GoogleGoogle
Google
 
Fruit
FruitFruit
Fruit
 
Privaatrecht
PrivaatrechtPrivaatrecht
Privaatrecht
 
Apa sexta edicion-2009-
Apa sexta edicion-2009-Apa sexta edicion-2009-
Apa sexta edicion-2009-
 
Que importa (1)
Que importa (1)Que importa (1)
Que importa (1)
 
Werving en Selectie ICT | IT-Profile
Werving en Selectie ICT | IT-ProfileWerving en Selectie ICT | IT-Profile
Werving en Selectie ICT | IT-Profile
 
Presentación miguel de cervantes
Presentación miguel de cervantesPresentación miguel de cervantes
Presentación miguel de cervantes
 
Camilo
CamiloCamilo
Camilo
 
Televisión educativa fernando galarza
Televisión educativa fernando galarzaTelevisión educativa fernando galarza
Televisión educativa fernando galarza
 
Presentacion sobre gerena
Presentacion sobre gerenaPresentacion sobre gerena
Presentacion sobre gerena
 
Open day presentation 2
Open day presentation 2Open day presentation 2
Open day presentation 2
 
Amor
AmorAmor
Amor
 
Porter Novelli Personal branding met social media
Porter Novelli Personal branding met social mediaPorter Novelli Personal branding met social media
Porter Novelli Personal branding met social media
 
Revisión web ajustes
Revisión web ajustesRevisión web ajustes
Revisión web ajustes
 
Syria Rosary
Syria RosarySyria Rosary
Syria Rosary
 

Semelhante a Operating systems

Exception Handling1
Exception Handling1Exception Handling1
Exception Handling1
guest739536
 
Java 5 concurrency
Java 5 concurrencyJava 5 concurrency
Java 5 concurrency
priyank09
 
Exception handling and templates
Exception handling and templatesException handling and templates
Exception handling and templates
farhan amjad
 
----------Evaluator-java---------------- package evaluator- import j.docx
----------Evaluator-java---------------- package evaluator-   import j.docx----------Evaluator-java---------------- package evaluator-   import j.docx
----------Evaluator-java---------------- package evaluator- import j.docx
janettjz6sfehrle
 

Semelhante a Operating systems (20)

Exception Handling1
Exception Handling1Exception Handling1
Exception Handling1
 
Full solution to bounded buffer
Full solution to bounded bufferFull solution to bounded buffer
Full solution to bounded buffer
 
Handling
HandlingHandling
Handling
 
Let's Talk Locks!
Let's Talk Locks!Let's Talk Locks!
Let's Talk Locks!
 
Java 5 concurrency
Java 5 concurrencyJava 5 concurrency
Java 5 concurrency
 
04 threads
04 threads04 threads
04 threads
 
Exception handling and templates
Exception handling and templatesException handling and templates
Exception handling and templates
 
----------Evaluator-java---------------- package evaluator- import j.docx
----------Evaluator-java---------------- package evaluator-   import j.docx----------Evaluator-java---------------- package evaluator-   import j.docx
----------Evaluator-java---------------- package evaluator- import j.docx
 
Java Multithreading.pptx
Java Multithreading.pptxJava Multithreading.pptx
Java Multithreading.pptx
 
Wait for your fortune without Blocking!
Wait for your fortune without Blocking!Wait for your fortune without Blocking!
Wait for your fortune without Blocking!
 
Lec7!JavaThreads.ppt
Lec7!JavaThreads.pptLec7!JavaThreads.ppt
Lec7!JavaThreads.ppt
 
Lec7!JavaThreads.ppt java multithreading
Lec7!JavaThreads.ppt java multithreadingLec7!JavaThreads.ppt java multithreading
Lec7!JavaThreads.ppt java multithreading
 
Lec7!JavaThreads.ppt
Lec7!JavaThreads.pptLec7!JavaThreads.ppt
Lec7!JavaThreads.ppt
 
Theoretical presentation1nachos
Theoretical presentation1nachosTheoretical presentation1nachos
Theoretical presentation1nachos
 
Templates
TemplatesTemplates
Templates
 
Exception handling in java
Exception handling  in javaException handling  in java
Exception handling in java
 
Time and Space Complexity Analysis.pptx
Time and Space Complexity Analysis.pptxTime and Space Complexity Analysis.pptx
Time and Space Complexity Analysis.pptx
 
Lazy Java
Lazy JavaLazy Java
Lazy Java
 
Mario Fusco - Lazy Java - Codemotion Milan 2018
Mario Fusco - Lazy Java - Codemotion Milan 2018Mario Fusco - Lazy Java - Codemotion Milan 2018
Mario Fusco - Lazy Java - Codemotion Milan 2018
 
Lazy java
Lazy javaLazy java
Lazy java
 

Mais de Jonathan Alvarado (13)

Firma digital
Firma digitalFirma digital
Firma digital
 
Android + Bluetooth + Arduino
Android + Bluetooth + ArduinoAndroid + Bluetooth + Arduino
Android + Bluetooth + Arduino
 
Presentacion moviles
Presentacion movilesPresentacion moviles
Presentacion moviles
 
Practical presentation
Practical presentationPractical presentation
Practical presentation
 
Practical presentation
Practical presentationPractical presentation
Practical presentation
 
Practical presentation
Practical presentationPractical presentation
Practical presentation
 
Practical presentation
Practical presentationPractical presentation
Practical presentation
 
Practical presentation
Practical presentationPractical presentation
Practical presentation
 
Operating systems
Operating systemsOperating systems
Operating systems
 
Avance de Proyecto
Avance de ProyectoAvance de Proyecto
Avance de Proyecto
 
Avance de Proyecto
Avance de ProyectoAvance de Proyecto
Avance de Proyecto
 
Avance de Proyecto
Avance de ProyectoAvance de Proyecto
Avance de Proyecto
 
Avance de Proyecto
Avance de ProyectoAvance de Proyecto
Avance de Proyecto
 

Último

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Último (20)

A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 

Operating systems

  • 1. Operating Systems Team: Jonathan Arturo Alvarado Mata   1441616 Obed David  Guevara Ibarra        1447478 Carlos Eduardo Triana Sarmiento    1412573 Blog: http://os-ocj.blogspot.com/
  • 2.
  • 3.
  • 4.
  • 5.
  • 6. CONSUMER(){ while(1){ try to aquire the lock if(l1->TRYAQUIRE()){ if the array is empty, wait                           if it isn’t, continue...                    WHILE(ARRAY == FULL){                               C->WAIT(L1);                      consume the next unit of data                         }decreae the number of items in the array               CONSUME(int dummy);                       C-> SIGNALl(); Enables the waiting thread                        L1->RELEASE();           }end of if       }end of while }//end of function consumer
  • 7. void main(){ L1 = new lock(“L1”); C = new condition(“C”); Thread *t = new Thread(“producer”);   t->Fork(producer, 1); Thread * t= new Thread(“consumer”); t->Fork(consumer, 1); }end main
  • 8.
  • 9.
  • 10.
  • 11.
  • 12.
  • 13.