From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) by sourceware.org (Postfix) with ESMTPS id 2D8D83858D38 for ; Mon, 3 Oct 2022 16:57:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 2D8D83858D38 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=harmstone.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-wm1-x331.google.com with SMTP id e18so7410218wmq.3 for ; Mon, 03 Oct 2022 09:57:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :sender:from:to:cc:subject:date; bh=3ZzQREvYScs4XBEC/H6OK63nHicig8U5jc2DrZv4peo=; b=mS7iyUEbCPADKP9qttc6B4sUUWdXkSifyd3gUNUHR11blP4ye/ZH0tMEM+JWQW57+w lLjygaNWSFgBwY144hIXo1Z/D7/A5gMwuPfLC/VmzloToah94omMwZtCustrl3lMPYHe vPoeHctgsDSekhTyVMGNDfUNASTAvJeXofDdjsSsLYj3OJ48+gKiZJQ8WVQnpoRdBruq HsJb2m4LL2nYwydLcuGw7VShrP4IPoQuvnYCKDCgEn/qB3LdcTcLDM/XG6Rshd5f91Ko Mmj6nfyo0Q3bOdqVsXFARZZk1+Th1rfsZHoGDlTyQerCuZohK35ncy3Ccaoc+OyoVVLg rLiw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :sender:x-gm-message-state:from:to:cc:subject:date; bh=3ZzQREvYScs4XBEC/H6OK63nHicig8U5jc2DrZv4peo=; b=8Rck0TduCIVwLAlkgG0QMPiyrYO0AF7Ah5oBndH2lqsT+Qniijs2osaS97vF9P/WTi 9sYeUUDrxRZbHh1kwZrihcen58DHwJ4LD5mku9O7prYm01peUS/2GkywbiiAlywrEPUj 76vdOCYE9MGcXxfNpkmxbMagtjFTDYLcmN2R7GmAGqs79UG4QWwzv4WerYuYx0PwLEyJ 4ZSev/86BnFoBDFrcTGHuW7GlsQUOkY1h4hsYsbuTKy7b6noylEXeZWxSzjIpV0/anro d7qQGXwhMkaU2coiuYkpe3t4N7MY0sQGNKGPL7b1rzy0H9uAyYuA9Tx4TyFXmUBJX2uz 1wDw== X-Gm-Message-State: ACrzQf3UrCI67a0rTSFAzj2Qm0WlaBCIWO6G4jnAGlWH/8x0pfdWSRas iCvaxgBLGlG92cT47KVPKo0kju7ShYs= X-Google-Smtp-Source: AMsMyM7D3H423WI8D7yIwcZ/WbipGdUbls8JnTVKgob+zYo/n/GOtDNHWRIbvz92fLHlAtad2GYjHw== X-Received: by 2002:a05:600c:3d86:b0:3b4:b65f:a393 with SMTP id bi6-20020a05600c3d8600b003b4b65fa393mr7681664wmb.0.1664816265859; Mon, 03 Oct 2022 09:57:45 -0700 (PDT) Received: from ?IPV6:2a02:8010:64ea:0:8eb8:7eff:fe53:9d5f? ([2a02:8010:64ea:0:8eb8:7eff:fe53:9d5f]) by smtp.googlemail.com with ESMTPSA id o17-20020adfcf11000000b002205a5de337sm10196538wrj.102.2022.10.03.09.57.44 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 03 Oct 2022 09:57:45 -0700 (PDT) Sender: Mark Harmstone Message-ID: Date: Mon, 3 Oct 2022 17:57:32 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.3.0 Subject: Re: [PATCH 1/2] ld: Add --pdb option Content-Language: en-US To: =?UTF-8?Q?Martin_Storsj=c3=b6?= Cc: binutils@sourceware.org References: <20221003014313.28766-1-mark@harmstone.com> <26dfc8b7-e89d-9212-da69-b05044d2d8a9@martin.st> From: Mark Harmstone In-Reply-To: <26dfc8b7-e89d-9212-da69-b05044d2d8a9@martin.st> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-5.9 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Hi Martin, > As I assume you're aware, lld's mingw port also supports PDB generation - and the description of this option also sounds like it's chosen to match lld's option for outputting PDB files - that's good! Yes, that's right. One notable difference is that the parameter here is optional, unlike with lld, making it a lot easier to fit this into e.g. CMake toolchain files or LDFLAGS. > The testcase only seemed to exercise the form --pdb=, so I thought I'd ask just for clarity: I guess the other forms of specifying the option, e.g. "--pdb " also does the same - same thing for setting the option with just one leading dash, "-pdb=" (I guess it's a getopt feature that allows that as long as it isn't ambiguous with single-letter options?), as well as the form "-pdb=" or "--pdb=" for requesting it to set the default name? Apparently provided that the option doesn't begin with an O, you can use either single dashes or double dashes. It looks like the equals sign is mandatory when providing optional parameters, otherwise it interprets the filename as another parameter. But it does mean that the form "-pdb=out.pdb" will work on both ld and lld, which I think is the most important thing. Mark