From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1944) id 6F930387688F; Wed, 26 Oct 2022 15:19:49 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6F930387688F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1666797589; bh=oFyglzQNxyEISosFCno1Ip5T+wKUzh7sQz/W/QZLJ5k=; h=From:To:Subject:Date:From; b=M4yrNwQjBWzveVp1AEbdDVxvUoswe7XVAMOA9Mwe2ZLSF3fLUlLfLQNGKgwUAzEQ6 qZzoimfAjnUKoXG1s9kQvdBRHf3/g8aRYq+vsZoKtZr+c9byPETEOhwxcKHFlYAZke t8P6VyG5f80U1Zq+eTvlgEMUvmpNSFWndxXfwE8Y= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Szabolcs Nagy To: glibc-cvs@sourceware.org Subject: [glibc/arm/morello/main] TODO(sprof): cheri: disable profiling shared libraries X-Act-Checkin: glibc X-Git-Author: Szabolcs Nagy X-Git-Refname: refs/heads/arm/morello/main X-Git-Oldrev: 96320bbc9042c4aa04bf3955e5399683933e539b X-Git-Newrev: 7eafdab20da5957666acfdf2ac1c5ac3840374a2 Message-Id: <20221026151949.6F930387688F@sourceware.org> Date: Wed, 26 Oct 2022 15:19:49 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=7eafdab20da5957666acfdf2ac1c5ac3840374a2 commit 7eafdab20da5957666acfdf2ac1c5ac3840374a2 Author: Szabolcs Nagy Date: Thu May 12 09:05:30 2022 +0100 TODO(sprof): cheri: disable profiling shared libraries This is needed now to avoid referencing abort in ld.so. TODO: Fixing shared library profiling for capabilities requires type fixes so capabilities are not stored into shared memory (maybe purecap layout can match the lp64 one and then no file format and external tooling change is required.) TODO: Proper fix also depends on _dl_runtime_profile plt entry Diff: --- elf/dl-profile.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/elf/dl-profile.c b/elf/dl-profile.c index ec57e3a965..2cb66e83c6 100644 --- a/elf/dl-profile.c +++ b/elf/dl-profile.c @@ -182,6 +182,9 @@ static unsigned int log_hashfraction; void _dl_start_profile (void) { +#ifdef __CHERI_PURE_CAPABILITY__ + __libc_fatal ("Profiling is not supported on capability architectures."); +#else char *filename; int fd; struct __stat64_t64 st; @@ -482,6 +485,7 @@ _dl_start_profile (void) /* Turn on profiling. */ running = 1; +#endif }