|
Boost Users : |
Subject: Re: [Boost-users] Memory mapped files
From: Niall Douglas (s_sourceforge_at_[hidden])
Date: 2019-01-23 01:33:44
> We are developing a system which heavily uses memory mapped files.
> These files are initially created under a unix system, but will then be
> used in portable systems such as Android and iOS.
> We are having some problems loading memory mapped files created under
> Unix into Android.
>
> Is this scenario even possible ?
> Are the memory mapped files compatible between systems ?
This kind of question has nothing to do with Boost, and would be better
asked on Stackoverflow.
However yes Android supports memory mapped files just fine. Free address
space is very limited though, so what works on 64 bit workstations may
not work on 32 bit Android. Also, Intel CPUs are not ARM CPUs, padding
of structs will be different, floating point numbers may have a
different representation or be interpreted a bit differently, there are
a few other differences.
With discipline memory mapped files usable on both architectures can be
devised, but usually with a performance penalty on all platforms. In the
end there is no free lunch.
Niall
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net