From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 42B9B395BC26; Wed, 20 May 2020 11:19:45 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 42B9B395BC26 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1589973585; bh=NK43Z0CZaZkAMbEQqz2gVLU/WYo0izCPskIUQXMzwUw=; h=From:To:Subject:Date:In-Reply-To:References:From; b=Xd75ewEWXQv3tTE+VOtIv5cxFQvQDrSmv+uBLNmsijvTGwGqnLEEBphEMWcK9Zb4P TYYfeN6Js24Bzy5OabCctzTW2O/RuMDiKXRUbTtPn1GeXvGbn6bzZyK8jggxr2vcCp EwbrpUN0y5AhY61eiAsBAD5+cQCAB1RM2qbYTIRg= From: "iains at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug sanitizer/95137] Sanitizers seem to be missing support for coroutines Date: Wed, 20 May 2020 11:19:44 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: sanitizer X-Bugzilla-Version: unknown X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: iains at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: iains at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 May 2020 11:19:45 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D95137 --- Comment #15 from Iain Sandoe --- (In reply to Martin Li=C5=A1ka from comment #14) > The original problem: >=20 > test.cc:3749:5: runtime error: member call on misaligned address > 0x000041b58ab3 for type 'struct awaiter', which requires 8 byte alignment > 0x000041b58ab3: note: pointer points here > >=20 > @Iain: How do you allocate the awaiter object? The coro frame is laid out according to the types determined for the object= s it contains (the awaiter types are known at the point it's laid out). It just uses the 'normal' struct building rules. Awaiters are most often initialised from return values from some promise method, but they can also be local vars or parms - perhaps I slipped up the= re. I have a thought that I might be failing to copy across excess alignment applied (which I will look at later). ^^^ these are things on my TO-LOOK-AT list. >=20 > @Rafael: Can you please append output with: > export UBSAN_OPTIONS=3D"print_stacktrace=3D1"=