Programming :: The Continuous Memory Allocation Is Larger 128kB For DMA Process?

Jun 3, 2010

I want to allocate the continuous memory larger 128k for DMA process. But i can't used kmalloc() function for allocate the memory larger 128KB. allocate the continuous memory larger 128k for DMA process.

View 1 Replies


ADVERTISEMENT

Programming :: Process Memory Allocation

Apr 30, 2011

I have been assigned a school project on detecting memory leaks in linux processes. I am reading.. but have found it hard and inefficient to go through the very vast documentation not knowing what to really look for. Could you please give me some guidelines on this subject?

View 4 Replies View Related

Programming :: Memory Allocation For Struct In C++?

Mar 30, 2010

How do we allocate memory of struct? what i did was

Code:

int main()
struct amp
{

[code].....

cout <<"The size of 'struct' is"<< sizeof(struct amp)<<"and it is located at"<<struct amp*s = malloc(sizeof(struct amp))<<endl;
it gives me an error---
In funtion 'int main()':
error: expected primary-expression before 'struct'
error: expected ';' before 'struct'

View 9 Replies View Related

Programming :: Explorations In Memory Allocation In ANSI C?

Feb 8, 2011

I'm performing some explorations in terms of memory allocations in ANSI C, using the following compiler:

gcc version 4.1.2 20080704 (Red Hat 4.1.2-46)

and I started to try to make the compiler complain for a huge data structure, so I coded this:

[code]....

I mean, I can always read the man entry for gcc but I rather ask because I can then have interaction...

View 11 Replies View Related

Programming :: Write Script To Look For The Presence Of Memory Allocation Calls Without Corresponding?

May 14, 2011

I need to write script to look for the presence of memory allocation calls without corresponding calls to free the memory

View 5 Replies View Related

General :: Application Virtual Address Space Memory Allocation - Memory Does Not Get Free

Apr 20, 2010

I am using malloc and frees a lot in my program. It shows its allocated but when i remove it doesnt show as the memory is removed(I am using the top command to view VIRT memory usage). If this continously grows what would happen to my program (Will it go out of memory?)

View 4 Replies View Related

General :: Memory Allocation - How To Disable Overcommit

Oct 17, 2010

I've been looking into memory overcommitting in Linux using /proc/sys/vm/overcommit_memory, and I've read a few articles which don't say the same thing. This doc, under the heading "Going in the wrong direction", goes on to say, "values 1: do overcommit, and 0 (default): don't", but then in the next few lines, it mentions, amongst similar things, that this isn't actually true and that 0 means "guess about how much overcommitment is reasonable". That means that memory overcommit isn't disabled using value 0, right?

It also says that 1 indicates "never refuse any malloc()", with 2 meaning "be precise about the overcommit - never commit a virtual address space larger than swap space plus a fraction overcommit_ratio of the physical memory." The Red Hat magazine, on the other hand states, "if the value is 0, then the kernel checks to determine if there is enough memory free to grant a memory request to a malloc call from an application. If there is enough memory, then the request is granted. Otherwise, it is denied and an error code is returned to the application."

This sounds exactly like disabling overcommit. "If the value is set to 1, then the kernel grants allocations above the amount of physical RAM and swap in the system as defined by the overcommit_ratio value.... If the setting in this file is 2, the kernel allows all memory allocations, regardless of the current memory allocation state." In terms of values 1 and 2, that is the opposite of what the previous doc said, right? What is actually correct, and if it is possible to 'disable' overcommit?

View 1 Replies View Related

Programming :: Getting The CPU & (Virtual) Memory Of A Process?

Aug 23, 2010

Is there any program which gets the CPU and memory of a process ?

View 1 Replies View Related

Programming :: Access Another Process's Memory With A Twist?

Jul 31, 2010

I have been looking for a method for a while now that would allow me to access another process's memory without causing it to freeze. But with all of my googling I have found nothing

so, my question is: Is there a way to not lock a process while accessing it's "/proc/[PID]/mem" interface?

View 3 Replies View Related

Fedora Servers :: Virtual Machine Manager Won't Allow Memory Allocation Over 1024

Jan 26, 2010

I'm running Fedora 11 (2.6.30.10-105.2.4.fc11.i686.PAE) 8 GB memory on a AMD Phenom(tm) II X4 965 Processor, 4 core server I just built.The problem I have run into is any virtual machine that has >1024 MB memory assigned to it will not boot. As along as it has 1024 MB or less it boots fine.The symptom you see is a very quick message "Booting from hard disk" the screen then goes blank, you can't login through SSH, and can't ping the network address so I know it's not some crazy video problem hiding the boot process.The attachment are messages from a failed boot attempt.

View 4 Replies View Related

Ubuntu :: Slow Gaming Experience - Increase Graphics Memory Allocation?

Jun 9, 2011

When I play Bejewelled Blitz on Mozilla firefox or Google Chrome,, it is so painfully slow that it is frustrating, I have all the latest updates from Ubuntu installed including the Adobe flashplayer. Is there some way I can increase the graphics memory allocation?

View 5 Replies View Related

Server :: MySQL & HTTP Process Allocation To Separate Processors

Sep 29, 2010

I have 2 CPU 8 GB RAM server running MySQL & HTTP server with apps using LAMP architecture. Since last few days we are having some performance problems.While looking at the problem i came to know both mysql and http are almost taking 100% cpu time of a single processor and the second processor is free. redirecting the mysql load to one cpu and http load to the second one? Is it possible? If so how to do it?

View 1 Replies View Related

Server :: Why VMrss Is Larger Than The Physical Memory

Aug 30, 2010

I got the VMrss used by a process as about 2GB, but the physical memory of my computer is only 1G.

View 10 Replies View Related

Programming :: Physical Memory Leaked By User Application Process Is Not Reclaimed Back After Exit?

May 2, 2010

Whenever I'm running my application process, I've 1M physical memory usage is increasing for every 2 hours.This I observed using 'free -m' command.But 'top' command did not showing any increase 'RSS' size.It is same as it was started initially.Even though I stopped my process,the increased memory was not released back. If I start my application process then again memory usage start increasing by 1M for every 2 hours. increase of memory usage observer with 'free' and that too when my application is running, but top command is not showing any change in the RSS sizeIf my application is leaking any memory which is allocated by new/malloc, that should be released back whenever my application exit and the size increase will be show through top command for that process, right? This is not happeningThis proves that there is no potential leaks in my process.But why physical memory is increasing when only my process is running?

View 14 Replies View Related

General :: Disk Based Text Editor To Edit File Larger Than Memory?

Aug 2, 2010

I am using Ubuntu and looking for a good editor to edit a file that is > 4GB. I just need to put content at the end and beginning of the file. I suppose I could use something like

cat "text to add" >> huge_file

To append to the file. Is that the route to go? What about prepending? In general, what is the best route if I wanted to edit somewhere in the middle?

I've tried VIM and it fails miserably. I assume emacs and nano would be even worse. What else is there? I assume to accomplish what I am looking for, the editor would have to be specifically designed for this by not keeping the entirety of the file's contents in memory.

View 5 Replies View Related

General :: Ubuntu - Memory Full, Process Memory Usage Doesn't Add Up In Top?

Mar 18, 2011

I have a computer with 16GB of ram. At the moment, top shows all the RAM is taken, (NOT by cache), but the RAM used by the various processes is very far from 16GB.I have seen this problem several times, but I don't understand what is happening.My only remedy so far has been to reboot the machine.

View 1 Replies View Related

Fedora :: User Memory Allocation - Set A Maximum Limit On The Amount Of Ram A User Can Utilize?

Jul 24, 2009

I have a few multi-user servers in an academic laboratory. I am having a problem with some users maxing out the available RAM, causing such sever slowdowns the machine essentially crashes. My servers are Dell Power Edge's running Ubuntu 8.10 Server Edition (Not my choice). I would like to set a maximum limit on the amount of ram a user can utilize. This morning I experimented with setting limits via /etc/security/limits.conf and using ulimit. Neither of them prevented my test program, a simple infinite loop of mallocs, from crashing the server.

View 7 Replies View Related

Ubuntu :: Memory Leak / Some Process Eating All Memory

Jan 29, 2011

I have had a fresh install of Ubuntu 9.10 and installed some software after that.Since third some, some process is eating half of my memory.I have checked processes running in system manager but everything is normal.Maximum is consumed by compiz which is about 26 mb, seems very normal.I did restarted my computer several times, and in the start for 5 mins, its fine after that again my cpu fans runs at very fast speed and my one cpu is used up 95 % (I have dual core).Please help me out, this invisible thing is driving me crazy.I am attaching my htop screen shot (sorted by cpu %), now the cpu is not used by completely but fan is still struggling hard and fast.

View 9 Replies View Related

Programming :: Shared Memory Address Area In Process Address Space?

Feb 21, 2011

if i attach a shared memory to my process whch part of the address space it will add(like stack, heap, data, code...).

View 3 Replies View Related

Programming :: 32-bit Executable Getting St9bad_alloc @ 3GB Mem Allocation

Jan 13, 2010

I'm maintaining a c++ application running on a 64-bit RHEL5 server w/32GB ram, but compiled to be a 32-bit executable with g++. The application handles large amounts of data, and has lately been throwing a st9bad_alloc exception. "top" shows the application as dieing right around when VIRT=~3GB, SWAP=~1.5GB and RES=~1.5GB. In the core dump I can see that it's consistently failing to push_back() a piece of data onto a std::vector (which already has hundreds of thousands of objects in it).

I know 4GB is the maximum address space for 32-bit applications. I've learned from this lwn article that a 32-bit kernel reserves 1GB of address space, leaving 3GB for user space. However I'm not running a 32-bit kernel, so that really doesn't answer anything.I wrote a dummy app which called malloc() over and over in a for loop, and it is able to allocate right up to the 4GB before it fails. I don't understand why this one seems to be able to allocate more.

The only difference between the two apps (besides malloc vs std::vector:ush_back), is that the 3GB crashing application attaches to 512mb of shared memory.Anyone have any ideas why this application would be crashing at 3GB? Is there any more diagnostics I should be doing? I would ultimately like to port this to 64-bit for a number of reasons, but it is a big undertaking for my organization, and I'd like to better understand what's going on here.

View 3 Replies View Related

Ubuntu Servers :: Strange File Names - Getting Larger And Larger All The Time

May 3, 2011

Using Samba I have looked into the file that stores all my web sites, there were a few strange files that get larger and larger all the time. File names are _Za01716 and _Za01820, they are nearly 50mb in size now. I know these are not Log files so what are they and can I delete them?

View 1 Replies View Related

Programming :: Didn't Change The Original Value Of The Pointer It Was Trying To Use For Allocation?

Feb 8, 2011

A friend working in HPC environments commented me that he had an issue regarding the use of the malloc() function.What issue?He told me that he has had cases in where malloc() instead of returning a NULL pointer on failure, simply didn't change the original value of the pointer it was trying to use for allocation, thus forcing him to initialize pointers to be allocated with malloc() to NULL, so that he could be sure that if malloc() fails, a test for NULL would make sense.

View 12 Replies View Related

Programming :: Processor Priority Level For Algorithm For Buffer Allocation

Jan 9, 2010

The algorithm for reading and writing disk blocks use the algorithm getblk to allocate buffers from the pool. In the algorithm getblk, if the kernel removes a buffer from the free list, it must raise the processor priority level to block out interrupts before checking the free list. Why ?Where can i find the C implementation of the above algorithm for buffer allocation in the linux source code ?

View 1 Replies View Related

Programming :: Declare An Array With The Number Of Elements Is Larger Than 2^32?

Oct 12, 2010

How can I declare an array with the number of elements is larger than 2^32 ?

View 2 Replies View Related

Programming :: Memory Leaks - Glibc Detected - ./SuffixTree: Malloc() - Memory Corruption - 0x00

Mar 21, 2011

I am new to C and linux. My code below does arbitary writes but I cant figure out where or how it does it.

I am calling the insertNode() function with seq = 'MISSISSPPI$' and alphabets = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ$'

Code:

Weird behaviour I should mention is that when I check for NULL pointer in node->child[index], the unassigned values are not null anymore, they point to arbitary memory.

View 12 Replies View Related

Programming :: Write A Script That Can Show Me Total Memory Vs Used Memory?

Apr 13, 2010

How do I write a script for my Linux that can show me total memory vs used memory and have it email me results if it's over 70 percent?

View 2 Replies View Related

Server :: PHP File Open Larger Files Or Fopen Files Larger Than 2gigs

Feb 16, 2011

I have a ubuntu 10.10 server with apaceh2 and php and I want to open a file larger than 2gigs

I've read there is a flag that needs to be compiled into php to do this ?

View 6 Replies View Related

Programming :: SHM Memory Counted As Cache Memory With Kernel 2.6.18?

Aug 25, 2010

Is that possible that SHM shared memory is counted as cache memory on Linux with kernel 2.6.18?If find it really odd since this memory is not file backed, but I have a piece of code that loads data using shm_open+mmap, and it generates an amount of cache memory in /proc/meminfo that corresponds exactly to the amount of shared memory (I load that data from a file but I am using posix_fadvise(fd,0,0,POSIX_FADV_DONTNEED) to ensure this file is not cached and I made sure that it is working as expected). As far as I know SHM memory was not tagged as cache memory with kernel 2.6.9.If it is the case it is really unfortunate since normally cache memory can be considered to be part of the "available" memory since it can be flushed promptly but this is clearly not the case with SHM memory... Is there an easy way to get the total amount of used SHM memory on a system?

View 4 Replies View Related

General :: Get Process Memory Consumption?

Apr 2, 2011

I need a command that can get the memory consumption of a process called "job_runner_o".

Running ubuntu 10.10

View 2 Replies View Related

Red Hat / Fedora :: Memory Utilization For Particular Process

Jul 15, 2009

Is there any command to get the memory utilization of a particular process in Linux?I tried with Top and /proc/pid/status commands but the results are not proper, the memory keeps on increasing.Can anyone tell other than Top and /proc/pid/status commands ?

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved