Skip to content
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

[RLMMigration] Call enumeration blocks inside an autoreleasepool #2206

Merged
merged 2 commits into from
Jul 22, 2015

Conversation

segiddins
Copy link
Contributor

Closes #2205.

\c @tgoyne

@segiddins segiddins added the pr label Jul 15, 2015
@tgoyne
Copy link
Member

tgoyne commented Jul 15, 2015

changelog

@segiddins
Copy link
Contributor Author

changelog added

@tgoyne
Copy link
Member

tgoyne commented Jul 15, 2015

👍

@porsager
Copy link
Contributor

Hi @segiddins

Cool - that's some very fast action right there ! :)

I use swift 2.0, so i tried merging this branch with the swift-2.0 branch and run the same migration with it. It goes to about 80mb of memory usage and then just freezes there forever.

I don't know if it's of any help, but if i pause in the debugger the stack looks like this:

#0 0x0399154a in __psynch_mutexwait ()
#1 0x03958210 in _pthread_mutex_lock ()
#2 0x03958003 in pthread_mutex_lock ()
#3 0x003fea61 in realm::util::RobustMutex::low_level_lock() ()
#4 0x004aa3d3 in realm::SharedGroup::do_begin_write() ()
#5 0x004aa297 in realm::SharedGroup::begin_write() ()
#6 0x003c54cb in realm::SharedGroup::upgrade_file_format()

Thanks for the very quick reaction!

@segiddins segiddins force-pushed the seg-autorelease-migration branch from 3a976cb to 0954434 Compare July 20, 2015 22:47
@segiddins
Copy link
Contributor Author

@porsager that's probably a different issue -- can you share a project that demonstrates that problem with us?

@segiddins
Copy link
Contributor Author

Test failures appear unrelated?

@jpsim
Copy link
Contributor

jpsim commented Jul 21, 2015

@segiddins please rebase this

@segiddins segiddins force-pushed the seg-autorelease-migration branch from 0954434 to 17d4bc6 Compare July 22, 2015 01:01
@segiddins
Copy link
Contributor Author

Rebased

@porsager
Copy link
Contributor

@segiddins You are right it is independent of this issue. Would you want me to create a new issue for it, or can i email you a test project with the issue?

@segiddins
Copy link
Contributor Author

@porsager an email with a test project would be perfect, thanks!

@jpsim
Copy link
Contributor

jpsim commented Jul 22, 2015

👍

segiddins added a commit that referenced this pull request Jul 22, 2015
[RLMMigration] Call enumeration blocks inside an autoreleasepool
@segiddins segiddins merged commit f1ea590 into master Jul 22, 2015
@segiddins segiddins removed the pr label Jul 22, 2015
@segiddins segiddins deleted the seg-autorelease-migration branch July 22, 2015 19:51
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 16, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enumeration of objects in migration without loading everything into memory
4 participants