Also added comment section to the head of the circular buffer header file.
On Tue, Nov 17, 2015 at 4:53 PM, Davide Libenzi <[email protected]> wrote: > Commits squashed. > > > On Tue, Nov 17, 2015 at 3:20 PM, Barret Rhoden <[email protected]> > wrote: > >> Hi - >> >> On 2015-11-13 at 19:54 "'Davide Libenzi' via Akaros" >> <[email protected]> wrote: >> > Coming to error(), should I always waserror() in my code, even if I >> > have nothing to be undone? >> > Because, that kinda defeats the exception-look-alike error model. >> >> I think no. You only need a waserror if you need to cleanup if a >> function you call throws. If you have nothing to cleanup or if you >> know that you don't call something that might throw, then you don't >> need a waserror block. >> >> > circular_buffer_write already has the comments in its body, which >> > describes the operation. >> > Adding some more to the skip API. >> >> What I was getting at is that if someone looks at the code for >> circular_buffer.h or circular_buffer.c, they won't know what it does >> without looking into the code. This makes it more difficult to use. >> >> Compare that to kern/include/trace.h, which has a bit of an explanation >> and tells people how to use it. >> >> > I added two commits (WIP:PROFILER and WIP:KPROF) at the end of the >> > stream, which did not squash in the proper place yet. >> > Take a look. I really do not like the idea of having resources left >> > allocated when the functionalities are not used. >> >> It seems okay. I understand the desire to free unused resources, but >> the tradeoff is complexity and possible bugs. I don't know that a >> small amount of RAM is worth that. But we'll see how this works out. =) >> >> Anyway, once you squash those last two commits or do any other stuff, >> let me know and I'll merge your latest. >> >> Barret >> >> >> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Akaros" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected]. >> To post to this group, send email to [email protected]. >> For more options, visit https://groups.google.com/d/optout. >> > > -- You received this message because you are subscribed to the Google Groups "Akaros" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. For more options, visit https://groups.google.com/d/optout.
