Zbr's days.
November
Sun Mon Tue Wed Thu Fri Sat
     
8
   
2006
Months
Nov

About TODO Blog RSS Old blog Projects Gallery Notes

Wed, 08 Nov 2006

Kevent updates.


Some kevent fixes for misteriously lived in the tree errors.
poll/select notifications were completely broken, which I was pointed to by Davide Libenzi.
I do not know, how it could happen, but probably during tree changes from old one, which contained network and FS AIO, to current I dropped some file updates.
I've fixed it and also changed a bit logic behind poll/select notifications - they are called with newly introduced KEVENT_REQ_LAST_CHECK flag, which if set allows to perform the last check on kevent (call appropriate callback) when kevent is marked as ready and has been removed from ready queue. If it will be confirmed that kevent is ready (k->callbacks.callback(k) returns true) then kevent will be copied to userspace, otherwise it will be requeued back to storage. Second (checking) call is performed with this bit _cleared_ so callback can detect when it was called from kevent_storage_ready() - bit is set, or kevent_dequeue_ready() - bit is cleared. If kevent will be requeued, bit will be set again.

Benchmarks compared to epoll() shows sightly better results, but it can be fluctuation and can be unrelated to that change.

I also created pipe/fifo notifications, but have not aggressively tested it yet, will do it tomorrow as long as release new kevent patchset with poll/select notifications fix.

/devel/kevent :: Link / Comments (0)


Threading libraries and it's speed.


Looking into threading benhcmark hosted on http://shootout.alioth.debian.org I've found that synthetic threading model (i.e. which has threading capabilities built into language interpreter like Erlang) works generally faster than posix threading model.
I think I will try to implement that benchmark in C and run different applications hosted there to compare if NPTL is really that slow.

If it is really so, I will think some more about possibility to create such library. Obviously I will not start it's implementation tomorrow, but some generic thoughts about how it could look like, what algorithms could be used and so on... Just a thoughts...

/devel/other :: Link / Comments (0)


I want to have 36 hours in my day.


This ppc32 work is (probably already 'was') in my todo list too.

Just thought, that ppc32 uses round-robin algorithm to update TLB cache. It looks like it would be possible to use weighted RR algo instead - i.e. create each entry's usage statistic and flush only entry with the smallest value.

I always wanted to work with low-level hardware and specially with some interesting arch. I probably would not want to be a maintainer of some common arch like PPC, but work with something interesting like LUNA machines based on Motorola 88000 CPU for example. Just a though...

/devel/other :: Link / Comments (0)