I know i can simulate a memory warning on the simulator by selecting 'Simulate Memory Warning' from the drop down menu of the iPhone Simulator. I can even make a hot key for that.
But this is not what I'd like to achieve. I'd like to do that from the code by simply, lets say doing it every 5 seconds. Is that possible?
...
While debugging in instruments using 'ObjectAlloc' I'm noticing 7megs of memory being allocated for the renderInContext call, but it never is released. When I comment out the renderInContext call this doesn't happen, and future renderInContext calls does not continue to increase the memory allotment.
UIGraphicsBeginImageContext(contentH...
Hi,
I'm having a few problems with some Objective-C and would appreciate some pointers.
So I have a class MapFileGroup which has the following simple interface (There are other member variables but they aren't important):
@interface MapFileGroup : NSObject {
NSMutableArray *mapArray;
}
@property (nonatomic, retain) NSMutableArray ...
I am using a webBrowser control to open PDF document in winforms, it works fine but when closing the application I get sometimes an error : "The Instruction at "0x2d864aa2" referenced memory at "0x00000008". The memory could not be "read".
Is there a solution for this problem?
Regards.
...
I just read this statement in a java book saying Objects in java reside on a heap.
Is a heap used because it is the best way to store data and retrieve data fast ?
I only have an idea about data structures being a beginner. I mean why not stack or something else ?
...
Hi,
Can anyone tell me if a linkedlist of structures will be allowed to grow larger than the equivalent List (given that a list uses a doubling strategy for increasing the size of it's internal array).
So given a struct that is say 40 bytes (I know about the 16 bytes and structure thing, but I am working with some legacy code here and ...
Is it possible that the .Net framework behaves differently when it comes to garbage collection / memory limitations on server environments? I am running explicitly x86 compiled apps on a 64bit server machine with 32gbs of physical ram and I am running out of memory (SystemOutOfMemoryException) even though nothing but that particular app ...
Does that sound right to anyone????
I have an ItemsControl that displays data from a custom object that implements iNotifyPropertyChanged. The DataTemplate consists of:
Border
3 buttons
5 textboxes
An ellipse
A Bindable RichTextBox (custom class that inherits from RichTextBox... so I could make Document a dependency property (to suppo...
As I know that accessing an element in vector takes constant time while in map takes logarithmic time. However, storing a map takes less memory than storing a vector.
Therefore, I want to ask which one is better in general? I'm considering using one of those two in my program, which has about 1000 elements. I plan to use 3 dimensional v...
In my application I need to keep track of a list of objects that are being displayed. Right now I have an NSArray with all of the NSManagedObjects. Would I be better off to store the ObjectIDs and then only request the object when I need it?
I am mainly concerned about memory at this point.
...
When I type in the foll. code, I get the output as 1073741823.
#include <iostream>
#include <vector>
using namespace std;
int main()
{
vector <int> v;
cout<<v.max_size();
return 0;
}
However when I try to resize the vector to 1,000,000,000, by v.resize(1000000000); the program stops executing. How can I enable the program to all...
Is there a function or constant defining the amount of available memory for an app in iPhone OS?
I'm looking for a device-independent way (iPod touch, iPhone, iPad) to know how much memory the app has left.
...
Ok, so here's my problem. My iPhone app is 1.2MB on disk. Granted I have a bunch of Images for the GUI buttons and backgrounds, etc. In-memory, my app takes up a whopping 15MB!
That means if I then take a picture with the camera, 8MB default, it gives a memory warning (several) even before the picker calls its delegate!
How can I te...
Is there a soft to do that?
I'm looking for a windows server (I might go for a VPS server), and I would like to know the ram I will need
I know I won't need a lot of ram, but beside the "windows task manager", is there a way to really test that?
Thanks
...
I want a string type that is Unicode and that stores the string directly at the adress of the variable, as is the case of the (Ansi-only) ShortString type.
I mean, if I declare a S: ShortString and let S := 'My String', then, at @S, I will find the length of the string (as one byte, so the string cannot contain more than 255 characters...
I'm trying to scroll through images being downloaded from a users online album (like in the facebook iphone app) since i can't load all images into memory, i'm loading 3 at a time (prev,current & next). then removing image(prev-1) & image (next +1) from the uiscroller subviews.
my logic works fine in the simulator but fails in the device...
I'm developing an application in which I need a structure to represent a huge graph (between 1000000 and 6000000 nodes and 100 or 600 edges) in memory. The edges representation will contain some attributes of the relation.
I have tried a memory map representation, arrays, dictionaries and strings to represent that structure in memory, ...
Let's say I create 5 objects, all from the same class. Would the byte offset of the first object be 0? How would I find out the byte offset of the other objects?
...
I'm dynamically adding a lot of input fields through jQuery but the page gets really slow when reaching 200+ inputs (think of the page like a html excel sheet). This is fine really because this scenario is not very common. However, when I dynamically remove the input fields from the page using jQuery's htmlObj.remove() function, the page...
I can set the max memory as 1000 and not more than that, if I set the memory more than that, it throws the following error.
Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.
My question is, why jvm looks for the max memory at startup?
Thanks in advance....