dongyx / libaca Goto Github PK
View Code? Open in Web Editor NEWC Library of Aho-Corasick Algorithm based on Coordinate Hash Trie
License: BSD 3-Clause "New" or "Revised" License
C Library of Aho-Corasick Algorithm based on Coordinate Hash Trie
License: BSD 3-Clause "New" or "Revised" License
I see that you incrementally allocate nodes on demand via malloc
. In many use cases you will know in advance how many nodes you need and could allocate them in contiguous memory. You would achieve considerable memory savings by eliminating the memory overhead of calling malloc
per node and by using 32-bit indices instead of 64-bit pointers . In addition to the memory savings, these changes would likely improved locality of reference (i.e. performance). Finally, nodes could be packed in contiguous memory in depth-first order (in an offline process) to further improve locality.
Any thoughts on these ideas?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.