From a15cf65c44d5c224169c32ef5495b68c758134b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 18 May 2014 16:08:14 +0200 Subject: Imported Upstream version 3.3.0.2 --- xsd/examples/cxx/parser/performance/README | 44 ++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 xsd/examples/cxx/parser/performance/README (limited to 'xsd/examples/cxx/parser/performance/README') diff --git a/xsd/examples/cxx/parser/performance/README b/xsd/examples/cxx/parser/performance/README new file mode 100644 index 0000000..d8d27a7 --- /dev/null +++ b/xsd/examples/cxx/parser/performance/README @@ -0,0 +1,44 @@ +This example measures the performance of XML parsing in the C++/Parser +mapping. It also shows how to structure your code to achieve the maximum +performance for this operation. + +The example consists of the following files: + +test.xsd + XML Schema which describes the test vocabulary. + +test-5k.xml +test-50k.xml +test-500k.xml + Test XML documents of various sizes. + +gen.cxx + Program to generate a test document of desired size. + +time.hxx +time.cxx + Class definition that represents time. + +test-pskel.hxx +test-pskel.ixx +test-pskel.cxx + Parser skeletons generated by the XSD compiler from test.xsd. + +driver.cxx + Driver for the example. It first parses the command line arguments + and reads the entire document into a memory buffer. It then creates + a SAX parser and pre-parses and caches the schema if validation is + enabled (Xerces-C++ only). Finally, it runs the performance + measurement loop which on each iteration parses the XML document + from the in-memory buffer. + +To run the example on a test XML document simply execute: + +$ ./driver test-50k.xml + +The -v option can be used to turn on validation in the underlying XML +parser (only makes sense for Xerces-C++, off by default). The -i option +can be used to specify the number of parsing iterations (1000 by default). +For example: + +$ ./driver -v -i 100 test-500k.xml -- cgit v1.2.3