Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

libgeneralist

Name: Anonymous 2011-09-12 22:56

So, /prog/, I'm writing a general library in C, with the aim of being somewhat inspired by libraries such as glib, but far lighter and cleaner. So far, I have a linked list implementation and a Unicode string implementation (this is incomplete), totalling 670 SLOC. The build system is cmake, the code is fully documented with doxygen. Of course, the library is in its infancy and far from finished; what other things should I implement? Any data structures? OS abstractions?

Name: Anonymous 2011-09-13 1:48

>>26
when do you actually use random access? I can think of one situation: image processing.

Everywhere else you are probably going to write some kind of tree data structure to optimize access for special purposes. At least this is what physics and graphcis algorithms do.

arrays are actually not that useful. The only nice thing about them is that they let you more easily utilize the structure of memory (which not coincidentally is more like a tree than a giant 1D plane) to obtain better performance through cache coherency. So instead of making your own trees and doing whatever you want with them, low level advocates say we should work with the trees we are given.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List