Einzelnen Beitrag anzeigen

Benutzerbild von himitsu
himitsu

Registriert seit: 11. Okt 2003
Ort: Elbflorenz
43.116 Beiträge
 
Delphi 12 Athens
 

Re: himXML (gesprochen himix ML)

  Alt 4. Jan 2010, 18:39
Soo, diesesmal ist nicht allzuviel passiert (hatte aber sozusagen versprochen den Code schon jetzt mal hochzuladen)

- vorwiegend wurde an der Speicherveraltung rumgespielt
- die ganzen Serialisierungsfunktionen wurden fast komplett überarbeitet
- der Code wurde Downgegradet und sollte nun mindestens ab Delphi 7 arbeiten
(Einiges ist aber erst ab Delphi 2006, bzw. TDE verfügbar)
- vorallem die Demo CheckLibs wurde umgebaut
Grund: http://www.delphipraxis.net/internal...t.php?t=170881
und http://www.delphipraxis.net/internal...t.php?t=171185
- und dann wurden auch gleich mal die anderen XML-Libs upgegradet (Grund hierfür kommt gleich)


Ja, nachdem ich sowieso schonmal eine der Libs erneuerte,
http://www.delphipraxis.net/internal...t.php?t=170293
hab ich das bei den Anderen auch mal gemacht und zusätzlich noch welche nachgerüstet.
Also wurde gleich mal alles etwas umgestellt.

Beim Umsehen fiel mir auf, daß einige Libs nun doch wieder aktualisiert werden,
sei es von Fremden (siehe SimpleXML) oder den Erstellern persönlich
und das nachdem sich an vielen Stellen seit Jahren nichts mehr regte.

Enthalten sind jetzt alle Dateien und Links zu diesen Libs (siehe Ordner "other" und der CheckLibs-Demo).

ThaXML v1.0 12.01.2003
ist vollkommen veraltet und läuft ab D2009 nur noch zufällig ab und zu mal und manchmal erstellt es defekte und vorallem nicht Codierungskonforme XML-Dateien

OmniXML v2010-01-03
nja, obwohl diese Lib anscheinend gutes Potential hatte

SimpleXML v2010-01-03
samso läuft es nun auch unter D2009 und vermutlich D2010 (teste ich demnächst mal)

XMLLib v1.90 09.12.2009
joar, auch Muetze1 hat doch nochmal viel an seiner Lib gemacht

@Muetze1: ich dachte du wolltest "nur" noch an deiner geheimen neuen Lib basteln?
und du hast Recht, für größere Dateien ist deine Lib nicht wirklich geeignet, aber was soll's.

KDS XML v1.41 2004-04-07
liegt nur bei, aber Aufgrund des Alters und da bisher keine Nachfrage bestand, ist sie nicht in die CheckLib integriert

XML Parser v1.0.19 2009-12-31
sobald ich meinen SAX-Parser (TSAXReader) wieder in Betrieb nehm, wird dieser auch mit in die CheckLibs integriert ... solange liegt er einfach nur so daneben rum

und dann noch MSXML, XercesXML und OpenXML
wobei MSXML ja wohl (bei halbwegs "normalen" Dateigrößen) das Langsamste und der größte Speicherfresser ist.
PS: beim Löschen von Nodes und mit doNodeAutoIndent ergibt sich krankes Bid, denn alle Formatierungen bleiben erhalten, welches in Test 2 eine rießige Lücke aus Leerzeichen und Zeilenumbrüchen zurückläßt und die Datei so auf die Doppelte größe aufbläht


PS: falls jemand ein schönes Testszenaio hat, welches halbwegs einheitlich auf alle integrierten Libs anwendbar ist, dann kann er/sie sich gerne mal melden


und hier noch die Ausgabe der CheckLib.dpr
Code:
SetProcessAffinityMask: OK

precreating used strings - do not create and convert this within the measuring
create: 40 


***** Information ************************************************************* 

mem      : new allocated virtual memory
filesize : size | size after reformatting by himXML


***** Test 1 ****************************************************************** 

fill TXMLFile with 10.000 nodes and save this into a file
create: 0   fill: 7   save: 4   free: 3   mem: 1mb
filesize: 148.961|148.961 

fill MS-XML-DOM with 10.000 nodes and save this into a file
create: 4   fill: 12.959   save: 55   free: 48   mem: 11mb
filesize: 148.962|148.961 

fill ThaXML with 10.000 nodes and save this into a file
create: 0   fill: 4   save: 8   free: 24   mem: 1mb
filesize: 158.945|148.944 

fill SimpleXML with 10.000 nodes and save this into a file
create: 0   fill: 4   save: 7   free: 1   mem: 1mb
filesize: 138.943|148.944 

fill XMLLib with 10.000 nodes and save this into a file
create: 0   fill: 140   save: 33   free: 43   mem: 1mb
filesize: 158.963|148.961 


***** Test 2 ****************************************************************** 

fill TXMLFile with 10.000 nodes, delete 8.000 nodes and save this into a file
create: 0   fill: 6   delete: 304   save: 1   free: 0 
filesize: 28.961|28.961 

fill MS-XML-DOM with 10.000 nodes, delete 8.000 nodes and save this into a file
create: 1   fill: 12.981   delete: 81.925   save: 53   free: 41 
filesize: 60.962|28.961 

fill ThaXML with 10.000 nodes, delete 8.000 nodes and save this into a file
create: 0   fill: 4   delete: 1.601   save: 2   free: 1 
filesize: 30.945|28.944 

fill SimpleXML with 10.000 nodes, delete 8.000 nodes and save this into a file
create: 0   fill: 4   delete: 91   save: 1   free: 0 
filesize: 26.943|28.944 

fill XMLLib with 10.000 nodes, delete 8.000 nodes and save this into a file
create: 0   fill: 141   delete: 523   save: 7   free: 4 
filesize: 30.963|28.961 


***** Test 3 ****************************************************************** 

fill TXMLFile with 10.000 nodes with attributes and save this into a file
create: 0   fill: 15   save: 13   free: 5   mem: 1mb
filesize: 267.851|267.851 

fill MS-XML-DOM with 10.000 nodes with attributes and save this into a file
create: 1   fill: 15.534   save: 59   free: 55   mem: 4mb
filesize: 267.852|267.851 

fill ThaXML with 10.000 nodes with attributes and save this into a file
create: 0   fill: 10   save: 24   free: 25   mem: 1mb
filesize: 277.835|267.834 

fill SimpleXML with 10.000 nodes with attributes and save this into a file
create: 0   fill: 7   save: 12   free: 3   mem: 1mb
filesize: 257.833|267.834 

fill XMLLib with 10.000 nodes with attributes and save this into a file
create: 0   fill: 144   save: 50   free: 46   mem: 1mb
filesize: 277.853|267.851 


***** Test 4 ****************************************************************** 

fill TXMLFile with 100.000 nodes, save into and load this from a file
create: 0   fill: 73   save: 35   free: 41   mem: 11mb
create: 0   load: 180   free: 36 
filesize: 1.588.961|1.588.961 

fill MS-XML-DOM with 100.000 nodes, save into and load this from a file
create: 1   fill: 1.338.466   save: 145   free: 504   mem: 143mb
create: 0   load: 333   free: 94 
filesize: 1.588.962|1.588.961 

fill ThaXML with 100.000 nodes, save into and load this from a file
create: 0   fill: 44   save: 110   free: 2.692   mem: 12mb
create: 0   load: 403.349   free: 2.692 
filesize: 1.688.945|1.588.944 

fill SimpleXML with 100.000 nodes, save into and load this from a file
create: 0   fill: 53   save: 73   free: 24   mem: 4mb
create: 0   load: 163   free: 23 
filesize: 1.488.943|1.588.944 

fill XMLLib with 100.000 nodes, save into and load this from a file
create: 0   fill: 12.398   save: 325   free: 3.869   mem: 18mb
create: 0   load: 12.099   free: 3.869 
filesize: 1.688.963|1.588.961 


***** Test 5 ****************************************************************** 

fill TXMLFile with 100.000 nodes with attributes and search nodes
create: 0   fill: 15   search: 1.899   free: 5 

fill MS-XML-DOM with 100.000 nodes with attributes and search nodes
create: 8   fill: 15.348   search: 151.316   free: 57 

fill ThaXML with 100.000 nodes with attributes and search nodes
create: 0   fill: 11   search: 11.159   free: 25 

fill SimpleXML with 100.000 nodes with attributes and search nodes
create: 0   fill: 7   search: 430   free: 3 

fill XMLLib with 100.000 nodes with attributes and search nodes
create: 0   fill: 144   search: 2.850   free: 48 


***** Test 6 ****************************************************************** 

fill TXMLFile with 3.000.000 nodes, save into and load this from a file
create: 0   fill: 12.073   save: 11.994   free: 2.327   mem: 1.536mb
create: 0   load: 28.524   free: 2.164 
filesize: 315.777.851|315.777.851 

fill MS-XML-DOM with 3.000.000 nodes, save into and load this from a file
error: das ist wirklich keinem zumutbar

fill ThaXML with 3.000.000 nodes, save into and load this from a file
error: EOutOfMemory wrde sich so ab 2.000.000 melden
error: ab etwa 500.000 braucht .Free ewig und es steigt expotentiel an
       es sind hiermit also efektiv nicht viel mehr als 200.000 m”glich
fill ThaXML with 200.000 nodes, save into and load this from a file
create: 0   fill: 546   save: 2.349   free: 11.736   mem*15: 1.496mb
filesize: 22.377.835|error
Ungültige Zeigeroperation
error: das Laden wrde ewig brauchen
fill ThaXML with 15.000 nodes, save into and load this from a file
create: 0   fill: 38   save: 181   free: 59 
create: 0   load: 113.716   free: 59 
filesize: 1.642.835|error
Ungültige Zeigeroperation

fill SimpleXML with 3.000.000 nodes, save into and load this from a file
create: 0   fill: 14.264   save: 7.752   free: 2.158   mem: 1.365mb
create: 0   load: 30.214   free: 2.969 
filesize: 312.777.833|315.777.834 

fill XMLLib with 3.000.000 nodes, save into and load this from a file
[color=silver]>>>> nach 'ner 1/2 Stunde abgebrochen, aber da wäre eh bald ein OutOfMemory gekommen[/color]
Garbage Collector ... Delphianer erzeugen keinen Müll, also brauchen sie auch keinen Müllsucher.
my Delphi wish list : BugReports/FeatureRequests
  Mit Zitat antworten Zitat