X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:mime-version:from:date:message-id:subject:to :content-type; q=dns; s=default; b=vBslVEVEFouvLhQPFzglNCZOzFenF ndcWwpKfXg4pvBt9RTwj5uEqDen6iTVdecHXGS7henjTWoq5wuzSzRDUL++R7aB5 gJ8qIkEqeTK776LJPxoW6pyVMOo4NDTHqM7f4ABx6cx3Qapa9CRVupQIzXERSpn0 RdSSkJ77s0ypFY= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:mime-version:from:date:message-id:subject:to :content-type; s=default; bh=SZNyuQdMo286TmAdUEfSO9W3GaI=; b=CBW x5LfnKiGQcC7a4FBAljCixwxzF3wMpTzMwv33skLR0z2WwlH0Va/TiI9CN1OXP/2 mcZdKRfIVEKPG7bt6sDXH432eNQRAcr8sUTH6vqA58HZoYWoziE3BGDYC4VWE9r+ wZob8yT+EEdJh536XtAwh6pfpoWo4QPKqCg08hNo= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.4 required=5.0 tests=BAYES_00,KAM_NUMSUBJECT,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=no version=3.3.2 spammy=upgraded, Hx-languages-length:1331 X-HELO: mail-oi0-f47.google.com X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=dI6idgQmb7oc3OctGt1ry3NxyOiCltLXnnKyGr6gwaI=; b=cA7dypoHSaU2qJpqoHU9u4nuqSwe3hEh7ZdBCpQ+ioUM7S6zSJTOv5GTsIUMgrivHh 5YDNUTxiMj4FfZPM8GtdRil+mQT9JpB5xfJ0NgnZi3KniN3bX68Mg2sVWiWV9K9g6n3A vMCGTUhPsnUP0Qbjv8EdSB7JES4qlh096G+L5yLL2YaPLWjcZNvoKsvzRgGVHJZsaB3c gd9tVgoWmgMVa1WXiGEOm6sibp//8ta/CSVyI0TwvSvvOND7UfLiM5YXwMshYWKxFhe7 nWPqibpITlLd816XLVTg17teRDxgZIfIkZl+nbYYarBXS5tnBeRqRAT4gFLF+8jFY40y 0uSA== X-Gm-Message-State: ALKqPwfdrefAt/2+FugnCUXSW0wTDLRKIenjsxWDUs9GTkA0U2bkpEly OyydEJ7AkMppsli5sCXBa2vDnoGjmwlq6Tx6oTY4ufeC X-Google-Smtp-Source: AB8JxZr55WWsg0WU/kJYv1Ze3kf2NSTAlweG+vQMjj7b2b4FTASuQp6tJn7klwqfJwfRhIltSCh0M41wQ5zMNwoI/j4= X-Received: by 2002:aca:c108:: with SMTP id r8-v6mr8090025oif.68.1526357873206; Mon, 14 May 2018 21:17:53 -0700 (PDT) MIME-Version: 1.0 From: Michael Enright Date: Mon, 14 May 2018 21:17:52 -0700 Message-ID: Subject: Defaulting to stabs debug output from AS Cygwin64 To: cygwin AT cygwin DOT com Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes I am working on a little compiler for fun, which generates assembly code. At this point I manually invoke as and ld. For debugging I added the -g option to the invocation of as, but then ld failed with t.o:t.s:1:(.stab+0x14): relocation truncated to fit: R_X86_64_32 against `.text' Looking into this on Stack Overflow I was taught that stabs is obsolete. I think 'obsolete' may not be quite the right interpretation, but 'wrong for Cygwin64' could be the right story. Practically speaking, without thinking about it too critically, -gdwarf2 in place of -g is the solution. I'm trying to find authority for saying anything exact about the situation: 1) Is there a reason why stabs is the default for '-g' with Cygwin64? 1a) Is a patch desired to make dwarf2 the default? 2) Is there a way within Cygwin64 that a .o file with stabs can be properly processed by ld to give proper input to gdb? 3) Is stabs fatally flawed for the purposes of Cygwin64 or could it be upgraded, within the existing meaning of the stabs specification, so that it would work? 3a) To put it another way, is this just a stabs bug that could be fixed for Cygwin64? Above when I say Cygwin64, I'm talking about straightforward native use of as, ld, and gdb, not cross-compiling to some other platform. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple