The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > High Level Programming
.
google unix.com



High Level Programming Post questions about C, C++, Java, SQL, and other programming languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
cpu, memory and virtual memory usage ocelot UNIX for Dummies Questions & Answers 4 12-01-2008 07:57 AM
unable to allocate enough memory rein UNIX for Advanced & Expert Users 11 05-14-2008 12:04 PM
Unix Help - allocate more memory to /tmp cmackin UNIX for Dummies Questions & Answers 1 06-01-2006 06:25 AM
about virtual memory and memory leak shriashishpatil High Level Programming 4 02-20-2006 11:31 AM
virtual memory big123456 UNIX for Dummies Questions & Answers 2 10-10-2005 01:21 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 04-20-2007
munnu munnu is offline
Registered User
  
 

Join Date: Nov 2006
Posts: 17
how allocate virtual memory

Hi Folks
can any body suggest how to allocate virtual memory any function for that
  #2 (permalink)  
Old 04-20-2007
Perderabo's Avatar
Perderabo Perderabo is offline Forum Staff  
Unix Daemon
  
 

Join Date: Aug 2001
Location: Ashburn, Virginia
Posts: 9,111
What an odd question. Everything you do is virtual memory.
int line[120];
The array "line" will be in virtual memory. For dynamic allocations there is malloc(). Even if you lock an item into core, it will still be virtual and the virtual addresses will be translated to physical addresses as it is used.
  #3 (permalink)  
Old 04-20-2007
jim mcnamara jim mcnamara is offline Forum Staff  
...@...
  
 

Join Date: Feb 2004
Location: NM
Posts: 5,717
It's based on knowing only Windows API calls. There is an API there, VirtualAlloc that allocates virtual -per the description anyway- memory (swapfile space).

I agree - the question make no sense in UNIX.

For clarification try reading this link -
Code:
http://msdn2.microsoft.com/en-us/library/aa366887.aspx
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 02:52 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0