From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ed1-x532.google.com (mail-ed1-x532.google.com [IPv6:2a00:1450:4864:20::532]) by sourceware.org (Postfix) with ESMTPS id 522E13858D1E for ; Mon, 29 Aug 2022 02:21:06 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 522E13858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-ed1-x532.google.com with SMTP id t5so8425705edc.11 for ; Sun, 28 Aug 2022 19:21:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:subject:message-id:date:from:mime-version:from:to:cc; bh=ZBgYsCHpiSQMAXNGwlDej8kUrGU6Yjm8igIIrOBXEPg=; b=XrJfbD2Wdhzj7fFrr0HJApnG+vekX0VNnAwv0S4qOTgMhpbplf2FUi5nsjWKZL3eWk 7c5zQ/fqPR/cOy1ZNPM/Qnb0Tn+22RuRMEW4CI7ymDqKLLBQrHupkwqmjZrUn8mTATCi 6W+w/At4piabFXsaMkVgV0jOJzDWPHMfg/4MbqyXtY1TP8u0MnRSGRWDg/aRZcd5/HJf E0rDKAIS804GNFIgXbTiHG3AU91moQiT9Zyxs3jIcl9WAc9SE4CLPJkIOXe2PBRydOQf IWwPtjpzC/WROh27Ie4JKwi/gKr2z9bQ6dgVxKuUSvaafVztuIfRdinXiB1MMzi1iABf uyxg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc; bh=ZBgYsCHpiSQMAXNGwlDej8kUrGU6Yjm8igIIrOBXEPg=; b=vyONkoNuWwdofcyNuyfRDkspEdrpsh8aYRBkJFzTpBpxFOtmWHpWkdBle+d9O/AB8Y aqSL0FYguJm+twxOjfqNk26PRVLqYo+I05nmeIOqElYPgSt4+GB3cLxNe0hwCEGIqmRk pTL1FyzJ8yOgHuCYfksZepkWZevIf28neEHUhkhJUJqm/htPMR/xs7xUIcPOAorj67Xk wzDT+xFQ5bYrOft+NGBLMGulo1K3B2jFV3rGkrBO/K4rUHTld0+TwLsLns8YoXU8M+5K 6aMrfqg3DmR4fjvbqpU0ebj6CGqsTS96l1YvlVPYSPCjSsbeOWT9QLY+olWybAtimJTG OuUQ== X-Gm-Message-State: ACgBeo1GEIFzECrWyHT2XMNhq64O5ABUve8KvN1wjrfMKFGFtvTppJq3 JVSlTFhNuJZyFRbqB1h3enat/4A93FDOkWzstpg/dZ1d2so= X-Google-Smtp-Source: AA6agR6q+9nktzttL0Gbnif8KHhd1zi9hW63arZz4Pxg175ip+zRlfmrYR2dRzrV79vwBeCkKL+jPMrQ4cz89VD53cw= X-Received: by 2002:a05:6402:5024:b0:440:e4ad:f7b6 with SMTP id p36-20020a056402502400b00440e4adf7b6mr14942318eda.358.1661739664442; Sun, 28 Aug 2022 19:21:04 -0700 (PDT) MIME-Version: 1.0 From: Zopolis0 Date: Mon, 29 Aug 2022 12:20:52 +1000 Message-ID: Subject: GCJ segfault To: gcc-help Content-Type: multipart/alternative; boundary="0000000000006889b505e757ea79" X-Spam-Status: No, score=-0.6 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE,KAM_SHORT,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE,WEIRD_PORT autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Message-ID: <20220829022052.f9oKyR6wELjTVWTvPjVfoOFs9OZInwI-VlhqieDqTlw@z> --0000000000006889b505e757ea79 Content-Type: text/plain; charset="UTF-8" While attempting to compile gcj, it throws, among other things, a segfault that I have traced back to line 536 of gcc/java/typeck.cc (on my msterstable branch https://github.com/Zopolis4/gcj/tree/msterstable). The segfault is due to the DECL_NAME call, which then fails the contains_struct_check and causes a segfault. According to 5a5e7deb5f93f04e027fd5baa1876370d6d6697f and 78fcec3fee63f10cfde06c252fc391e768c64b12, the correct fix would be to wrap the call in DECL_NAME, no? Yet that just causes the contains_struct_check to fail on the if DECL_NAME (TYPE_NAME (type)) call. What is the proper way to solve this? libtool: compile: /home/zopolis4/gcjbuild/./gcc/gcj -B/home/zopolis4/gcjbuild/x86_64-pc-linux-gnu/libjava/ -B/home/zopolis4/gcjbuild/./gcc/ -B/usr/local/x86_64-pc-linux-gnu/bin/ -B/usr/local/x86_64-pc-linux-gnu/lib/ -isystem /usr/local/x86_64-pc-linux-gnu/include -isystem /usr/local/x86_64-pc-linux-gnu/sys-include -fomit-frame-pointer -Usun -fclasspath= -fbootclasspath=/home/zopolis4/gcjbuild/../gcj/libjava/classpath/lib --encoding=UTF-8 -Wno-deprecated -fbootstrap-classes -g -O2 -c -fsource-filename=/home/zopolis4/gcjbuild/x86_64-pc-linux-gnu/libjava/classpath/lib/classes -MT gnu/awt/j2d.lo -MD -MP -MF gnu/awt/j2d.deps @gnu/awt/j2d.list -fPIC -o gnu/awt/.libs/j2d.o /home/zopolis4/gcj/libjava/gnu/awt/j2d/AbstractGraphicsState.java: In class 'gnu.awt.j2d.AbstractGraphicsState': /home/zopolis4/gcj/libjava/gnu/awt/j2d/AbstractGraphicsState.java: In method 'gnu.awt.j2d.AbstractGraphicsState.clone()': In file included from :351: /home/zopolis4/gcj/libjava/gnu/awt/j2d/AbstractGraphicsState.java:133: internal compiler error: Segmentation fault 133 | return super.clone (); | 0xda20cf crash_signal /home/zopolis4/gcjbuild/../gcj/gcc/toplev.cc:322 0x86be61 contains_struct_check(tree_node*, tree_node_structure_enum, char const*, int, char const*) /home/zopolis4/gcjbuild/../gcj/gcc/tree.h:3621 0x86be61 build_java_signature(tree_node*) /home/zopolis4/gcjbuild/../gcj/gcc/java/typeck.cc:536 0x86b7c4 shallow_find_method /home/zopolis4/gcjbuild/../gcj/gcc/java/typeck.cc:650 0x86b9f6 lookup_do /home/zopolis4/gcjbuild/../gcj/gcc/java/typeck.cc:756 0x864d8a expand_invoke /home/zopolis4/gcjbuild/../gcj/gcc/java/expr.cc:2462 0x866193 process_jvm_instruction(int, unsigned char const*, long) /home/zopolis4/gcjbuild/../gcj/gcc/java/javaop.def:292 0x86884f expand_byte_code(JCF*, tree_node*) /home/zopolis4/gcjbuild/../gcj/gcc/java/expr.cc:3244 0x87f494 parse_class_file /home/zopolis4/gcjbuild/../gcj/gcc/java/jcf-parse.cc:1658 0x87fd2d java_parse_file() /home/zopolis4/gcjbuild/../gcj/gcc/java/jcf-parse.cc:1976 Please submit a full bug report, with preprocessed source (by using -freport-bug). Please include the complete backtrace with any bug report. See for instructions. make[3]: *** [Makefile:10625: gnu/awt/j2d.lo] Error 1 --0000000000006889b505e757ea79--