diku-dk / alpacc

MIT License
5 stars 0 forks source link

Slow composition table generation. #12

Closed WilliamDue closed 4 months ago

WilliamDue commented 6 months ago

Currently in src/Alpacc/Lexer/ParallelLexing.hs a decently naïve way of generating the lexer table is used. There is some slow lookups related to the function newEndoConn used in the function connected. It could probably do with some memoization and a map to look at previous connected transitions and not just transitions going out from the given state. Also maybe having a tabel to lookup an Endomorphism with some integer key could be an idea since they occur in many maps.

WilliamDue commented 4 months ago

Fixed https://github.com/diku-dk/alpacc/commit/67cc9daf01fca638a309c891746bccab560e98f1