You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by Shlomi Afia <Sh...@whale-com.com> on 2001/08/12 18:16:43 UTC

Page faults, when running DOM parser on windows NT

Hi there,
I'm running this simple test program on Windows NT,  using xerces version
1.3.0:

int main(int argc, char* argv[])
{
	char buffer[5000];

	XMLPlatformUtils::Initialize();
	DOMParser* parser = new DOMParser;

	FILE* stream = fopen("D:\\Temp\\test.xml", "r"); 
	int bufferSize = fread(buffer, sizeof(char), 5000, stream);
	fclose(stream);

	while (true)
	{
		MemBufInputSource memBuff((XMLByte*)buffer, bufferSize, "");
		parser->parse(memBuff);
		Sleep(10);
	}

	delete parser;
	return 0;
}

To my surprise it has a lot of memory page faults! (the test.xml file is
less then 5000 bytes).
Does anybody know how can I reduce the amount of page faults the DOM parser
creates?

thanks,
Shlomi.


---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org