From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM11-BN8-obe.outbound.protection.outlook.com (mail-bn8nam11on2046.outbound.protection.outlook.com [40.107.236.46]) by sourceware.org (Postfix) with ESMTPS id D1BB1383E81A for ; Sun, 10 May 2020 19:25:04 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org D1BB1383E81A Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=amd.com Authentication-Results: sourceware.org; spf=none smtp.mailfrom=AlokKumar.Sharma@amd.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XqWIAqm6MUWRhMY5IbdZpmUFr4aVkBxdQhrDmZdVCGyOJuTP3JYrE5Or02NHtfN5b1EPoF+ehG403OKdbHPPAT/VGVGm+12/gZkY+ncl6vSvft0h5df55MvsKzJ9hTcaBJTHkB33gEqr1s264n/zO5vinLse4ePxsAImsNPmVhHaLSBPq3Vasg9pfEr0LPkmbUnsW1alpaZOoG7MRk7kaNDFFuUvbAOq44h4w4YQ6MHpPdvmd5jht27NCvNgMSF8Bve/WCUUodtGh4I2qCN+TRjPoR4KL2C14nMFwto1D7CBidsI0GD3kmrb/8yZGdsDLUPu4cWb31ZoFf4++v1MHQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=d8lqO8ubBUCqisbLmKM1IwOkU8pBO2/1eeJrks62hBw=; b=YT2ae3cqU6j9vgZW8ZUVHMcjdN9pL13jd9BmhHMT9JbnuOfpsAJubiEVnKKuPC0rkd4VD+VNU8O/50+w+jR9Ux06TYhlxobEGUpUnMH+oenlqUyFPpyZmTtGjkeFem4oqwUkL1lPHa+XpSgT0VweqGMBwKMTm6trs2nEyfqUyUr4EWuzhlFgiMz8DpAQoFlLJZJwBwfZ4tSVYCLw64sihwhW6kxVYOf15fKuDBb4eEzlds/FToTYrshPVimifER1BbtCYWaKDFqtGqXVUfg1Ruc7mN4sPIizA6fOtHiPwQFKQvqJyYE/a2iWAntalpKLUH3Y4g3C+bWNu4WOfKMimw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector2-amdcloud-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=d8lqO8ubBUCqisbLmKM1IwOkU8pBO2/1eeJrks62hBw=; b=NTe5fJ0XwLvEZr795CrtxiHTKcEzbhw2OiRnDXlmjs3TeZi28p39P16f4yQLxs4dEQIHEhfQBHbPUnlEnHfGnfK2W+alWjR5kZuiszj+Sxo0ySB7BNKtmr/1NKMgNmH6s5WpXjlSqs8coVualWKLuLjErRRUfCLqLTveN/JMSbw= Received: from BY5PR12MB3859.namprd12.prod.outlook.com (2603:10b6:a03:1a8::31) by BY5PR12MB3649.namprd12.prod.outlook.com (2603:10b6:a03:1ad::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2979.34; Sun, 10 May 2020 19:24:59 +0000 Received: from BY5PR12MB3859.namprd12.prod.outlook.com ([fe80::2591:731d:e067:9483]) by BY5PR12MB3859.namprd12.prod.outlook.com ([fe80::2591:731d:e067:9483%7]) with mapi id 15.20.2979.033; Sun, 10 May 2020 19:24:59 +0000 From: "Sharma, Alok Kumar" To: Andrew Burgess CC: Tom Tromey , "George, Jini Susan" , "Achra, Nitika" , "gdb-patches@sourceware.org" Subject: RE: [PATCH] gdb/fortran: Allow Flang MAIN_ in Fortran testing Thread-Topic: [PATCH] gdb/fortran: Allow Flang MAIN_ in Fortran testing Thread-Index: AdYaGoxVOtBbfA8rTdieLXSAzB7KHQABxBoAAAWJSrkAAXKNAAAAbW7wAI0EZQAAEo/YUABSSJGAAilE5zAAFTExoA== Date: Sun, 10 May 2020 19:24:58 +0000 Message-ID: References: <20200424101752.GB3522@embecosm.com> <87sggthwk2.fsf@tromey.com> <20200424133750.GD3522@embecosm.com> <20200427090750.GE3522@embecosm.com> <20200429091521.GJ3522@embecosm.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_Enabled=true; MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_SetDate=2020-05-10T09:19:19Z; MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_Method=Privileged; MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_Name=Non-Business; MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d; MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_ActionId=30933c67-ca90-483c-815a-0000835a0cd5; MSIP_Label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_ContentBits=0 msip_label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_enabled: true msip_label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_setdate: 2020-05-10T19:24:53Z msip_label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_method: Privileged msip_label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_name: Non-Business msip_label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_siteid: 3dd8961f-e488-4e60-8e11-a82d994e183d msip_label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_actionid: 5fb0b5a9-108c-452e-b7da-0000f52b7bec msip_label_f2ed062d-8486-4f50-a4f1-3cce0dd00d64_contentbits: 0 authentication-results: embecosm.com; dkim=none (message not signed) header.d=none;embecosm.com; dmarc=none action=none header.from=amd.com; x-originating-ip: [2409:4071:2096:7ec6:c449:2148:aee7:7a] x-ms-publictraffictype: Email x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: 540029b7-eddf-4d47-8eba-08d7f517d464 x-ms-traffictypediagnostic: BY5PR12MB3649:|BY5PR12MB3649: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:10000; x-forefront-prvs: 039975700A x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: hBcVenaohjcENFUjLcwEH0xP8tCR7znI0TPQiHzodPPFas/OT28L+BLWwVGjIAIgUyCZOsPERZDg6zUsOC+lA9+212AKiwymYaRCLpagCQxJZTUPLhBzvCPwCYFNMvjRGpsPsr2nD2vmm0aLirpzRB2rj8wko5buBNcDMF9NEsq5SI7l/GdQAHAYLrSq/ED5yrhElmNiUpbjQnoz1ximjC8ye+muGZoMJm5AuGKTRA5Ev6FFDDJywl6sMrbQz43eOgiACX2qFqMgvr8maqigqHNWglJove8zj69hS0WN1PFiJ35NhcBFovBy2T4mqrPyjD4aYJ/w8wDPflmJkiCRGve9VkpEeoL/cdE2O7gsfoq4FBOGWif+JPBeTFQAtvToyE74BFUTA9mgx85TM7eozHCbmR4UDKN9wVwrxyxEoQsU0dqU686LYUOA2kgdhsoVaK+qu0y5OlY+jYU2aDScGmtnCIWaQnac+f4an7hkiOkOg2cK52i684TZC2kFMxO141W51JA46X6LvRhrxx1uHI8rezE2UWwRNZDHkoedy4r+NK1CNNH8eFoZa8M8dAhzvobk8bMyKQErpl8iTfZ0TTCdMm6FEJf5ZLt5OrDRnTU= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BY5PR12MB3859.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFTY:; SFS:(4636009)(366004)(346002)(396003)(39860400002)(376002)(136003)(33430700001)(2940100002)(6506007)(76116006)(64756008)(66446008)(4326008)(66556008)(66946007)(66476007)(6916009)(30864003)(9686003)(8936002)(53546011)(7696005)(33656002)(5660300002)(55016002)(52536014)(186003)(8676002)(478600001)(71200400001)(316002)(86362001)(33440700001)(2906002)(54906003)(559001)(579004); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata: 3J7bbBfVJfFEnhUKTN98T6c+YW80s6AgLC7ChS0GOeZGkPdzL/Y+hpM1K/KwVC8KXvEBY4cNREpWCFS0aZllzDJzl5pGFFOOtCo0VuoKIoJVJbK5mn7iL8c1RhxEMXOE/7C9ePvgQaVDVg6ZpNRANgrbuds5o+ZRQywIhvHtRlYqxjpFRoucRWa3QvaU1ZvbaTb5Vuh3JnbUWhv3fr7NhQdNmkWtXt0jjE3um95nVTRewc6AZWW5Lq4Qp4GcfWwkiJqVwzPajeKGPe2lfb5Pa1XuhrUqAiO9fMAdMHj7mg9hSxbRD5SZswqM5rL+R6Udvrnzqa5GVkSDodbe0SbchBIKsVoteSt9psSdax15kCbkK5XvD63S1RW5lsEf/ndamD60L+OrjcOHPaK/zWVTfrcJycNJoWzxfkRfmFNmLVr35HGBbUVV8hotSqkFIaYQoJv8Ab/zgPk8CHpbsdETJiiq7cfbxNj4JSnI8jonHh+Y5vC2EHKWnUYZ4Vcon1zG0/iW97u5TvaA8g3kk5Wyt6RZQNKEojmRxtGl8/zMwmA= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 540029b7-eddf-4d47-8eba-08d7f517d464 X-MS-Exchange-CrossTenant-originalarrivaltime: 10 May 2020 19:24:59.0098 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 2TB2yUU1xrlJWLbJWp+oWuxVEg3aVKSguc9jrahs2Z8dFbTZaU75R63pOEa8RjpOzv5BFE+iOGjNgqJAXDYPWw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY5PR12MB3649 X-Spam-Status: No, score=-10.3 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, FORGED_SPF_HELO, GIT_PATCH_0, KAM_LOTSOFHASH, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 May 2020 19:25:17 -0000 Just to inform, I just got back the access and pushed the changes. Thanks. Regards, Alok -----Original Message----- From: Sharma, Alok Kumar=20 Sent: Sunday, May 10, 2020 2:52 PM To: Andrew Burgess Cc: Tom Tromey ; George, Jini Susan ; Achra, Nitika ; gdb-patches@sourceware.org Subject: RE: [PATCH] gdb/fortran: Allow Flang MAIN_ in Fortran testing Thanks a lot Andrew for your comments. Please find the updated patch with y= our comments incorporated. As I lost my ssh setup and yet to get new one updated on server, I am unabl= e to commit currently. I would like to request if someone please commit this? gdb/testsuite/ChangeLog * lib/fortran.exp (fortran_main): New Proc, handle flang MAIN_, (fortran_runto_main): New Proc, fortran version of runto_main. * gdb.fortran/array-bounds-high.exp: Handle flang MAIN_. * gdb.fortran/array-bounds.exp: Likewise. * gdb.fortran/array-slices.exp: Likewise. * gdb.fortran/block-data.exp: Likewise. * gdb.fortran/charset.exp: Likewise. * gdb.fortran/common-block.exp: Likewise. * gdb.fortran/complex.exp: Likewise. * gdb.fortran/derived-type-function.exp: Likewise. * gdb.fortran/derived-type.exp: Likewise. * gdb.fortran/info-modules.exp: Likewise. * gdb.fortran/info-types.exp: Likewise. * gdb.fortran/intrinsics.exp: Likewise. * gdb.fortran/library-module.exp: Likewise. * gdb.fortran/logical.exp: Likewise. * gdb.fortran/max-depth.exp: Likewise. * gdb.fortran/module.exp: Likewise. * gdb.fortran/multi-dim.exp: Likewise. * gdb.fortran/nested-funcs.exp: Likewise. * gdb.fortran/print-formatted.exp: Likewise. * gdb.fortran/print_type.exp: Likewise. * gdb.fortran/printing-types.exp: Likewise. * gdb.fortran/ptr-indentation.exp: Likewise. * gdb.fortran/ptype-on-functions.exp: Likewise. * gdb.fortran/subarray.exp: Likewise. * gdb.fortran/vla-alloc-assoc.exp: Likewise. * gdb.fortran/vla-datatypes.exp: Likewise. * gdb.fortran/vla-history.exp: Likewise. * gdb.fortran/vla-ptr-info.exp: Likewise. * gdb.fortran/vla-ptype-sub.exp: Likewise. * gdb.fortran/vla-ptype.exp: Likewise. * gdb.fortran/vla-sizeof.exp: Likewise. * gdb.fortran/vla-type.exp: Likewise. * gdb.fortran/vla-value-sub-arbitrary.exp: Likewise. * gdb.fortran/vla-value-sub-finish.exp: Likewise. * gdb.fortran/vla-value-sub.exp: Likewise. * gdb.fortran/vla-value.exp: Likewise. * gdb.fortran/whatis_type.exp: Likewise. * gdb.mi/mi-var-child-f.exp: Likewise. Regards, Alok -----Original Message----- From: Andrew Burgess Sent: Wednesday, April 29, 2020 2:45 PM To: Sharma, Alok Kumar Cc: Tom Tromey ; George, Jini Susan ; Achra, Nitika ; gdb-patches@sourceware.org Subject: Re: [PATCH] gdb/fortran: Allow Flang MAIN_ in Fortran testing [CAUTION: External Email] * Sharma, Alok Kumar [2020-04-27 18:02:03 +0000]= : > Hi Andrew, > > Thanks a lot for your valuable comments. Please have a look at the=20 > updated patch in attachment. > > > > From 75e55e41ddc83ee3db6879fd955baf31d1301ba4 Mon Sep 17 00:00:00 2001 > From: Alok Kumar Sharma > Date: Fri, 24 Apr 2020 14:46:09 +0530 > Subject: [PATCH] gdb/fortran: Allow Flang MAIN_ in Fortran testing > > Name of fortran main function for Flang compiler is MAIN_ while for=20 > gfortran it is MAIN__ . In test cases MAIN__ is hardcoded for the=20 > purpose of inserting breakpoint. > > New proc is added to detect main function name depending on the=20 > compiler used. > Fortran specific version of runto_main named fortran_runto_main is=20 > added. > > This commit adds support for Flang main function, there should be no=20 > change for gfortran. This looks great. Please go ahead an commit it. I did have one minor last= fix, but don't feel you know you need to repost the patch, just update and= merge. > > gdb/testsuite/ChangeLog > > * lib/fortran.exp (fortran_main): New Proc, handle flang MAIN_, > (fortran_runto_main): New Proc, fortran version of runto_main. > * gdb.fortran/array-bounds-high.exp: Handle flang MAIN_. > * gdb.fortran/array-bounds.exp: Likewise. > * gdb.fortran/array-slices.exp: Likewise. > * gdb.fortran/block-data.exp: Likewise. > * gdb.fortran/charset.exp: Likewise. > * gdb.fortran/common-block.exp: Likewise. > * gdb.fortran/complex.exp: Likewise. > * gdb.fortran/derived-type-function.exp: Likewise. > * gdb.fortran/derived-type.exp: Likewise. > * gdb.fortran/info-modules.exp: Likewise. > * gdb.fortran/info-types.exp: Likewise. > * gdb.fortran/intrinsics.exp: Likewise. > * gdb.fortran/library-module.exp: Likewise. > * gdb.fortran/logical.exp: Likewise. > * gdb.fortran/max-depth.exp: Likewise. > * gdb.fortran/module.exp: Likewise. > * gdb.fortran/multi-dim.exp: Likewise. > * gdb.fortran/nested-funcs.exp: Likewise. > * gdb.fortran/print-formatted.exp: Likewise. > * gdb.fortran/print_type.exp: Likewise. > * gdb.fortran/printing-types.exp: Likewise. > * gdb.fortran/ptr-indentation.exp: Likewise. > * gdb.fortran/ptype-on-functions.exp: Likewise. > * gdb.fortran/subarray.exp: Likewise. > * gdb.fortran/vla-alloc-assoc.exp: Likewise. > * gdb.fortran/vla-datatypes.exp: Likewise. > * gdb.fortran/vla-history.exp: Likewise. > * gdb.fortran/vla-ptr-info.exp: Likewise. > * gdb.fortran/vla-ptype-sub.exp: Likewise. > * gdb.fortran/vla-ptype.exp: Likewise. > * gdb.fortran/vla-sizeof.exp: Likewise. > * gdb.fortran/vla-type.exp: Likewise. > * gdb.fortran/vla-value-sub-arbitrary.exp: Likewise. > * gdb.fortran/vla-value-sub-finish.exp: Likewise. > * gdb.fortran/vla-value-sub.exp: Likewise. > * gdb.fortran/vla-value.exp: Likewise. > * gdb.fortran/whatis_type.exp: Likewise. > * gdb.mi/mi-var-child-f.exp: Likewise. > > Change-Id: I0a30f5dad684879b416f71d3d08c385c159325bf > --- > gdb/testsuite/ChangeLog | 43 +++++++++++++++++++ > .../gdb.fortran/array-bounds-high.exp | 5 ++- > gdb/testsuite/gdb.fortran/array-bounds.exp | 5 ++- > gdb/testsuite/gdb.fortran/array-slices.exp | 3 +- > gdb/testsuite/gdb.fortran/block-data.exp | 4 +- > gdb/testsuite/gdb.fortran/charset.exp | 6 ++- > gdb/testsuite/gdb.fortran/common-block.exp | 4 +- > gdb/testsuite/gdb.fortran/complex.exp | 5 ++- > .../gdb.fortran/derived-type-function.exp | 5 ++- > gdb/testsuite/gdb.fortran/derived-type.exp | 4 +- > gdb/testsuite/gdb.fortran/info-modules.exp | 4 +- > gdb/testsuite/gdb.fortran/info-types.exp | 4 +- > gdb/testsuite/gdb.fortran/intrinsics.exp | 4 +- > gdb/testsuite/gdb.fortran/library-module.exp | 5 ++- > gdb/testsuite/gdb.fortran/logical.exp | 5 ++- > gdb/testsuite/gdb.fortran/max-depth.exp | 4 +- > gdb/testsuite/gdb.fortran/module.exp | 6 +-- > gdb/testsuite/gdb.fortran/multi-dim.exp | 4 +- > gdb/testsuite/gdb.fortran/nested-funcs.exp | 4 +- > gdb/testsuite/gdb.fortran/print-formatted.exp | 4 +- > gdb/testsuite/gdb.fortran/print_type.exp | 2 +- > gdb/testsuite/gdb.fortran/printing-types.exp | 5 ++-=20 > gdb/testsuite/gdb.fortran/ptr-indentation.exp | 4 +- > .../gdb.fortran/ptype-on-functions.exp | 4 +- > gdb/testsuite/gdb.fortran/subarray.exp | 5 ++- > gdb/testsuite/gdb.fortran/vla-alloc-assoc.exp | 3 +- > gdb/testsuite/gdb.fortran/vla-datatypes.exp | 2 +- > gdb/testsuite/gdb.fortran/vla-history.exp | 3 +- > gdb/testsuite/gdb.fortran/vla-ptr-info.exp | 3 +- > gdb/testsuite/gdb.fortran/vla-ptype-sub.exp | 2 +- > gdb/testsuite/gdb.fortran/vla-ptype.exp | 2 +- > gdb/testsuite/gdb.fortran/vla-sizeof.exp | 3 +- > gdb/testsuite/gdb.fortran/vla-type.exp | 2 +- > .../gdb.fortran/vla-value-sub-arbitrary.exp | 3 +- > .../gdb.fortran/vla-value-sub-finish.exp | 3 +- > gdb/testsuite/gdb.fortran/vla-value-sub.exp | 3 +- > gdb/testsuite/gdb.fortran/vla-value.exp | 6 +-- > gdb/testsuite/gdb.fortran/whatis_type.exp | 4 +- > gdb/testsuite/gdb.mi/mi-var-child-f.exp | 2 +- > gdb/testsuite/lib/fortran.exp | 18 ++++++++ > 40 files changed, 143 insertions(+), 64 deletions(-) > > diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index > 10683db566..0e3c207f85 100644 > --- a/gdb/testsuite/ChangeLog > +++ b/gdb/testsuite/ChangeLog > @@ -1,3 +1,46 @@ > +2020-04-24 Alok Kumar Sharma > + > + * lib/fortran.exp (fortran_main): New Proc, handle flang MAIN_, > + (fortran_runto_main): New Proc, fortran version of runto_main. > + * gdb.fortran/array-bounds-high.exp: Handle flang MAIN_ > + * gdb.fortran/array-bounds.exp: Likewise. > + * gdb.fortran/array-slices.exp: Likewise. > + * gdb.fortran/block-data.exp: Likewise. > + * gdb.fortran/charset.exp: Likewise. > + * gdb.fortran/common-block.exp: Likewise. > + * gdb.fortran/complex.exp: Likewise. > + * gdb.fortran/derived-type-function.exp: Likewise. > + * gdb.fortran/derived-type.exp: Likewise. > + * gdb.fortran/info-modules.exp: Likewise. > + * gdb.fortran/info-types.exp: Likewise. > + * gdb.fortran/intrinsics.exp: Likewise. > + * gdb.fortran/library-module.exp: Likewise. > + * gdb.fortran/logical.exp: Likewise. > + * gdb.fortran/max-depth.exp: Likewise. > + * gdb.fortran/module.exp: Likewise. > + * gdb.fortran/multi-dim.exp: Likewise. > + * gdb.fortran/nested-funcs.exp: Likewise. > + * gdb.fortran/print-formatted.exp: Likewise. > + * gdb.fortran/print_type.exp: Likewise. > + * gdb.fortran/printing-types.exp: Likewise. > + * gdb.fortran/ptr-indentation.exp: Likewise. > + * gdb.fortran/ptype-on-functions.exp: Likewise. > + * gdb.fortran/subarray.exp: Likewise. > + * gdb.fortran/vla-alloc-assoc.exp: Likewise. > + * gdb.fortran/vla-datatypes.exp: Likewise. > + * gdb.fortran/vla-history.exp: Likewise. > + * gdb.fortran/vla-ptr-info.exp: Likewise. > + * gdb.fortran/vla-ptype-sub.exp: Likewise. > + * gdb.fortran/vla-ptype.exp: Likewise. > + * gdb.fortran/vla-sizeof.exp: Likewise. > + * gdb.fortran/vla-type.exp: Likewise. > + * gdb.fortran/vla-value-sub-arbitrary.exp: Likewise. > + * gdb.fortran/vla-value-sub-finish.exp: Likewise. > + * gdb.fortran/vla-value-sub.exp: Likewise. > + * gdb.fortran/vla-value.exp: Likewise. > + * gdb.fortran/whatis_type.exp: Likewise. > + * gdb.mi/mi-var-child-f.exp: Likewise. > + > 2020-04-23 Tom de Vries > > * gdb.base/decl-before-def.exp: Run to main and print a again. > diff --git a/gdb/testsuite/gdb.fortran/array-bounds-high.exp > b/gdb/testsuite/gdb.fortran/array-bounds-high.exp > index 81e2f87b89..ba34dbc23e 100644 > --- a/gdb/testsuite/gdb.fortran/array-bounds-high.exp > +++ b/gdb/testsuite/gdb.fortran/array-bounds-high.exp > @@ -20,13 +20,14 @@ if { [skip_fortran_tests] } { return -1 } > > set testfile "array-bounds-high" > standard_testfile .f90 > +load_lib fortran.exp > > if {[prepare_for_testing $testfile.exp $testfile $srcfile {f90 debug}]} = { > return -1 > } > > -if {![runto MAIN__]} { > - perror "Could not run to breakpoint `MAIN__'." > +if {![fortran_runto_main]} { > + perror "Could not run to main." > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/array-bounds.exp > b/gdb/testsuite/gdb.fortran/array-bounds.exp > index 12bf5c2db3..3f2527343b 100644 > --- a/gdb/testsuite/gdb.fortran/array-bounds.exp > +++ b/gdb/testsuite/gdb.fortran/array-bounds.exp > @@ -20,13 +20,14 @@ if { [skip_fortran_tests] } { return -1 } > > set testfile "array-bounds" > standard_testfile .f90 > +load_lib fortran.exp > > if {[prepare_for_testing $testfile.exp $testfile $srcfile {f90 debug}]} = { > return -1 > } > > -if {![runto MAIN__]} { > - perror "Could not run to breakpoint `MAIN__'." > +if {![fortran_runto_main]} { > + perror "Could not run to main." > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/array-slices.exp > b/gdb/testsuite/gdb.fortran/array-slices.exp > index 11997f926a..4ca1db90f7 100644 > --- a/gdb/testsuite/gdb.fortran/array-slices.exp > +++ b/gdb/testsuite/gdb.fortran/array-slices.exp > @@ -21,13 +21,14 @@ > if {[skip_fortran_tests]} { return -1 } > > standard_testfile ".f90" > +load_lib fortran.exp > > if {[prepare_for_testing ${testfile}.exp ${testfile} ${srcfile} \ > {debug f90}]} { > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/block-data.exp > b/gdb/testsuite/gdb.fortran/block-data.exp > index 292afe6c16..632c0141a3 100644 > --- a/gdb/testsuite/gdb.fortran/block-data.exp > +++ b/gdb/testsuite/gdb.fortran/block-data.exp > @@ -30,8 +30,8 @@ if {[prepare_for_testing $testfile.exp $testfile $srcfi= le {debug f90}]} { > return -1 > } > > -if ![runto MAIN__] then { > - untested "couldn't run to breakpoint MAIN__" > +if ![fortran_runto_main] then { > + untested "couldn't run to main" > return -1 > } > > diff --git a/gdb/testsuite/gdb.fortran/charset.exp > b/gdb/testsuite/gdb.fortran/charset.exp > index f0f62f8490..fc504ae0b0 100644 > --- a/gdb/testsuite/gdb.fortran/charset.exp > +++ b/gdb/testsuite/gdb.fortran/charset.exp > @@ -19,12 +19,14 @@ > if { [skip_fortran_tests] } { return -1 } > > standard_testfile .f90 > +load_lib fortran.exp > + > if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {de= bug additional_flags=3D-fbackslash f90}] } { > return -1 > } > > -if ![runto MAIN__] { > - perror "Couldn't run to MAIN__" > +if ![fortran_runto_main] { > + perror "Couldn't run to main" > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/common-block.exp > b/gdb/testsuite/gdb.fortran/common-block.exp > index 19c1af0d81..3dacfd32b2 100644 > --- a/gdb/testsuite/gdb.fortran/common-block.exp > +++ b/gdb/testsuite/gdb.fortran/common-block.exp > @@ -27,8 +27,8 @@ if {[prepare_for_testing "failed to prepare" ${testfile= } \ > return -1 > } > > -if ![runto MAIN__] then { > - perror "couldn't run to breakpoint MAIN__" > +if ![fortran_runto_main] then { > + perror "couldn't run to main" > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/complex.exp > b/gdb/testsuite/gdb.fortran/complex.exp > index c092ab29f1..a88e553e58 100644 > --- a/gdb/testsuite/gdb.fortran/complex.exp > +++ b/gdb/testsuite/gdb.fortran/complex.exp > @@ -14,13 +14,14 @@ > # along with this program. If not, see . > > standard_testfile .f90 > +load_lib fortran.exp > > if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug f= 90 quiet}]} { > return -1 > } > > -if ![runto MAIN__] then { > - perror "Couldn't run to MAIN__" > +if ![fortran_runto_main] then { > + perror "Couldn't run to main" > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/derived-type-function.exp > b/gdb/testsuite/gdb.fortran/derived-type-function.exp > index 1f0f957317..2ae6f46c1e 100644 > --- a/gdb/testsuite/gdb.fortran/derived-type-function.exp > +++ b/gdb/testsuite/gdb.fortran/derived-type-function.exp > @@ -21,13 +21,14 @@ > if { [skip_fortran_tests] } { return -1 } > > standard_testfile .f90 > +load_lib fortran.exp > > if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug f= 90}]} { > return -1 > } > > -if ![runto MAIN__] then { > - perror "couldn't run to breakpoint MAIN__" > +if ![fortran_runto_main] then { > + perror "couldn't run to main" > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/derived-type.exp > b/gdb/testsuite/gdb.fortran/derived-type.exp > index f1705bffd8..4b86ba97de 100644 > --- a/gdb/testsuite/gdb.fortran/derived-type.exp > +++ b/gdb/testsuite/gdb.fortran/derived-type.exp > @@ -27,8 +27,8 @@ if {[prepare_for_testing "failed to prepare" $testfile = $srcfile {debug f90}]} { > return -1 > } > > -if ![runto MAIN__] then { > - perror "couldn't run to breakpoint MAIN__" > +if ![fortran_runto_main] then { > + perror "couldn't run to main" > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/info-modules.exp > b/gdb/testsuite/gdb.fortran/info-modules.exp > index 0c3c6a58e1..a3a9b2cb18 100644 > --- a/gdb/testsuite/gdb.fortran/info-modules.exp > +++ b/gdb/testsuite/gdb.fortran/info-modules.exp > @@ -28,8 +28,8 @@ if { [prepare_for_testing "failed to prepare" $testfile= \ > return -1 > } > > -if { ![runto MAIN__] } { > - perror "Could not run to breakpoint `MAIN__'." > +if { ![fortran_runto_main] } { > + perror "Could not run to main." > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/info-types.exp > b/gdb/testsuite/gdb.fortran/info-types.exp > index 2138937782..e80c990a85 100644 > --- a/gdb/testsuite/gdb.fortran/info-types.exp > +++ b/gdb/testsuite/gdb.fortran/info-types.exp > @@ -27,8 +27,8 @@ if { [prepare_for_testing "failed to prepare" $testfile= \ > return -1 > } > > -if { ![runto MAIN__] } { > - perror "Could not run to breakpoint `MAIN__'." > +if { ![fortran_runto_main] } { > + perror "Could not run to main." > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/intrinsics.exp > b/gdb/testsuite/gdb.fortran/intrinsics.exp > index 504bce4138..2cb0237c95 100644 > --- a/gdb/testsuite/gdb.fortran/intrinsics.exp > +++ b/gdb/testsuite/gdb.fortran/intrinsics.exp > @@ -25,8 +25,8 @@ if { [prepare_for_testing "failed to prepare" $testfile= $srcfile {debug f90}] } > return -1 > } > > -if { ![runto MAIN__] } { > - perror "Could not run to breakpoint `MAIN__'." > +if { ![fortran_runto_main] } { > + perror "Could not run to main." > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/library-module.exp > b/gdb/testsuite/gdb.fortran/library-module.exp > index f25988e32c..8254fcf10a 100644 > --- a/gdb/testsuite/gdb.fortran/library-module.exp > +++ b/gdb/testsuite/gdb.fortran/library-module.exp > @@ -40,9 +40,10 @@ if { [gdb_compile $srcdir/$subdir/$srcfile=20 > $binfile executable [list debug f90 clean_restart $testfile > > gdb_load_shlib $libfile > +load_lib fortran.exp > > -if ![runto MAIN__] then { > - perror "couldn't run to breakpoint MAIN__" > +if ![fortran_runto_main] then { > + perror "couldn't run to main" > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/logical.exp > b/gdb/testsuite/gdb.fortran/logical.exp > index 324714fa49..161bbdd908 100644 > --- a/gdb/testsuite/gdb.fortran/logical.exp > +++ b/gdb/testsuite/gdb.fortran/logical.exp > @@ -16,13 +16,14 @@ > # This file was written by Jan Kratochvil . > > standard_testfile .f90 > +load_lib fortran.exp > > if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug f= 90 quiet}]} { > return -1 > } > > -if { ![runto MAIN__] } { > - perror "Could not run to breakpoint `MAIN__'." > +if { ![fortran_runto_main] } { > + perror "Could not run to main." > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/max-depth.exp > b/gdb/testsuite/gdb.fortran/max-depth.exp > index 262d0fdfa1..420b72539f 100644 > --- a/gdb/testsuite/gdb.fortran/max-depth.exp > +++ b/gdb/testsuite/gdb.fortran/max-depth.exp > @@ -26,8 +26,8 @@ if { [prepare_for_testing "failed to prepare" $testfile= $srcfile {debug f90}] } > return -1 > } > > -if { ![runto MAIN__] } { > - perror "Could not run to breakpoint `MAIN__'." > +if { ![fortran_runto_main] } { > + perror "Could not run to main." > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/module.exp > b/gdb/testsuite/gdb.fortran/module.exp > index 1c269e2fed..4a8251c44c 100644 > --- a/gdb/testsuite/gdb.fortran/module.exp > +++ b/gdb/testsuite/gdb.fortran/module.exp > @@ -29,8 +29,8 @@ gdb_test "p modmany::var_i" " =3D 14" "stopped language= detection" > > gdb_test "print mod1::var_const" " =3D 20" "fully qualified name of DW_T= AG_constant" > > -if ![runto MAIN__] then { > - perror "couldn't run to breakpoint MAIN__" > +if ![fortran_runto_main] then { > + perror "couldn't run to main" > continue > } > > @@ -123,7 +123,7 @@ complete "modmany::var" $modmany_list #=20 > Breakpoint would work in language "c". > gdb_test "show language" {The current source language is "(auto;=20 > currently )?fortran".} > > -# gcc-4.4.2: The main program is always MAIN__ in .symtab so "runto"=20 > above > +# gcc-4.4.2: The main program is always $fmain in .symtab so "runto"=20 > +above > # works. But DWARF DW_TAG_subprogram contains the name specified by=20 > # the "program" Fortran statement. > if [gdb_breakpoint "module"] { > diff --git a/gdb/testsuite/gdb.fortran/multi-dim.exp > b/gdb/testsuite/gdb.fortran/multi-dim.exp > index 05590914df..ef6c6da8bd 100644 > --- a/gdb/testsuite/gdb.fortran/multi-dim.exp > +++ b/gdb/testsuite/gdb.fortran/multi-dim.exp > @@ -25,8 +25,8 @@ if { [prepare_for_testing "failed to prepare" ${testfil= e} ${srcfile} {debug f90} > return -1 > } > > -if ![runto MAIN__] { > - perror "Couldn't run to MAIN__" > +if ![fortran_runto_main] { > + perror "Couldn't run to main" > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/nested-funcs.exp > b/gdb/testsuite/gdb.fortran/nested-funcs.exp > index e4fc02ffa5..9e0073d210 100755 > --- a/gdb/testsuite/gdb.fortran/nested-funcs.exp > +++ b/gdb/testsuite/gdb.fortran/nested-funcs.exp > @@ -25,8 +25,8 @@ if {[prepare_for_testing "failed to prepare" $testfile = $srcfile {debug f90}]} { > return -1 > } > > -if ![runto MAIN__] then { > - perror "couldn't run to breakpoint MAIN__" > +if ![fortran_runto_main] then { > + perror "couldn't run to main" > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/print-formatted.exp > b/gdb/testsuite/gdb.fortran/print-formatted.exp > index 8c6529ce7f..e71287724b 100644 > --- a/gdb/testsuite/gdb.fortran/print-formatted.exp > +++ b/gdb/testsuite/gdb.fortran/print-formatted.exp > @@ -25,8 +25,8 @@ if { [prepare_for_testing "failed to prepare" $testfile= $srcfile {debug f90}] } > return -1 > } > > -if { ![runto MAIN__] } { > - fail "runto MAIN__" > +if { ![fortran_runto_main] } { > + fail "could not run to main" > return -1 > } > > diff --git a/gdb/testsuite/gdb.fortran/print_type.exp > b/gdb/testsuite/gdb.fortran/print_type.exp > index 7d5915390d..fcedb9579a 100755 > --- a/gdb/testsuite/gdb.fortran/print_type.exp > +++ b/gdb/testsuite/gdb.fortran/print_type.exp > @@ -24,7 +24,7 @@ if { [prepare_for_testing ${testfile}.exp ${testfile} $= {srcfile} \ > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/printing-types.exp > b/gdb/testsuite/gdb.fortran/printing-types.exp > index 2c88f9e003..44fd93cc56 100644 > --- a/gdb/testsuite/gdb.fortran/printing-types.exp > +++ b/gdb/testsuite/gdb.fortran/printing-types.exp > @@ -16,13 +16,14 @@ > if {[skip_fortran_tests]} { return -1 } > > standard_testfile .f90 > +load_lib fortran.exp > > if {[prepare_for_testing $testfile.exp $testfile $srcfile {debug f90}]} = { > return -1 > } > > -if {![runto MAIN__]} then { > - untested "could not run to breakpoint MAIN__" > +if {![fortran_runto_main]} then { > + untested "could not run to main" > return -1 > } > > diff --git a/gdb/testsuite/gdb.fortran/ptr-indentation.exp > b/gdb/testsuite/gdb.fortran/ptr-indentation.exp > index 285e24e2cc..209809a292 100644 > --- a/gdb/testsuite/gdb.fortran/ptr-indentation.exp > +++ b/gdb/testsuite/gdb.fortran/ptr-indentation.exp > @@ -22,8 +22,8 @@ if {[prepare_for_testing $testfile.exp $testfile $srcfi= le {debug f90}]} { > return -1 > } > > -if {![runto MAIN__]} then { > - untested "couldn't run to breakpoint MAIN__" > +if {![fortran_runto_main]} then { > + untested "couldn't run to main" > return -1 > } > > diff --git a/gdb/testsuite/gdb.fortran/ptype-on-functions.exp > b/gdb/testsuite/gdb.fortran/ptype-on-functions.exp > index d91e4bd48e..8dc5f76d93 100644 > --- a/gdb/testsuite/gdb.fortran/ptype-on-functions.exp > +++ b/gdb/testsuite/gdb.fortran/ptype-on-functions.exp > @@ -24,8 +24,8 @@ if {[prepare_for_testing "failed to prepare" $testfile = $srcfile {debug f90}]} { > return -1 > } > > -if ![runto MAIN__] then { > - perror "couldn't run to breakpoint MAIN__" > +if ![fortran_runto_main] then { > + perror "couldn't run to main" > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/subarray.exp > b/gdb/testsuite/gdb.fortran/subarray.exp > index 5e3e8c38cb..9ee5a9b3cb 100644 > --- a/gdb/testsuite/gdb.fortran/subarray.exp > +++ b/gdb/testsuite/gdb.fortran/subarray.exp > @@ -21,6 +21,7 @@ > if { [skip_fortran_tests] } { return -1 } > > standard_testfile .f > +load_lib fortran.exp > > if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug f= 90}]} { > return -1 > @@ -31,8 +32,8 @@ gdb_start > gdb_reinitialize_dir $srcdir/$subdir > gdb_load ${binfile} > > -if ![runto MAIN__] then { > - perror "couldn't run to breakpoint MAIN__" > +if ![fortran_runto_main] then { > + perror "couldn't run to main" > continue > } > > diff --git a/gdb/testsuite/gdb.fortran/vla-alloc-assoc.exp > b/gdb/testsuite/gdb.fortran/vla-alloc-assoc.exp > index 5d8585c2ee..2ae0411cf1 100644 > --- a/gdb/testsuite/gdb.fortran/vla-alloc-assoc.exp > +++ b/gdb/testsuite/gdb.fortran/vla-alloc-assoc.exp > @@ -14,13 +14,14 @@ > # along with this program. If not, see . > > standard_testfile "vla.f90" > +load_lib fortran.exp > > if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ > {debug f90 quiet}] } { > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-datatypes.exp > b/gdb/testsuite/gdb.fortran/vla-datatypes.exp > index 2db9b3e110..b69636f600 100644 > --- a/gdb/testsuite/gdb.fortran/vla-datatypes.exp > +++ b/gdb/testsuite/gdb.fortran/vla-datatypes.exp > @@ -24,7 +24,7 @@ if { [prepare_for_testing "failed to prepare"=20 > ${testfile} ${srcfile} \ # check that all fortran standard datatypes=20 > will be # handled correctly when using as VLA's > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-history.exp > b/gdb/testsuite/gdb.fortran/vla-history.exp > index 24bd945f4a..3bf98db197 100644 > --- a/gdb/testsuite/gdb.fortran/vla-history.exp > +++ b/gdb/testsuite/gdb.fortran/vla-history.exp > @@ -14,13 +14,14 @@ > # along with this program. If not, see . > > standard_testfile "vla.f90" > +load_lib fortran.exp > > if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ > {debug f90 quiet}] } { > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-ptr-info.exp > b/gdb/testsuite/gdb.fortran/vla-ptr-info.exp > index 24c7b45840..d3fa595bea 100644 > --- a/gdb/testsuite/gdb.fortran/vla-ptr-info.exp > +++ b/gdb/testsuite/gdb.fortran/vla-ptr-info.exp > @@ -14,13 +14,14 @@ > # along with this program. If not, see . > > standard_testfile "vla.f90" > +load_lib fortran.exp > > if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ > {debug f90 quiet}] } { > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-ptype-sub.exp > b/gdb/testsuite/gdb.fortran/vla-ptype-sub.exp > index 09909e74b0..07a4a5fc2e 100644 > --- a/gdb/testsuite/gdb.fortran/vla-ptype-sub.exp > +++ b/gdb/testsuite/gdb.fortran/vla-ptype-sub.exp > @@ -21,7 +21,7 @@ if { [prepare_for_testing "failed to prepare" ${testfil= e} ${srcfile} \ > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-ptype.exp > b/gdb/testsuite/gdb.fortran/vla-ptype.exp > index 22b2005317..bbb81ea0c8 100644 > --- a/gdb/testsuite/gdb.fortran/vla-ptype.exp > +++ b/gdb/testsuite/gdb.fortran/vla-ptype.exp > @@ -21,7 +21,7 @@ if { [prepare_for_testing "failed to prepare" ${testfil= e} ${srcfile} \ > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-sizeof.exp > b/gdb/testsuite/gdb.fortran/vla-sizeof.exp > index 8e7d36314e..d26b8c60f8 100644 > --- a/gdb/testsuite/gdb.fortran/vla-sizeof.exp > +++ b/gdb/testsuite/gdb.fortran/vla-sizeof.exp > @@ -14,13 +14,14 @@ > # along with this program. If not, see . > > standard_testfile "vla.f90" > +load_lib fortran.exp > > if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ > {debug f90 quiet}] } { > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-type.exp > b/gdb/testsuite/gdb.fortran/vla-type.exp > index 6d885e7889..f007ea3a78 100755 > --- a/gdb/testsuite/gdb.fortran/vla-type.exp > +++ b/gdb/testsuite/gdb.fortran/vla-type.exp > @@ -21,7 +21,7 @@ if { [prepare_for_testing "failed to prepare" ${testfil= e} ${srcfile} \ > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-value-sub-arbitrary.exp > b/gdb/testsuite/gdb.fortran/vla-value-sub-arbitrary.exp > index ab61dde06f..c3ed909a81 100644 > --- a/gdb/testsuite/gdb.fortran/vla-value-sub-arbitrary.exp > +++ b/gdb/testsuite/gdb.fortran/vla-value-sub-arbitrary.exp > @@ -14,13 +14,14 @@ > # along with this program. If not, see . > > standard_testfile "vla-sub.f90" > +load_lib fortran.exp > > if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ > {debug f90 quiet}] } { > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-value-sub-finish.exp > b/gdb/testsuite/gdb.fortran/vla-value-sub-finish.exp > index afd992cee4..403e411cc2 100644 > --- a/gdb/testsuite/gdb.fortran/vla-value-sub-finish.exp > +++ b/gdb/testsuite/gdb.fortran/vla-value-sub-finish.exp > @@ -14,13 +14,14 @@ > # along with this program. If not, see . > > standard_testfile "vla-sub.f90" > +load_lib fortran.exp > > if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ > {debug f90 quiet}] } { > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-value-sub.exp > b/gdb/testsuite/gdb.fortran/vla-value-sub.exp > index 3311f6befa..fd923edf40 100644 > --- a/gdb/testsuite/gdb.fortran/vla-value-sub.exp > +++ b/gdb/testsuite/gdb.fortran/vla-value-sub.exp > @@ -14,13 +14,14 @@ > # along with this program. If not, see . > > standard_testfile "vla-sub.f90" > +load_lib fortran.exp > > if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ > {debug f90 quiet}] } { > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > diff --git a/gdb/testsuite/gdb.fortran/vla-value.exp > b/gdb/testsuite/gdb.fortran/vla-value.exp > index 5af17b570c..9a727fc30a 100644 > --- a/gdb/testsuite/gdb.fortran/vla-value.exp > +++ b/gdb/testsuite/gdb.fortran/vla-value.exp > @@ -21,7 +21,7 @@ if { [prepare_for_testing "failed to prepare" ${testfil= e} ${srcfile} \ > return -1 > } > > -if ![runto_main] { > +if ![fortran_runto_main] { > untested "could not run to main" > return -1 > } > @@ -129,8 +129,8 @@ gdb_test "print vla1(9, 9, 9)" "no such vector=20 > element \\\(vector not allocated\ # Try to assign VLA to user=20 > variable clean_restart ${testfile} > > -if ![runto MAIN__] then { > - perror "couldn't run to breakpoint MAIN__" > +if ![fortran_runto_main] then { > + perror "couldn't run to main" > continue > } > gdb_breakpoint [gdb_get_line_number "vla2-allocated"] diff --git=20 > a/gdb/testsuite/gdb.fortran/whatis_type.exp > b/gdb/testsuite/gdb.fortran/whatis_type.exp > index 6a9cc0a81e..4b0cbf9c28 100644 > --- a/gdb/testsuite/gdb.fortran/whatis_type.exp > +++ b/gdb/testsuite/gdb.fortran/whatis_type.exp > @@ -23,8 +23,8 @@ if { [prepare_for_testing "failed to prepare" ${testfil= e} \ > return -1 > } > > -if ![runto MAIN__] { > - fail "run to MAIN__" > +if ![fortran_runto_main] { > + fail "run to main" > return > } > > diff --git a/gdb/testsuite/gdb.mi/mi-var-child-f.exp > b/gdb/testsuite/gdb.mi/mi-var-child-f.exp > index 8cfffa7c08..3af80a8e60 100644 > --- a/gdb/testsuite/gdb.mi/mi-var-child-f.exp > +++ b/gdb/testsuite/gdb.mi/mi-var-child-f.exp > @@ -36,7 +36,7 @@ if {[gdb_compile "${srcdir}/${subdir}/${srcfile}"=20 > "${binfile}" \ mi_gdb_reinitialize_dir $srcdir/$subdir mi_gdb_load=20 > ${binfile} > > -mi_runto MAIN__ > +mi_runto [fortran_main] > > mi_create_varobj "array" "array" "create local variable array" > > diff --git a/gdb/testsuite/lib/fortran.exp=20 > b/gdb/testsuite/lib/fortran.exp index 549ed65790..654afd2b74 100644 > --- a/gdb/testsuite/lib/fortran.exp > +++ b/gdb/testsuite/lib/fortran.exp > @@ -126,3 +126,21 @@ proc fortran_character1 {} { > return "unknown" > } > } > + > +proc fortran_main {} { This proc should have a header comment. Something like: # Return name of the main procedure based on the compiler version. > + if {[test_compiler_info {gcc-4-[012]-*}] > + || [test_compiler_info {gcc-*}] > + || [test_compiler_info {icc-*}]} { > + return "MAIN__" > + } elseif {[test_compiler_info {clang-*}]} { > + return "MAIN_" > + } else { > + return "unknown" > + } > +} > + > +# fortran version of runto_main. Please capitalise Fortran, which I believe is how the name is written. With those two fixes, please just go ahead and merge. Thanks, Andrew > + > +proc fortran_runto_main { } { > + return [runto [fortran_main]] > +} > -- > 2.17.1