New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using ArrayPool for AssocTable #8234
Conversation
@@ -234,8 +231,14 @@ module internal Implementation = | |||
let ruleValues = (Array.zeroCreate 100 : obj[]) | |||
let lhsPos = (Array.zeroCreate 2 : Position[]) | |||
let reductions = tables.reductions | |||
let actionTable = new AssocTable(tables.actionTableElements, tables.actionTableRowOffsets) | |||
let gotoTable = new AssocTable(tables.gotos, tables.sparseGotoTableRowOffsets) | |||
let cacheSize = 7919 // the 1000'th prime |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lol what?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have no idea :) - I just copied what was there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fair enough
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Style nits, one of which should impact debuggability I think.
we are allocating a large int array every time we want to parse anything.
Is there some trace data or benchmark that shows the impact of this?
@cartermp Added trace data |
tagging myself so I can know to wait for this before releasing the next FCS. |
* Using ArrayPool * Remove open * Changed some style nits * Clear arrays
Uses ArrayPool for AssocTable since we are allocating a large int array every time we want to parse anything.