Trabalho 3 – EPOS
System Object Destruction
No exercício três deviamos implementar o controle de destrução de objetos, o qual não deve corromper o sistema e também deve estar de acordo com a semântica da linguagem de programação.
A implementação adotada funciona da seguinte maneira: na class Thread foi adicionado um campo _container, nele é guardada a fila em que a Thread se encontra no momento. Os métodos desta classe foram alterados para que a consistência do campo _container seja mantida. No método join, por exemplo, o campo _container é atualizado com o endereço da fila _waiting_for_me do objeto em que se da join.
Quando uma thread entra para o estado RUNNING o seu campo container não é atualizado, já que caso o mesmo seja deletado (ou auto-deletado), ele tentará se remover de uma fila em que não está, não causando mais problemas.
Quando uma thread que possui elementos na sua fila _waiting_for_me é deletada, ela não acorda aquelas que a estão esperando, entrando em uma situação de deadlock. Nosso sistema, por conseguir detectar essa situação facilmente, gera um aviso. Porém, caso a Thread que tente se dar join já tiver sido destruída e removida da memória, a thread em execução trava, como nosso sistema não consegue detectar esse erro ele não é informado.
Quando um objeto que extende a classe Synchronizer é deletado, seu destrutor chama wakeup_all, fazendo com que todos as threads que estiverem travadas nele continuem a execução.
Arquivos Modificados:
Thread.h
Thread.cc
Sycronizer.h
1win az promo kod https://1win5761.help
review zaviro trustline – Clean structure and intuitive navigation make the site pleasant to explore.
1win az canlı mərclər http://1win5761.help
Resources – Organized content, fast pages, and content is straightforward for research.
velixo access – Minimal clutter, structured content, and pages feel responsive and clean
News – Updates and announcements are presented cleanly and load without delay.
About Us – Smooth navigation and tidy layout make exploring content easy and fast.
financial portal – Everything runs smoothly and the layout feels reliable.
next move portal – Website provides simple tools for mapping out upcoming goals effectively.
Updates – Latest information is organized clearly and loads quickly.
Access trust site – The layout helps beginners grasp information without confusion.
Blog – Articles are presented neatly, allowing smooth reading and learning.
Bond information page – Clearly structured layout, effective navigation, and relevant details.
Support – Structured guides and fast-loading pages provide a smooth browsing experience.
financial hub – Smooth experience, and content is presented clearly.
Digital portal – Streamlined layout, quick page loads, and information is user-friendly.
explore here – Well-laid-out pages, fast browsing, very easy to understand content
News – Latest updates are structured clearly and browsing the site is quick and easy.
bavlo network – Straightforward interface, clean pages, and no noticeable issues on visit
Explore project – Simple layout, clear content, and navigation is effortless.
trusted finance portal – Design looks professional, browsing is smooth, and information is easy to access.
legacyline.bond – Professional presentation, content communicates tradition and purpose effectively.
ideas link – Wording feels empowering and encourages actionable thinking.
stonecrestpoint.bond – Sleek design, navigation is smooth and content communicates professionalism well.
online bond information – Straightforward layout, responsive pages, and trustworthy appearance.
growthstream.bond – Engaging interface, concepts are clear and navigation is effortless throughout.
bondedtrust.bond – Smooth navigation, content presents a secure and approachable experience.
Bonded Framework Access – Professional structure, framework concept is easy to grasp at a glance.
clarity link – Structure is simple, keeping focus on the key ideas.
Nexa Center – Sleek design with fast loading and messaging that is easy to understand.
groundcore.bond – Smooth layout, content is concise and communicates stability naturally.
Bonded Legacy Focus – Professional feel, navigation is smooth and legacy concept is clear.
inviting website link – The design makes exploring feel natural and smooth.
focusandgrowinsights.bond – Easy navigation, content motivates readers to focus and grow gradually.
online shop click – Easy to explore, everything is organized and visually appealing.
northquillemporium.shop – Organized layout, finding products is easy and store navigation flows well.
daily deals online – Pleasant layout, makes checking offers fast and simple.
clarity forward – Text encourages clarity-driven progress with a sense of purpose.
QuickXanix – Layout organized, pages responsive, and shopping is straightforward.
investment lynx site – Fast browsing, all bond choices are simple to access.
micro progress site – Motivates you to make small changes that add up.
discover & explore page – Always comes with something novel to explore.
smart shopper portal – Engaging visuals, platform feels advanced and easy to navigate.
clicktolearnandgrow.click – Found this today, content seems helpful and worth checking again.
Advancement-focused website – The site runs smoothly and navigation feels natural.
partnershipvalueguide – Clear recommendations that supported smarter long-term relationship planning.
team collaboration guide – Useful tips that enhanced enterprise teamwork and supported sustainable growth.
business partner hub – Useful guidance that made networking and joint planning more productive.
convenientpurchasezone – Very user-friendly site, checkout process was fast and easy.
entrepreneurguideonline – Insightful guidance, helped me uncover potential business directions today.