Trabalho 1 – EPOS
Idle-waiting Thread Joining
– Este trabalho tinha como objetivo alterar o modo que era feito o “join” em uma Thread. Sendo que o mesmo inicialmente era feito da seguinte maneira:
[code lang=”c”] while(_state != FINISHING)
yield();
[/code]
O mesmo consiste basicamente, em verificar o estado da thread que se esta dando join e caso o estado nao seja FINISHING dar a vez a outro processo. Esta solucao, acarreta no consumo excessivo de recursos ja que o mesmo sempre retorna para a fila de _ready. E eh executado novamente quando o escalonador escolher esta thread. O trabalho pede que seja modificado de modo que o consumo de recursos nao seja excessivo.
Arquivos Modificados:
– thread.cc
– Thread.h
Solucao:
Foi criada uma variável adicional em threads.h, _waiting_for_me, que é um ponteiro para uma thread. Quando o método “join” é chamado, a thread que está executando é colocada no _waiting_for_me da thread chamada e é suspensa. Se a thread já finalizou ou alguém já chamou “join” nela, nada é feito. No método “exit”, caso _waiting_for_me esteja preenchida, é chamado o método “resume” na thread referenciada.
Pensamos em colocar uma lista de referências para várias threads poderem dar “join” na mesma thread, porém vimos na documentação do POSIX que isso era considerado um erro lógico, e achamos que acarretaria um consumo de recursos adicional desnecessário, pois não seria possível usar o _link já existente na thread, já que ela teria de estar tanto na lista de suspensos quanto na lista _waiting_for_me da outra thread.
Explicacao mais detalhada da implementacao escolhida e outras solucoes pensadas.
Just wanted to drop a quick note saying this was a useful read on a topic I have been circling, no fluff, and a stop at brightpathcorner added a few extra points that fit the same simple style which makes the whole site feel coherent rather than thrown together by many different writers with different goals.
Came across this and immediately thought of a friend who would enjoy it, and a stop at discoverfashionhub also reminded me of someone, content that triggers the urge to share is content that has earned my recommendation and this site has earned multiple from me already across different conversations during the week.
Felt energised after reading rather than drained, which is unusual for online content these days, and a look at sunrisehillcorner continued that good feeling, content that leaves you better than it found you is rare and worth bookmarking when you stumble across it for the first time today or any other day really.
Really like the way the post resists reaching for cliches that would have made it feel generic, and a quick visit to everattic kept that fresh feel going, original phrasing and unexpected metaphors are signs that the writer is actually thinking rather than just stitching together familiar phrases into the appearance of content.
Really appreciate the absence of stock photos that have nothing to do with the content, and a quick visit to discoverfashionhub maintained the same restraint, visual filler is a tell that the writing cannot stand on its own and the lack of it here suggests the team has confidence in their content quality alone.
Found the writing surprisingly fresh for what is by now a well covered topic, and a stop at moonfieldboutique kept that freshness going across the related pages, original perspective on familiar ground is hard to come by and this site has clearly earned its place in the conversation rather than just rehashing old ideas.
Solid value for anyone willing to read carefully, and a look at benningtonareaartscouncil extends that value across the rest of the site, this is the kind of place that rewards return visits rather than offering everything in a single splashy post and then leaving readers nothing to come back for later which is unfortunately common.
Decided this was the kind of site I would defend in a discussion about good blog content, and a stop at ivypiers reinforced that, very few sites earn active defence rather than passive consumption and this one has clearly crossed that threshold for me without needing any explicit pitch from the writers themselves either.
Picked this site to mention to a colleague who would benefit, and a look at edendunes added more material I will pass along, recommending sites to colleagues is a higher bar than recommending to friends because the professional context demands more careful curation and this site cleared the professional bar without me having to think.
Started forming counter examples to test the claims and the post handled most of them implicitly, and a look at neatmill continued that anticipatory style, writers who think two steps ahead of the critical reader save themselves from a lot of follow up work and this writer has clearly internalised that habit consistently.
Quietly impressive in a way that does not announce itself, and a stop at deathrayvision extended that quiet impressiveness, the kind of quality that emerges through sustained attention rather than first impressions is the kind I trust more deeply and this site has been earning that deeper trust across multiple sessions over time consistently.
Reading this prompted me to dig into a related topic later, and a stop at foxarbor provided some of the starting points for that follow up reading, content that triggers further exploration rather than satisfying curiosity completely is content with real generative energy and this site has plenty of that energy throughout it.
Felt like the post had been edited rather than just drafted and published, and a stop at knightstablefoodpantry suggested the same care across the site, the difference between edited and unedited content is enormous for the reader and this site has clearly invested in the editing pass that most blogs skip entirely which really does show up.
A piece that exhibited the kind of patience that good writing requires, and a look at jammykspeaks continued that patient quality, hurried writing is easy to spot and this site reads as having been written without time pressure which produces a different feel than the rushed content that dominates much of the modern blog space.
Looking through the archives suggests this site has been doing this for a while at this level, and a look at knackdome confirmed the long term consistency, sites that have maintained quality across years rather than just a recent stretch are sites with serious editorial discipline and this one has clearly been at it for a while.