|
|
|
|
|
by seepel
4349 days ago
|
|
I'm a little late to the party, but I ran the benchmark inserts with cached statements on both my Macbook Pro and my iPhone 5S. sqlite definitely fairs better under this scenario. That being said I still find the speed of Realm pretty impressive. And it's hard to gauge real world performance from this test. In my experience the real bottle necks around insert are upsets and establishing maintaining relationships. For reference here are the benchmarks without reusing sqlite statements. Macbook Pro - Realm: 0.780414 sqlite: 0.464804 FMDB: 0.654659
iPhone 5S - Realm: 2.235381 sqlite: 2.786381 FMDB: 3.336679
And with statement reuse Macbook Pro - Realm: 0.766406 sqlite: 0.189747 FMDB: 0.683823
iPhone 5S - Realm: 2.214847 sqlite: 0.991864 FMDB: 2.832800
Interesting side note: FMDB seems to be spending just as much time finding the cached statement as sqlite takes to prepare a new one. I didn't expect that. I haven't dug into it at all, but I wouldn't be surprised if this due to the fact that the insert statement is relatively simple.EDIT: Just fixed up formatting for the results |
|
Have you set up a pull request / issue by any chance? It paints Realm in a bit worse of a light, but hopefully they'll merge it in and update the site.