allocate 10 GB of memory dynamically

Hi,

I have 1 GB RAM (Physical Memory) and 90 GB Harddisk (Logical Memory).

Is it possible to allocate 5 GB of memory dynamically.

But Dynamic memory allocation depends on Heap that we have. I believe that heap cannot be allocated to have around 8 GB of memory. (But, some tricks must be there to have around 8 GBs of Heap :) :) !! )

Kindly tell some tricks for assigning big amount ( 8 GB ) of Heap by some tricks ?

Thx in advans, Karthik Balaguru

Reply to
karthikbg
Loading thread data ...

Sure, use a 64 bit CPU and OS.

Reply to
Arlet

Hi, How to do that Heap allocation for a Board baed on 32-Bit CPU and OS ? ( CPU cannot be changed at this stage :( .... !! )

Any tricks ?

Thx in advans, Karthik Balaguru

Reply to
karthikbg

There are no easy tricks. With a 32 bit address register, you can only access a theoretical maximum of 4GB. In practice you'll have to subtract kernel memory space.

Which CPU/OS are you using ? With IA-32, you may be able to use the PAE (Physical Address Extension). If you use Windows, look for the Address Windowing Extensions. On Linux, you can use mmap(). Through these tricks you can access more than 4GB, but only in sections, not all at the same time.

Reply to
Arlet

You can allocate as much memory as you like, but not in one piece. If you want to make it look as one piece, you can implement a C++ class which will handle the pointers.

Vladimir Vassilevsky

DSP and Mixed Signal Design Consultant

formatting link

Reply to
Vladimir Vassilevsky

Unable to get your point. I understand that there is some method to allocate memory of any big size. But, not in one piece. How is this possible ? Could you pls explain the technique .

Thx in advans, Karthik Balaguru

Reply to
karthikbg

I am using MCF5272 Coldfire processor and UCOS-II RTOS(Micrium's).

Regards, Karthik Balaguru

Reply to
karthikbg

Got the point now. My understanding is I need to have something similar to malloc and allocate until 1 GB (loops) and have it connected by somemeans and use it . I will try implementing the similar logic .

Thx, Karthik Balaguru

Reply to
karthikbg

I may need to do have something similar to mmap() in UCOS-II. So, mostly something similar thing (mmap) in UCOS-II RTOS has to be written ?? what do you think ? Any ideas / docs for starting with this mmap creation ?

Thx in advans, Karthik Balaguru

Reply to
karthikbg

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.