Re: Recover/defrag memory API



On Sun, 10 Jul 2005 19:46:25 +0100, "Simon" <spambucket@xxxxxxxxxxxx> wrote:

>>
>>>> It is not clear how it can "defrag" memory, since this is impossible in
>>>> a
>>>> C/C++ program.
>>>> It is a concept beyond anything supported in the language,
>>>
>>>Hence wy i asked for an API, not a standard C++ function.
>> ****
>> You are missing the point. It is *impossible*. No API can do it. It is not
>> doable within C
>> or C++ in the general case, although you can make some very-special-case
>> situations work
>> well. But "impossible" means "impossible by any means whatsoever".
>>>
>
>No, you are missing the point.
>Please, read my OP,
****
I did. It says

"I have been using "System Mechanic 5" and one of their "utility" is to
defrag and/or recover memory.
I can see that somehow it does recover a lot of memory.

But how does it do it? What API does it use?"

The answers you have been getting is that there IS NO SUCH API IT CAN USE. WE ALL KNOW
THIS. Apparently we have not convinced you that there is no such API. There is *NO* API
THAT CAN DEFRAG AND/OR RECOVER APPLICATION MEMORY. THE VENDORS ARE COMMITTING FRAUD, WHICH
MARK RUSSINOVICH EXPLAINS IN DETAIL. BUT THE REST OF US KNOW NO SUCH API CAN EXIST AND
WE'VE BEEN TRYING TO TELL YOU THAT!

So there is no possible way to answer your original posting. The REAL answer is that the
program destroys system performance to give you the illusion it has manged to "defrag
and/or recover memory", but since we know this is not possible, we have been trying to
explain to you that it is not possible. I have told you how to use
VirtualAlloc/VirtualFree to allocate memory buffers to hold file contents, and that is the
best you are ever going to be able to do. It may solve your problem, but it is not related
to any fictitious figment of someone's fevered marketing department's imagination. It
doesn't exist. So the reason I have not answered your question is that it is unanswerable
unless you, too, want to create fraud which destroys overall system performance. I presume
you do not wish to create fraud, but want a technically correct solution. I gave you that
several posts back, but you persist in believing that there is "an API" that does this.
There isn't. And Mark explains in detail how the fraud works.

So your choices are to commit the same fraud, or to rewrite the program with the
suggestion I made. That's it. That's the only two solutions available other than customer
education.
joe

>I love your opinion, and I love hearing about how many years you have been
>in the business.
>But please read my OP before you answer.
>
>BTW, did you even read the link I gave you to help you understand Windows
>memory?
>
>Simon.
>

Joseph M. Newcomer [MVP]
email: newcomer@xxxxxxxxxxxx
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm
.



Relevant Pages

  • Re: Recover/defrag memory API
    ... > I can see that somehow it does recover a lot of memory. ... > The answers you have been getting is that there IS NO SUCH API IT CAN USE. ... > THAT CAN DEFRAG AND/OR RECOVER APPLICATION MEMORY. ...
    (microsoft.public.vc.mfc)
  • Re: Computer has slowed way down
    ... If you believe registry defrag has any value, ... I also dumped Spybot and AdAware and downloaded Microsoft Security ... primary memory cache 512 Kb secondary memory cache. ...
    (microsoft.public.windowsxp.basics)
  • Re: Active Memory Defragmentation: Our implementation & problems
    ... Low memory kernel pages are a much bigger deal to defrag. ... We've thought about having many more allocator pools around to help ease ... you go to free a file's page cache, you get some pretty large contiguous ...
    (Linux-Kernel)
  • Re: [openib-general] Re: [PATCH][RFC][0/4] InfiniBand userspace verbs implementation
    ... > The problem is that our driver and library implement an API that we don't ... > tells the library to register it. ... The app then goes on its merry way until ... at which point it tells the library to deregister the memory. ...
    (Linux-Kernel)
  • Re: Library design for downloading an unknown amount of data?
    ... easy to use api for all supported devices. ... The first one is the device layer, which itself consist of a protocol layer and a memory layout layer. ... An single dive is also a blob of binary data, but with some additional metadata that is required for parsing that data, such as current time at the time of the download, model/serial number, firmware revision, etc. ...
    (comp.lang.c)

Quantcast