This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: 32 bit libraries in a 64 bit world?


The easy and short answer is no.  Your process will not have access to
more memory than is allowed by 32-bit constraints.  The long and hard
answer is perhaps, depending on how much work you are willing to do.
You could potentially have a 64-bit process which shares memory, and
your 32-bit process could map regions of that shared memory.  Another
approach would be to memory map files.  If there is sufficient memory
on the machine, it is likely, but not guaranteed, that if a file has
been in memory, it will remain there, and again, you can map portions
of the memory into your memory space at a time.

It might be worth trying to negotiate the purchase of that source code...

Sorry for the bad news,
  Brian

On Thu, Aug 13, 2009 at 4:54 PM, Brian McGrew<brian@visionpro.com> wrote:
>
>
>
> On 8/13/09 4:50 PM, "Nikos Chantziaras" <realnc@arcor.de> wrote:
>
>> On 08/14/2009 02:31 AM, Brian McGrew wrote:
>>> Good afternoon y¹all! ?I¹ve asked this question once before, so forgive me,
>>> but I never got a conclusive answer and now it¹s time that I have to make
>>> something happen :-)
>>>
>>> We've ported our applications from Fedora Core 5 32 bit to CentOS 5.3 x86_64
>>> and so far our own code is working great.
>>>
>>> Now we need to link to a set of third party libraries that are 32 bit and
>>> since the vendor is in the middle of bankruptcy they're not going to port
>>> the code for us and getting the source code is even more of a stretch.
>>>
>>> Is there anything I can do? ?Some kind of a wrapper or conversion program or
>>> something??? ?These are dynamic libraries I'm linking to using the standard
>>> gcc-4.1.2 that comes with the machine. ?If I need to upgrade gcc or other
>>> libraries on the box, I can do that too.
>>
>> The only practical solution is to build your applications as 32-bit apps
>> ("-m32" GCC switch.)
>>
>
> Well, that is an option, but... ?The whole reason we went to 64 bit was to
> overcome the 3GB memory boundry. ?We're using third party hardware which
> does not support PAE, so the only way to overcome the memory issue was move
> to 64 bit. ?Is it possible that I can use a 64 bit hardware driver and
> compile my application in 32 bit? ?Will the 32 bit application still have
> access to mvoe than 3GB of memory?
>
> -b
>
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]