From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27496 invoked by alias); 4 Feb 2015 23:37:00 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 27473 invoked by uid 89); 4 Feb 2015 23:36:59 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.6 required=5.0 tests=AWL,BAYES_00,MSGID_MULTIPLE_AT autolearn=no version=3.3.2 X-HELO: mailhost.u-strasbg.fr Received: from mailhost.u-strasbg.fr (HELO mailhost.u-strasbg.fr) (130.79.222.211) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 04 Feb 2015 23:36:58 +0000 Received: from mailhost.u-strasbg.fr (localhost [127.0.0.1]) by antispam (Postfix) with ESMTP id CB7372208AF; Thu, 5 Feb 2015 00:36:54 +0100 (CET) Received: from mailhost.u-strasbg.fr (localhost [127.0.0.1]) by antivirus (Postfix) with ESMTP id B916C2208B2; Thu, 5 Feb 2015 00:36:54 +0100 (CET) Received: from lmr.u-strasbg.fr (lmr1.u-strasbg.fr [172.30.21.1]) by mr1.u-strasbg.fr (Postfix) with ESMTP id 7E03D2208AF; Thu, 5 Feb 2015 00:36:51 +0100 (CET) Received: from lmr.u-strasbg.fr (localhost [127.0.0.1]) by antivirus (Postfix) with ESMTP id 3F469EA; Thu, 5 Feb 2015 00:36:51 +0100 (CET) Received: from E6510Muller (lec67-4-82-230-53-140.fbx.proxad.net [82.230.53.140]) (Authenticated sender: mullerp) by lmr1.u-strasbg.fr (Postfix) with ESMTPSA id 6EDC59C; Thu, 5 Feb 2015 00:36:47 +0100 (CET) From: "Pierre Muller" To: "'Pedro Alves'" , "'Doug Evans'" Cc: "'gdb-patches'" References: <54ae4586.01e3440a.7b06.fffff844SMTPIN_ADDED_BROKEN@mx.google.com> <54AE605A.8050308@redhat.com> <54ae7f9f.c323460a.36ed.ffffff30SMTPIN_ADDED_BROKEN@mx.google.com> <54AE8914.4010507@redhat.com> <54ae911b.85e3440a.1d96.5ffdSMTPIN_ADDED_BROKEN@mx.google.com> <54AFB2E5.5080307@redhat.com> <001201d02c27$87cbee20$9763ca60$@muller@ics-cnrs.unistra.fr> In-Reply-To: <001201d02c27$87cbee20$9763ca60$@muller@ics-cnrs.unistra.fr> Subject: [RFA 0/3 V4] Fix pascal behavior for class fields with testcase Date: Wed, 04 Feb 2015 23:37:00 -0000 Message-ID: <002d01d040d3$72ddccc0$58996640$@muller@ics-cnrs.unistra.fr> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-SW-Source: 2015-02/txt/msg00110.txt.bz2 Hi all, this is a new round of my patch series to treat fields of this like any other variable in the pascal parser. Pierre Muller as pascal language maintainer. PS: I got problem to test my series because I get an internal-error with stabs generated debug information: Doug, I suspect this is due to the series you committed Re: [PATCH 0/5] Remove struct main_type.vptr_{fieldno,basetype} $ ../gdb --args ../gdb ./gdb.pascal/case-insensitive-symbols ......... (top-gdb) run Breakpoint 1, internal_error (file=0x7f5fcc "../../../binutils-gdb/gdb/gdbtypes.c", line=1204, fmt=0x7f5f9e "%s: Assertion `%s' failed.") at ../../../binutils-gdb/gdb/common/errors.c:54 54 va_start (ap, fmt); (top-gdb) bt #0 internal_error (file=0x7f5fcc "../../../binutils-gdb/gdb/gdbtypes.c", line=1204, fmt=0x7f5f9e "%s: Assertion `%s' failed.") at ../../../binutils-gdb/gdb/common/errors.c:54 #1 0x00570b43 in internal_type_self_type (type=0x801b1628) at ../../../binutils-gdb/gdb/gdbtypes.c:1204 #2 0x005e31a3 in read_member_functions (fip=0x2c2a354, pp=0x2c2a4c0, type=0x801b1540, objfile=0x8014baa0) at ../../../binutils-gdb/gdb/stabsread.c:2389 #3 0x005e5c1d in read_struct_type (pp=0x2c2a4c0, type=0x801b1540, type_code=TYPE_CODE_STRUCT, objfile=0x8014baa0) at ../../../binutils-gdb/gdb/stabsread.c:3555 #4 0x005e23c7 in read_type (pp=0x2c2a4c0, objfile=0x8014baa0) at ../../../binutils-gdb/gdb/stabsread.c:2006 #5 0x005e0b16 in define_symbol (valu=0, string=0x801a6ebc "TOBJECT:Tt15=s4$vf15:14,0;CREATE::17=##16;:__ct__7TOBJECT7POINTER;2A.;DESTR OY::18=##3;:__dt__7TOBJECT7POINTER;2A*0;15;;NEWINSTANCE::19=##16;:11unnamedt ype;2A*1;15;;FREEINSTANCE::20=##3;:7TOBJECT;2A*2;"..., desc=0, type=128, objfile=0x8014baa0) at ../../../binutils-gdb/gdb/stabsread.c:1316 #6 0x005ac0f6 in process_one_symbol (type=128, desc=0, valu=0, name=0x801a6ebc "TOBJECT:Tt15=s4$vf15:14,0;CREATE::17=##16;:__ct__7TOBJECT7POINTER;2A.;DESTR OY::18=##3;:__dt__7TOBJECT7POINTER;2A*0;15;;NEWINSTANCE::19=##16;:11unnamedt ype;2A*1;15;;FREEINSTANCE::20=##3;:7TOBJECT;2A*2;"..., section_offsets=0x8015ba88, objfile=0x8014baa0) at ../../../binutils-gdb/gdb/dbxread.c:3217 #7 0x005ab00d in read_ofile_symtab (objfile=0x8014baa0, pst=0x801a7c00) at ../../../binutils-gdb/gdb/dbxread.c:2601 #8 0x005aaa85 in dbx_psymtab_to_symtab_1 (objfile=0x8014baa0, pst=0x801a7c00) at ../../../binutils-gdb/gdb/dbxread.c:2418 #9 0x005aabbc in dbx_read_symtab (self=0x801a7c00, objfile=0x8014baa0) at ../../../binutils-gdb/gdb/dbxread.c:2471 #10 0x0051fb16 in psymtab_to_symtab (objfile=0x8014baa0, pst=0x801a7c00) at ../../../binutils-gdb/gdb/psymtab.c:788 #11 0x0051f3a3 in psym_lookup_symbol (objfile=0x8014baa0, block_index=0, name=0x8003ba88 "main", domain=VAR_DOMAIN) at ../../../binutils-gdb/gdb/psymtab.c:520 #12 0x00518210 in lookup_symbol_via_quick_fns (objfile=0x8014baa0, block_index=0, name=0x8003ba88 "main", domain=VAR_DOMAIN) at ../../../binutils-gdb/gdb/symtab.c:2436 #13 0x00518558 in lookup_symbol_in_objfile (objfile=0x8014baa0, block_index=0, name=0x8003ba88 "main", domain=VAR_DOMAIN) at ../../../binutils-gdb/gdb/symtab.c:2604 #14 0x0051872f in lookup_symbol_global_iterator_cb (objfile=0x8014baa0, cb_data=0x2c2a888) at ../../../binutils-gdb/gdb/symtab.c:2685 #15 0x0041bda5 in windows_iterate_over_objfiles_in_search_order (gdbarch=0x8014a3a8, cb=0x5186bf , cb_data=0x2c2a888, current_objfile=0x0) at ../../../binutils-gdb/gdb/windows-tdep.c:452 #16 0x0056c62c in gdbarch_iterate_over_objfiles_in_search_order (gdbarch=0x8014a3a8, cb=0x5186bf , cb_data=0x2c2a888, current_objfile=0x0) at ../../../binutils-gdb/gdb/gdbarch.c:4412 #17 0x00518847 in lookup_global_symbol (name=0x8003ba88 "main", block=0x0, domain=VAR_DOMAIN) at ../../../binutils-gdb/gdb/symtab.c:2730 #18 0x00518386 in basic_lookup_symbol_nonlocal (langdef=0x81cf80 , name=0x8003ba88 "main", block=0x0, domain=VAR_DOMAIN) at ../../../binutils-gdb/gdb/symtab.c:2530 #19 0x00517b46 in lookup_symbol_aux (name=0x8003ba88 "main", block=0x0, domain=VAR_DOMAIN, language=language_c, is_a_field_of_this=0x0) at ../../../binutils-gdb/gdb/symtab.c:2148 #20 0x00517501 in lookup_symbol_in_language (name=0x8003ba88 "main", block=0x0, domain=VAR_DOMAIN, lang=language_c, is_a_field_of_this=0x0) at ../../../binutils-gdb/gdb/symtab.c:1944 #21 0x00517546 in lookup_symbol (name=0x8003ba88 "main", block=0x0, domain=VAR_DOMAIN, is_a_field_of_this=0x0) at ../../../binutils-gdb/gdb/symtab.c:1958 #22 0x00524cee in set_initial_language () at ../../../binutils-gdb/gdb/symfile.c:1698 #23 0x005243bf in symbol_file_add_main_1 (args=0x2c2ac49 "./gdb.pascal/case-insensitive-symbols", from_tty=1, flags=0) at ../../../binutils-gdb/gdb/symfile.c:1327 #24 0x00524360 in symbol_file_add_main (args=0x2c2ac49 "./gdb.pascal/case-insensitive-symbols", from_tty=1) at ../../../binutils-gdb/gdb/symfile.c:1311 #25 0x00556ac9 in catch_command_errors_const (command=0x524340 , arg=0x2c2ac49 "./gdb.pascal/case-insensitive-symbols", from_tty=1, mask=RETURN_MASK_ALL) at ../../../binutils-gdb/gdb/main.c:396 #26 0x0055799a in captured_main (data=0x2c2abc4) at ../../../binutils-gdb/gdb/main.c:1042 #27 0x00552c81 in catch_errors (func=0x556d1a , func_args=0x2c2abc4, errstring=0x7eb761 <__PRETTY_FUNCTION__.13998+168> "", mask=RETURN_MASK_ALL) at ../../../binutils-gdb/gdb/exceptions.c:237 #28 0x00557d2f in gdb_main (args=0x2c2abc4) at ../../../binutils-gdb/gdb/main.c:1157 #29 0x0040120c in main ( During symbol reading, incomplete CFI data; DW_CFA_restore unspecified register ebx (#3) at 0x6100776e. argc=2, argv=0x2c2abfc) at ../../../binutils-gdb/gdb/gdb.c:32 (top-gdb) f 1 #1 0x00570b43 in internal_type_self_type (type=0x801b1628) at ../../../binutils-gdb/gdb/gdbtypes.c:1204 1204 gdb_assert (TYPE_SPECIFIC_FIELD (type) == TYPE_SPECIFIC_FUNC); (top-gdb) p *type.main_type $1 = {code = TYPE_CODE_METHOD, flag_unsigned = 0, flag_nosign = 0, flag_stub = 1, flag_target_stub = 0, flag_static = 0, flag_prototyped = 0, flag_incomplete = 0, flag_varargs = 0, flag_vector = 0, flag_stub_supported = 0, flag_gnu_ifunc = 0, flag_fixed_instance = 0, flag_objfile_owned = 1, flag_declared_class = 0, flag_flag_enum = 0, type_specific_field = TYPE_SPECIFIC_NONE, nfields = 0, name = 0x0, tag_name = 0x0, owner = {objfile = 0x8014baa0, gdbarch = 0x8014baa0}, target_type = 0x801b15e8, flds_bnds = {fields = 0x0, bounds = 0x0}, type_specific = {cplus_stuff = 0x0, gnat_stuff = 0x0, floatformat = 0x0, func_stuff = 0x0, self_type = 0x0}, data_location = 0x0} No calls to set_type_self_type up to this error point. TOBJECT is the fundamental class type for Free Pascal, and this code had no problems before.