From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 4BCDE3858C52; Fri, 21 Apr 2023 11:37:38 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4BCDE3858C52 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1682077058; bh=XseKN9EAd0U06jpLWaITsMMzE0njhBdCZyb3q/HO+SU=; h=From:To:Subject:Date:In-Reply-To:References:From; b=bVAFfiFxm1M06qmbVqspbvaI6FFLoA9T0tgB4sT9zsD/VrEUy9oxDJXkXUdb7yoXW bF/qczFPviz8yg4r6QV26hA8fkrJiZWEGroj9x45oVNyG3Qp4A6r4j+GReMY//jdER 9PlOW/uTVkbBg0Y/+Gkgbdnaak+qdVHTfjN6BBJ4= From: "hector at marcansoft dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/109585] Carla/sord miscompiled with -O2 on ARM64 (inlining issue) Date: Fri, 21 Apr 2023 11:37:37 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 12.1.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: hector at marcansoft dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D109585 --- Comment #4 from Hector Martin --- This whole codebase is complex, and the problem is in btree code which is h= ard to simplify down. Best I can do right now is this. First grab the lv2.tar.gz attachment and extract it into /tmp. Then: $ git clone https://github.com/falkTX/Carla $ cd Carla && make -C source/modules/lilv $ cat > test.c << EOF #include "lilv/lilv.h" int main(int argc, char **argv) { LilvWorld* world =3D lilv_world_new(); lilv_world_load_all(world, "/tmp/lv2"); } EOF $ gcc -I source/includes/ -I source/modules/lilv/lilv-0.24.0/ -o test test.c ./build/modules/Release/lilv.a -lm $ ./test Compiling with -fno-schedule-insns -fno-schedule-insns2 seems to work prope= rly.=