ios - Dequeuing reusable cell in Swift 3 is incredibly slow -


dequeuing cell taking 0.5-1.0 seconds means uitableview takes more 2-3 full seconds load though has 4 rows.

override func tableview(_ tableview: uitableview, cellforrowat indexpath: indexpath) -> uitableviewcell {     var cellid = "numbercell"     var isnumber = true     if indexpath.row == 0 {         cellid = "textcell"         isnumber = false     }      nslog("before dequeue \(indexpath)")     let cell = tableview.dequeuereusablecell(withidentifier: cellid, for: indexpath) as! textfieldtableviewcell     nslog("dequeued")      // ...      return cell } 

the nslog() statements directly before , after show dequeue takes 07.47 08.38.

2017-07-25 22:07:07.471898-0700 myapp[10209:4507471] before dequeue [0, 0]

2017-07-25 22:07:07.679715-0700 myapp[10209:4507471] [mc] system group container systemgroup.com.apple.configurationprofiles path /private/var/containers/shared/systemgroup/systemgroup.com.apple.configurationprofiles

2017-07-25 22:07:07.683843-0700 myapp[10209:4507471] [mc] reading public effective user settings.

2017-07-25 22:07:08.386960-0700 myapp[10209:4507471] dequeued

the cell simple. has uilabel , uitextfield , uitextfield has editing changed action. that's it.

enter image description here

what heck possibly causing take long dequeue cell? other 2 system nslog()s system group container?

it makes app unusable because when try segue view controller app appears lock 2-4 seconds while it's setting 4 rows.

i've made hundreds of uitableviewcontrollers in objective-c , i've never had problem. there weird swift 3 i'm missing?

2017-07-25 22:07:07.679715-0700 myapp[10209:4507471] [mc] system group container systemgroup.com.apple.configurationprofiles path /private/var/containers/shared/systemgroup/systemgroup.com.apple.configurationprofiles

2017-07-25 22:07:07.683843-0700 myapp[10209:4507471] [mc] reading public effective user settings.

⚠️ log os level. delay in dequeuing uitablecell

you can disable unwanted log in xcode . below

1- xcode menu open: product > scheme > edit scheme

2- on environment variables set os_activity_mode in value set disable

enter image description here

you face problem when debugging app . run fine on real device .


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -