>gpc --version 20011222, based on gcc-2.95.3 20010315 (release) >gpc -g head.pas >cat head.pas Program Head; (* No "Output" specification needed. *) begin writeln ( 'OK' ); end. >valgrind --tool=memcheck ./a.out ==4451== Memcheck, a memory error detector for x86-linux. ==4451== Copyright (C) 2002-2004, and GNU GPL'd, by Julian Seward et al. ==4451== Using valgrind-2.2.0, a program supervision framework for x86-linux. ==4451== Copyright (C) 2000-2004, and GNU GPL'd, by Julian Seward et al. @@ unlikely looking definition in unparsed remains ";" @@ expected ',' at struct TYPE (remains=",0,8;Timevalid:(0,23),8,8;Year:(0,1), 32,32;Month:(0,24)=r(0,1);0000000000001;0000000000014;,64,32;Day:(0,25)=r(0,1); 0000000000001;0000000000037;,96,32;Dayofweek:(0,26)=r(0,1);0000000000000; 0000000000006;,128,32;Hour:(0,27)=r(0,1);0000000000000;0000000000027;,160,32; Minute:(0,28)=r(0,1);0000000000000;0000000000073;,192,32;Second:(0,29)=r(0,1); 0000000000000;0000000000075;,224,32;Microsecond:(0,30)=r(0,1);0000000000000; 0000003641077;,256,32;Timezone:(0,1),288,32;Dst:(0,23),320,8;Tzname1:(0,31) =s44Capacity:(0,4),0,32;length:(0,4),32,32;_p_schema_:(0,32)=@s264;@S;S(0,33) =r(0,1);0000000000001;0000000000041;,64,264;;,352,352;Tzname2:(0,34) =s44Capacity:(0,4),0,32;length:(0,4),32,32;_p_schema_:(0,35)=@s264;@S;S(0,33), 64,264;;,704,352;;") @@ parsing (0,22)=s132Datevalid:(0,23)=@s8;-16;,0,8;Timevalid:(0,23),8,8;Year: (0,1),32,32;Month:(0,24)=r(0,1);0000000000001;0000000000014;,64,32;Day:(0,25) =r(0,1);0000000000001;0000000000037;,96,32;Dayofweek:(0,26)=r(0,1); 0000000000000;0000000000006;,128,32;Hour:(0,27)=r(0,1);0000000000000; 0000000000027;,160,32;Minute:(0,28)=r(0,1);0000000000000;0000000000073;,192,32; Second:(0,29)=r(0,1);0000000000000;0000000000075;,224,32;Microsecond:(0,30)=r(0, 1);0000000000000;0000003641077;,256,32;Timezone:(0,1),288,32;Dst:(0,23),320,8; Tzname1:(0,31)=s44Capacity:(0,4),0,32;length:(0,4),32,32;_p_schema_:(0,32) =@s264;@S;S(0,33)=r(0,1);0000000000001;0000000000041;,64,264;;,352,352;Tzname2: (0,34)=s44Capacity:(0,4),0,32;length:(0,4),32,32;_p_schema_:(0,35)=@s264;@S;S(0, 33),64,264;;,704,352;; gave NULL type (s132Datevalid:(0,23)=@s8;-16;,0,8; Timevalid:(0,23),8,8;Year:(0,1),32,32;Month:(0,24)=r(0,1);0000000000001; 0000000000014;,64,32;Day:(0,25)=r(0,1);0000000000001;0000000000037;,96,32; Dayofweek:(0,26)=r(0,1);0000000000000;0000000000006;,128,32;Hour:(0,27)=r(0,1); 0000000000000;0000000000027;,160,32;Minute:(0,28)=r(0,1);0000000000000; 0000000000073;,192,32;Second:(0,29)=r(0,1);0000000000000;0000000000075;,224,32; Microsecond:(0,30)=r(0,1);0000000000000;0000003641077;,256,32;Timezone:(0,1), 288,32;Dst:(0,23),320,8;Tzname1:(0,31)=s44Capacity:(0,4),0,32;length:(0,4),32, 32;_p_schema_:(0,32)=@s264;@S;S(0,33)=r(0,1);0000000000001;0000000000041;,64, 264;;,352,352;Tzname2:(0,34)=s44Capacity:(0,4),0,32;length:(0,4),32,32; _p_schema_:(0,35)=@s264;@S;S(0,33),64,264;;,704,352;; remains) Segmentation fault >valgrind --tool=addrcheck ./a.out (similar to above) >>valgrind --tool=none ./a.out (similar to above)
Patrick, is this still a problem with Valgrind 2.4.0 or the code from the 3.0 repository? Several stabs-related fixes have gone in since 2.2.0.
Hi Nicholas, Thanks for getting back to me. Answers merged below On Monday 18 July 2005 09:21 pm, you wrote: [bugs.kde.org quoted mail] I have downloaded and built 2.4.0. Every pascal program that I try gives approximately the following: valgrind `which drtest` ==14998== Memcheck, a memory error detector for x86-linux. ==14998== Copyright (C) 2002-2005, and GNU GPL'd, by Julian Seward et al. ==14998== Using valgrind-2.4.0, a program supervision framework for x86-linux. ==14998== Copyright (C) 2000-2005, and GNU GPL'd, by Julian Seward et al. @@ don't know what type 'd' is @@ parsing d(0,2) gave NULL type ((0,2) remains) @@ parsing (0,50)=d(0,2) gave NULL type ((0,2) remains) Segmentation fault where: valgrind --version valgrind-2.4.0 gpc --version 20011222, based on gcc-2.95.3 20010315 (release) or the code > from the 3.0 repository? I do not know what "3.0 repository" refers to. >Several stabs-related fixes have gone in since > 2.2.0. Hope this helps. If this information is insufficient, write back and I will try harder. Thanks again for working on this. -- Pat
Created attachment 11852 [details] Patch to dix parsing of d descriptor in stabs At least valgrind 2.4 is producing a more helpful error message... The problem is the 'd' descriptor which is something only pascal uses - it indicates a file of records of some type. Can you try this patch please - hopefully it will fix the problem.
Hi Tom, It works! I tried it on several pascal programs. Even found an uninitialized variable or two. Thanks a lot. -- Pat On Tuesday 19 July 2005 10:57 am, you wrote: [bugs.kde.org quoted mail]
Thanks for confirming that. I have committed the fix to the 3.0 SVN repository.