DMARC-Filter: OpenDMARC Filter v1.4.2 delorie.com 61QKlYsI1237328 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 61QKlYsI1237328 Authentication-Results: delorie.com; dkim=pass (1024-bit key, unprotected) header.d=cygwin.com header.i=@cygwin.com header.a=rsa-sha256 header.s=default header.b=h0RWZcwF X-Recipient: archive-cygwin AT delorie DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 78D7A4BA2E10 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1772138853; bh=cG6RPtQUCxNzgZ5s7+1YCAoqMYRdXCej1AMqCzXJqU0=; h=Date:To:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=h0RWZcwF8Wvzdwg9u3as8VYjhxph1hknWhj+p7ZDNPa6DMBSNqSmUCMU1NaJXQud5 tk727m3N3qyIeFsB7uEmWW9hoRoFO/0T/XOxRfN93jvUYZvdeTEKx8BE3hGvcutiqh zKZuVN7uyvWSh4HaTN37EsePiD7VOa2PONa1Rs9U= X-Original-To: cygwin AT cygwin DOT com Delivered-To: cygwin AT cygwin DOT com DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 2C49D4BA2E0A ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 2C49D4BA2E0A ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1772138834; cv=none; b=E8OPA7GRuj/Nc98yzzsgThxdfqAfPlPzcXUFAo7kJ/fbcEKlV8ZnBqMV0taDbb/M/Yx/++qd/xDVdBUkgLXVFeZ0u2nFva2K87+9ru4kgJiMjcaet8p0Az5NH+3Nv2skoahVdWtf+zVHE+BGquLRZ6jMbBOZ3e2OauZflUHBvvE= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1772138834; c=relaxed/simple; bh=vIRCFku5IEmNSJwxVLX0XtOwGNe/2J2wnNT3xCO+mas=; h=DKIM-Signature:Date:From:To:Message-ID:Subject:MIME-Version; b=EmeRqMp5B3I0zqbcLLhkyeN5IU2tZ7uJ5ojNBoGzdF1TtpK2f+C120NBJTVsNtTz4EvrumpYZUNJHjK6ZHn1+i9YRJatnmf5HqcFAsBdGH08Q1E4Zr8/AXwNPw+UT5TtvqcBvnjXc5F5sC6UqeeATJ3ScYNRDdGZEWHF+cuYQzA= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 2C49D4BA2E0A Date: Thu, 26 Feb 2026 12:47:09 -0800 (PST) To: Dimitry Andric Message-ID: <957583332.1523179.1772138829815@connect.xfinity.com> In-Reply-To: <609655EE-8E9D-4522-A05C-F74C3FC89583@unified-streaming.com> References: <547312365 DOT 1464244 DOT 1771958282029 AT connect DOT xfinity DOT com> <1670201592 DOT 1489273 DOT 1772043520008 AT connect DOT xfinity DOT com> <1044918836 DOT 1507810 DOT 1772086967212 AT connect DOT xfinity DOT com> <1579472684 DOT 1508349 DOT 1772092747339 AT connect DOT xfinity DOT com> <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> <609655EE-8E9D-4522-A05C-F74C3FC89583 AT unified-streaming DOT com> Subject: Re: Memmove causing program crashes, giving SIGTRAP in GDB(?) MIME-Version: 1.0 X-Priority: 3 Importance: Normal X-Mailer: Open-Xchange Mailer v7.10.6-Rev83 X-Originating-IP: ::ffff:50.47.202.14 X-Originating-Port: 65182 X-Originating-Client: open-xchange-appsuite X-CMAE-Envelope: MS4xfJuqd7PVzXx0l3c3JIMXQFOml7LFmJphRPjsoVN/JO9DP8VgvatL0QSCa62P3q/0Ln54LRBLHfS9t6hlXuWV8w+lP1AwhoH7sH1QlYZoR0YrJWIRXeLj IPxS9/BfcX9h0B0It+n5jhlYWec2z0llCpO5zlaugTKH1zgIDN5pd1G8i8Ym+3xeag0jEL4lEZZTqns46AFsW4BUWyk45aM9vr01UJLyZ5kLEeeavsKcJuZu YZS5U3eQRuLpWbOanacThNK69fLoXi1EB76s+CpNCFrJ/czx3LvwofN6eI8DstIY X-BeenThere: cygwin AT cygwin DOT com X-Mailman-Version: 2.1.30 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: KENNON J CONRAD via Cygwin Reply-To: KENNON J CONRAD Cc: KENNON J CONRAD via Cygwin Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com Sender: "Cygwin" Yes, lots. 7 threads were running at the point of the crash 87% load on my i7-4790k. I did a little research since the last post. The memmove code where the crash occurs is: 0x00007ff96ba812a8 <+136>: std => 0x00007ff96ba812a9 <+137>: rep movsq %ds:(%rsi),%es:(%rdi) 0x00007ff96ba812ac <+140>: cld This sets the direction flag immediately before the rep movsq and clears the direction flag immediately after the rep movsq. Yet when gdb breaks it shows the direction flag is not set: eflags 0x246 [ PF ZF IF ] Would a forward move on overlapping data cause the SIGTRAP? Could the code have moved to a different core? Or could it have been interrupted by some other task that corrupts the flag? As I mentioned earlier, the rep movsq is only failing once per several million times memmove is called so it seems likely to be something along those lines. -Kennon > On 02/26/2026 12:20 PM PST Dimitry Andric wrote: > > > Is there some concurrency going on? Maybe some other part of the program is flipping the direction flag? > > -Dimitry > -- 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