| delorie.com/archives/browse.cgi | search |
| DMARC-Filter: | OpenDMARC Filter v1.4.2 delorie.com 61QKLJOC1228940 |
| Authentication-Results: | delorie.com; dmarc=pass (p=none dis=none) header.from=cygwin.com |
| Authentication-Results: | delorie.com; spf=pass smtp.mailfrom=cygwin.com |
| DKIM-Filter: | OpenDKIM Filter v2.11.0 delorie.com 61QKLJOC1228940 |
| Authentication-Results: | delorie.com; |
| dkim=fail reason="signature verification failed" (1024-bit key, unprotected) header.d=cygwin.com header.i=@cygwin.com header.a=rsa-sha256 header.s=default header.b=AY0fzgGX | |
| X-Recipient: | archive-cygwin AT delorie DOT com |
| DKIM-Filter: | OpenDKIM Filter v2.11.0 sourceware.org 19FA54BA23D0 |
| DKIM-Signature: | v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; |
| s=default; t=1772137278; | |
| bh=Rl5/4We9x3Pa28DhlUijn/vWMfjhJGB35nmkWvO1As0=; | |
| h=Subject:In-Reply-To:Date:References:To:List-Id:List-Unsubscribe: | |
| List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: | |
| From; | |
| b=AY0fzgGXsREVdspm40HBv+BDRFmbxemC9JcsPWscd3C21TK7E/vrHq67nFUVtzD8i | |
| ZqOcAmbnviZFTwHLu6LQktSSUpiIr7Z+JPXCPPxqzNkdxckDMCedFcKJ64lIjAuxYC | |
| gKvWv53lDki/DArFKktAt5jHOQ9pYrbRo0b5t1eY= | |
| X-Original-To: | cygwin AT cygwin DOT com |
| Delivered-To: | cygwin AT cygwin DOT com |
| DMARC-Filter: | OpenDMARC Filter v1.4.2 sourceware.org 14AA44BA2E0A |
| ARC-Filter: | OpenARC Filter v1.0.0 sourceware.org 14AA44BA2E0A |
| ARC-Seal: | i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1772137257; cv=none; |
| b=GmdtO+HHdc8zrhASrEIIQAECvjpoLTLdTb6XBe82Y0Ic23uwZRunEIySaw5c55lvIuGL70xXkYZmD6Gb970+vIa6zFHrnTjGIga6JrNCYOOgndQMGItcXIEC7A1EJg/RCmfMT0cdqwM4iFZfBELdmae2W4qWD8QBfCRTQXT7Id8= | |
| ARC-Message-Signature: | i=1; a=rsa-sha256; d=sourceware.org; s=key; |
| t=1772137257; c=relaxed/simple; | |
| bh=Alrp++1xUmsoz1tZijbfk+lrmjXMph3da9GbnyzX9iQ=; | |
| h=DKIM-Signature:Mime-Version:Subject:From:Date:Message-Id:To; | |
| b=R+/LUjPbUpae+OnXmDalQJFX+ZrtqnlYSE5Y44Cp+olZLEc5dF9dpXIruKmet2Iy4XOZjNDCaqb6rOo+w7JXdqpnFUSdu7F6T1xhJxjbAh+bD0djxKYNKaK8C0XjgzFPIet62zgk+45PUen+7DHEP3QCN/tv6Mp4IWfFW5+G9P0= | |
| ARC-Authentication-Results: | i=1; server2.sourceware.org |
| DKIM-Filter: | OpenDKIM Filter v2.11.0 sourceware.org 14AA44BA2E0A |
| X-Google-DKIM-Signature: | v=1; a=rsa-sha256; c=relaxed/relaxed; |
| d=1e100.net; s=20230601; t=1772137256; x=1772742056; | |
| h=to:references:message-id:content-transfer-encoding:cc:date | |
| :in-reply-to:from:subject:mime-version:x-gm-gg:x-gm-message-state | |
| :from:to:cc:subject:date:message-id:reply-to; | |
| bh=m4tFv8W56vEctRsQVFm7I4CmRcGNhcWjsw+/szdfoQg=; | |
| b=U8i5ab9jtovLRKcemyQC6DnOjdKkQzaeNU9SYGyFAILlVEg3Hq0R53J7XFEEdBaTAT | |
| 9c0x4UloW+7lsp/8BErADJab9f1XCgmZehpxtVoa0rWrz8eSTR0Sca5YOd7aWa6KvA4u | |
| Ow3k+n/h3XC1Y9QG2smC7SRI+pt2zSStxuPddQfu5v6c5eazDsVt6D1Iy5eAWCvd6uzE | |
| rKMogPxhIb6++NPpy4G7GLlOqiPb27kkvDiVS3So11JWLlClMuUaGc3jDMtCm+2/+L7t | |
| ZwFAdSqU533zcosJa4JrubciKDOeMEPpinL5Yq3hnlNImRg4uOT2JZ+RtHMDmVjEBBn7 | |
| l7CQ== | |
| X-Forwarded-Encrypted: | i=1; |
| AJvYcCVHAviFNSygpZtcs/2sen2eWH77WTh7g5dv0sA92SkXdGeXlbHkEhgOSxnZgpqdwJ/XlRt4H2k=@cygwin.com | |
| X-Gm-Message-State: | AOJu0YxUzTtehQqxZ28/xSeXc/23mnH8K5ainOcGjroosqBBvsPQOQxF |
| FTbHhmvth0HM1CfDuUV8/5N5JtdT4Y3csOhX6umxyEjRsvzjL4LVSeBFNsFxdos1U7Os1EjcUEQ | |
| LHW5f | |
| X-Gm-Gg: | ATEYQzwxMrdjFx3OLJpAFHiYc28DOSp03AhQ4moAHPk6vQ78XbG7oCNfb8rr/Yv07/P |
| uTyq2GxtvJtk5KKM3nIUsgAjUxFuwXpyLy4zD/wBZcXwuxw49d1qn4T0mP9yR3ze2tIqrIiw5+f | |
| lBFCqmZv7I4Lvrh8DGsXkNYP2QcR8k/vFjb3/Er8pAD2YZUTtNMxmC7Z4JO0VGKSXjljCpPWcB1 | |
| ADrqHO/nrT6uqsOkkS4EmuDve9qF+Sg31s49aeb7xaRLaklwPX/Mg4/6J3Czz+GHJ0Sjt34NJlu | |
| o/+NygL2UK7WVF2rf6DkcjxrzvNwA6mOeU3MGENWeNrp0QCOgT+fa07NePuUAWap5t2ujijoqcW | |
| +29V0IZhaqq8HjnyUcoS1vHik2cG9caa8MhTU+ggmi/G1HyoxHvdDwsVHfusQZlC+psqYsdNkVn | |
| YWUnZt4GDZiqETpM7POh/oTSydwwyvWG5/hhrk7ntQuvOkzh2XlMQHj65U7sC0cOoaRA== | |
| X-Received: | by 2002:a17:906:2848:b0:b8f:b3c4:1e2 with SMTP id |
| a640c23a62f3a-b9376547f85mr9343266b.39.1772137255918; | |
| Thu, 26 Feb 2026 12:20:55 -0800 (PST) | |
| Mime-Version: | 1.0 (Mac OS X Mail 16.0 \(3826.700.81.1.4\)) |
| Subject: | Re: Memmove causing program crashes, giving SIGTRAP in GDB(?) |
| X-Priority: | 3 |
| In-Reply-To: | <1462848037.1521935.1772136952077@connect.xfinity.com> |
| Date: | Thu, 26 Feb 2026 21:20:54 +0100 |
| Message-Id: | <609655EE-8E9D-4522-A05C-F74C3FC89583@unified-streaming.com> |
| References: | <547312365 DOT 1464244 DOT 1771958282029 AT connect DOT xfinity DOT com> |
| <aZ7PrbisVR1R4A7v AT dimstar DOT local DOT net> | |
| <1670201592 DOT 1489273 DOT 1772043520008 AT connect DOT xfinity DOT com> | |
| <e91d8b5b-2690-4271-aa74-e6226440e33d AT SystematicSW DOT ab DOT ca> | |
| <1044918836 DOT 1507810 DOT 1772086967212 AT connect DOT xfinity DOT com> | |
| <1579472684 DOT 1508349 DOT 1772092747339 AT connect DOT xfinity DOT com> | |
| <aaABFf5iEowV1l7I AT xps13> <1148572549 DOT 1808180 DOT 1772097444036 AT mail DOT yahoo DOT com> | |
| <1901597260 DOT 1508573 DOT 1772100378936 AT connect DOT xfinity DOT com> | |
| <0C965DD0-856E-41FF-B5A4-15E472292A32 AT unified-streaming DOT com> | |
| <483908609 DOT 1508714 DOT 1772103775739 AT connect DOT xfinity DOT com> | |
| <2346fd41-2500-0db6-5849-6788174b5a1d AT cs DOT umass DOT edu> | |
| <1462848037 DOT 1521935 DOT 1772136952077 AT connect DOT xfinity DOT com> | |
| To: | KENNON J CONRAD <kennonconrad AT comcast DOT net> |
| X-Mailer: | Apple Mail (2.3826.700.81.1.4) |
| X-BeenThere: | cygwin AT cygwin DOT com |
| X-Mailman-Version: | 2.1.30 |
| List-Id: | General Cygwin discussions and problem reports <cygwin.cygwin.com> |
| List-Unsubscribe: | <https://cygwin.com/mailman/options/cygwin>, |
| <mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe> | |
| List-Archive: | <https://cygwin.com/pipermail/cygwin/> |
| List-Post: | <mailto:cygwin AT cygwin DOT com> |
| List-Help: | <mailto:cygwin-request AT cygwin DOT com?subject=help> |
| List-Subscribe: | <https://cygwin.com/mailman/listinfo/cygwin>, |
| <mailto:cygwin-request AT cygwin DOT com?subject=subscribe> | |
| From: | Dimitry Andric via Cygwin <cygwin AT cygwin DOT com> |
| Reply-To: | Dimitry Andric <dimitry AT unified-streaming DOT com> |
| Cc: | KENNON J CONRAD via Cygwin <cygwin AT cygwin DOT com> |
| Errors-To: | cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com |
| Sender: | "Cygwin" <cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com> |
Is there some concurrency going on? Maybe some other part of the program is flipping the direction flag? -Dimitry > On 26 Feb 2026, at 21:15, KENNON J CONRAD <kennonconrad AT comcast DOT net> wrote: > > Hello Eliot, > > Yes, that helps a lot. With the frame set to the one for memmove, the RSI register contains 0xa00035e0e. With the candidates_index address of 0xa00034460, that indicates the RSI register is 0x19AE more than the array start index and corresponds to index 3287 of the uint16_t array. The array index of the rightmost element that should be moved is 3359, so RSI holds an array index that is 72 less than the last index that should be moved. But since the RSI is already set up for the next iteration of REP MOVSQ, it seems that 68 array elements should have been moved prior to the REP that gets the SIGTRAP. So I checked the index array, and found it contains duplicate values of 2028 at both array indexes 3291 and 3292 (elements 3292 and above have been copied from elements 3291 and above). There should not be any duplicate values in the active portion of the array except during the move. So it seems that 17 REP MOVSQ's were completed successfully before the SIGTRAP prevented the 1 8th move from being completed. It shouldn't stop until the 767th array element is moved, so this is pretty early in the desired REP MOVSQ iterations. Interestingly, the DF is not set in EFLAGS at the point where the SIGTRAP is issued (eflags 0x246 [ PF ZF IF ]) - I thought it should be set for backward REP MOVSQ's. > > Best Regards, > > Kennon > > > > >> On 02/26/2026 5:25 AM PST Eliot Moss <moss AT cs DOT umass DOT edu> wrote: >> >> >> On 2/26/2026 6:02 AM, KENNON J CONRAD via Cygwin wrote: >> >>> Thanks for checking and sharing your thoughts. This is what I would expect, so at least I'm not crazy :) >>> I really need to see the values of the registers in memmove, hopefully it's just a matter of continuing to learn gdb. >> >> The command is "info registers", of "info r" for short. You can also print an >> individual register using (say) "print $rax" (prefix the register name by $) >> or "info r rax". If you're stepping, you can set up a *layout* that shows all >> the register values as you step along. >> >> You also might consider using a reverse debugging tool like the "undo" debugger. >> They track enough information to allow them to (effectively) execute backwards >> from a point. Not sure if any work under cygwin, though. >> >> By the way, I got the commands for printing individual registers with a simple >> web search :-) ... >> >> HTH -- Eliot Moss -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |