-
Notifications
You must be signed in to change notification settings - Fork 16
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
Sqlite improvements #61
Conversation
bdce5f7
to
1b924a2
Compare
622bf42
to
6071477
Compare
Ok, re-aimed this at main now that refactor host is merged. |
64440ec
to
f0e6406
Compare
Update here. Have been working with Luke and iterating on both api and usability. So Things are shifting again now. Kinda an interactive review. |
@Anton-4, I renamed some files and am getting CI failures now. Probably am missing something obvious, but I can't seem to figure out why it is still pulling in the old name. |
I fixed the old InternalSql references, perhaps you forgot to commit a file? Now, they all get stuck at:
|
Yeahs, something must not be matching locally with what I have pushed. I know I updated those file...
Yeah, this broke recently when I was trying to make the tags nicer. Have to figure it out still. |
For the sql file. Locally, I had |
Huh, that's unexpected 😄 |
aad9cf2
to
9adc707
Compare
ce282ea
to
42c7a56
Compare
|
crates/roc_host/src/roc.rs
Outdated
let alloc_result = heap.alloc_for(stmt); | ||
match alloc_result { | ||
Ok(out) => { | ||
// TODO: only make these constant if they escape init. |
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 do think this TODO needs to be dealt with before we land. Just an FYI
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.
@bhansconnect I think I resolved this in fd317fb. Can you just double check as I wasn't 100% around the logic here. Like are we setting refcount to zero during or after init. I've opted for during as that feels right, these stmts will escape init and therefore we don't want them to be freed.
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 think I realized a cooler way to do this. Just pushed it. It also has the advantage that an sqlite statement that is freed during init will actually get freed. Only those still live after init will be promoted to constants!
Ok, I think this is good for final review and merge! |
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.
Woo! 🐙
Revert "Merge pull request #61 from roc-lang/sqlite-improvements"
I think this will be a really cool api improvement that also should give us some perf gains. That said, currently breaks the compiler. Putting the PR up so that other can look at it. Maybe someone else has some ideas of things to mess with to get it compiling. My guess is that tasks + record builders do not play happily together, but the root cause my be something else.
Really want to land this if possible, but might take compiler fixes. I think the impl is pretty cool. Thanks @agu-z for the record bulder help.