et99 <et…@rocketship1.me> posted:
>
>
> The bitarray C extension stores arrays of small integers (1, 8, 16, 32 or 64 bits, signed or unsigned) packed in memory that looks and behaves like an ordinary Tcl list. To the rest of Tcl a bitarray IS a list: lindex, lset, lrange, lreplace, linsert, foreach, "in", lsort, lsearch, join, {*}$a all work on a bitarrary.
>
> .....
>
> They work a 64-bit word at a time, and the logical and relational operators use SSE2 for the 8-, 16- and 32-bit widths on x86-64 (on by default; one build switch turns it off). The table below is one million elements, microseconds per call, measured on Windows with Visual C++ /O2 against the same job done on a plain list with an ordinary Tcl loop. The numbers are from running extras/listbench.tcl on a Windows run.
>
> operation plain list bitarray speed-up-approx
> a AND b (1-bit arrays) 87,347 7.9 11,000x
> ....
> "> 1000" on a 16-bit array 250,769 315 800x
>
> Questions, bug reports and criticism are welcome. Mit Licence.
>
> -Eric
>
It seems astonishing, almost incredible, especially for the use on digital signals or
analog signals (after being converted to integer). What are land, lnot ...?
Are they just mnemonics you used for your explanations ?
Olivier.