From nobody Wed Sep 15 19:32:43 2021 X-Original-To: erlang@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 0430E17B29A9 for ; Wed, 15 Sep 2021 19:32:43 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4H8r2y6X7kz3DsJ for ; Wed, 15 Sep 2021 19:32:42 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id C1DFF14003 for ; Wed, 15 Sep 2021 19:32:42 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 18FJWgXn070621 for ; Wed, 15 Sep 2021 19:32:42 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 18FJWgn1070620 for erlang@FreeBSD.org; Wed, 15 Sep 2021 19:32:42 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: erlang@FreeBSD.org Subject: [Bug 258494] lang/erlang lang/erlang-runtime21 lang/erlang-runtime23: clang 13 build breaks dtrace if PGO is enabled Date: Wed, 15 Sep 2021 19:32:43 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: dim@FreeBSD.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: erlang@FreeBSD.org X-Bugzilla-Flags: maintainer-feedback? 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: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Support of Erlang-related ports List-Archive: https://lists.freebsd.org/archives/freebsd-erlang List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-erlang@freebsd.org MIME-Version: 1.0 X-ThisMailContainsUnwantedMimeParts: N https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D258494 --- Comment #1 from Dimitry Andric --- (In reply to Dimitry Andric from comment #0) > Something in beam_emu_pu.o (emitted by clang or llvm 13) is tripping up d= trace, but I have very little knowledge about dtrace so I need help here. :) So there are two objects that are instrumented with profile generation code, beam_emu_pg.o and erl_process_pg.o. These are linked into a beam.smp execut= able which generates profile data, and the data is used to build beam_emu_pu.o a= nd erl_process_pu.o. The difference between llvm 12 and llvm 13 output is in the produced sectio= ns for the _pu.o files. With llvm 12, there is a .llvm.call-graph-profile sect= ion (to be used by the linker to rearrange 'hot' and 'cold' parts): [Nr] Name Type Address Off Size ES = Flg Lk Inf Al ... [19] .llvm.call-graph-profile LOOS+0xfff4c02 0000000000000000 02e9f0 000= e80 10 E 21 0 1 whereas with llvm 13, there is an additional .rel.llvm.call-graph-profile section: [Nr] Name Type Address Off Size ES = Flg Lk Inf Al ... [17] .llvm.call-graph-profile LOOS+0xfff4c09 0000000000000000 0279a9 000= 750 08 E 22 0 1 [18] .rel.llvm.call-graph-profile REL 0000000000000000 030888 001d40 10 22 17 8 I have verified that removing the .rel.llvm.call-graph-profile section from= the _pu.o files (using objcopy --remove .rel.llvm.call-graph-profile) makes dtr= ace not crash anymore. However, I think the .rel.llvm.call-graph-profile section might contain information that is useful to the linker. So the question is still what is = in this particular section that makes dtrace crash. --=20 You are receiving this mail because: You are the assignee for the bug.=