On 31 Aug 2016, at 4:40am, sanhua.zh <sanhua...@foxmail.com> wrote:

> Is it caused by mmap file too big that the address space is not enough?

Yes.  Under iOS, memory maps can only be as big as the available physical 
memory.  You're working on a tiny multi-tasking device and memory is at a 
premium.  You can't afford to hog memory.  Nor can you do data-handling so fast 
that it runs down the battery or overheats the device.

Also, iDevices before the iPhone 5S in 2013 ran a 32-bit version of iOS, 
limiting them to 4GB of memory per App.

> If yes, then how can I get the allowed mmap file size?

This figure would be useless since available physical memory varies depending 
on things your application cannot prevent.  For instance, you may find out how 
much free memory there is, but then there may be in incoming phonecall.  iOS 
will then allocate some of that memory to the process dealing with the 
phonecall.  And, of course you cannot do anything to interfere with a phonecall 
because that is more important than an App.

Why are you trying to do memory-mapping on a portable device ?  Is it for speed 
?  Do you absolutely need it ?  Won't the standard SQLite API do the job well 
enough ?

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to