Re: [xml] Memory error.
- From: "William M. Brack" <wbrack mmm com hk>
- To: xml gnome org
- Cc: Òþøèí Âàäèì <tva forsys ru>
- Subject: Re: [xml] Memory error.
- Date: Sat, 7 Feb 2004 16:46:57 +0800 (HKT)
William M. Brack said:
Òþøèí Âàäèì \(forsys\) said:
Greeting.
I have found a memory trouble while parsing xml document in a BIG
cycle.
Please, try to compile and run the attached program setting
different cycle values.
The more value will be set to the cycle counter, the more memory
will be eaten away by this program.
By the way: under HP-UX setting cycle counter to 100000 or higher
will cause program to fall into 'core dump'.
Problem was found under version 2.6.2. I tryed 2.6.5 - problem
exists.
By the way: under version 2.5.6 this bug does not exist.
With respect. Tyushin Vadim
tva forsys ru
I compiled your program on my AMD MP2000+ system and ran it with the
libxml2 "memcheck" feature, as well as under the memory checking
program "valgrind". There are *no* memory leaks (except for the
allocation of an encoding handler, which would be released if
xmlCleanupParser were called), including setting the cycle count up
to 1,000,000. Unfortunately, it's getting past my bedtime now, but
tomorrow I will port everything over to my testing account on an
HP-UX system and see if I can uncover anything there.
I uploaded the released version 2.6.5 of libxml2 library together
with your program onto an HP system. Unfortunately the iconv
library on that system had some problems, so I needed to remove the
encoding declaration from your program. There were no problems,
including a run of 5,000,000 cycles. System info:
wbrack spe176 work $ uname -a
HP-UX spe176 B.11.23 U ia64 1437274693 unlimited-user license
wbrack spe176 work $ gcc -v
Reading specs from /usr/local/lib/gcc-lib/ia64-hp-hpux11.23/3.3.2/specs
Configured with:
/scratch/zack/gcc/pkg/3.3.1/hpux-11/gcc-3.3.2/configure
--enable-languages=c,c++ --enable-threads=posix --with-gnu-as
--without-gnu-ld --with-as=/usr/local/bin/as --prefix=/usr/local
Thread model: posix
gcc version 3.3.2
Program run:
wbrack spe176 work $ ./test_libxml 5000000
Message (length 70):
<?xml version="1.0"?>
<ftvml version="1.2" command_id="1201">
</ftvml>
imax = 5000000
Press <Enter> to exit.
"Top" info at end of run:
CPU USERNAME PRI NI SIZE RES TIME %WCPU %CPU COMMAND
0 wbrack 154 20 7372K 488K 1:47 57.12 56.97 test_lib
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]