From patchwork Wed Nov 18 14:46:59 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matheus Castanho X-Patchwork-Id: 41093 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id AEC7239874E0; Wed, 18 Nov 2020 14:47:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org AEC7239874E0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1605710829; bh=03Yydxhgnw9CcxN4YCUUPPFzqCYCkFm1VNZg3+2i3gs=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:Cc:From; b=qfxWbD3Dc/g+9lCFbjXxDMgEP7tUYSiHtbQrP5ysuQbej6rmKOHpegspq7lFBdVyX yTMmbFG9avKMQkBYDD4h3tAlgykKk5gSfN9eoa+3wN3TIlnnsLVmCRviAU2g2eKi8z PGY7dh9X+RItHryxofwu6sWZvtWfCKQMZfctFRug= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by sourceware.org (Postfix) with ESMTPS id 185123898035 for ; Wed, 18 Nov 2020 14:47:08 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 185123898035 Received: from pps.filterd (m0098420.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 0AIEWuJF193796 for ; Wed, 18 Nov 2020 09:47:07 -0500 Received: from ppma02dal.us.ibm.com (a.bd.3ea9.ip4.static.sl-reverse.com [169.62.189.10]) by mx0b-001b2d01.pphosted.com with ESMTP id 34w4qra71a-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 18 Nov 2020 09:47:07 -0500 Received: from pps.filterd (ppma02dal.us.ibm.com [127.0.0.1]) by ppma02dal.us.ibm.com (8.16.0.42/8.16.0.42) with SMTP id 0AIEkfx2007219 for ; Wed, 18 Nov 2020 14:47:07 GMT Received: from b01cxnp23033.gho.pok.ibm.com (b01cxnp23033.gho.pok.ibm.com [9.57.198.28]) by ppma02dal.us.ibm.com with ESMTP id 34vgjmhpsr-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 18 Nov 2020 14:47:06 +0000 Received: from b01ledav004.gho.pok.ibm.com (b01ledav004.gho.pok.ibm.com [9.57.199.109]) by b01cxnp23033.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 0AIEl5YJ64422260 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 18 Nov 2020 14:47:05 GMT Received: from b01ledav004.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id C5D5511206B; Wed, 18 Nov 2020 14:47:05 +0000 (GMT) Received: from b01ledav004.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 2EBBE112065; Wed, 18 Nov 2020 14:47:05 +0000 (GMT) Received: from localhost (unknown [9.160.22.117]) by b01ledav004.gho.pok.ibm.com (Postfix) with ESMTP; Wed, 18 Nov 2020 14:47:04 +0000 (GMT) To: libc-alpha@sourceware.org Subject: [PATCH 0/4] powerpc: Add support for system call vectored Date: Wed, 18 Nov 2020 11:46:59 -0300 Message-Id: <20201118144703.75569-1-msc@linux.ibm.com> X-Mailer: git-send-email 2.26.2 MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.312, 18.0.737 definitions=2020-11-18_04:2020-11-17, 2020-11-18 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 lowpriorityscore=0 clxscore=1015 spamscore=0 adultscore=0 suspectscore=1 malwarescore=0 mlxlogscore=922 phishscore=0 mlxscore=0 bulkscore=0 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2011180100 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Matheus Castanho via Libc-alpha From: Matheus Castanho Reply-To: Matheus Castanho Cc: tuliom@linux.ibm.com Errors-To: libc-alpha-bounces@sourceware.org Sender: "Libc-alpha" This patchset enables the usage of system call vectored (scv) instruction by system calls for improved performance on POWER9 and later processors. Please check each patch for more details, specially 3/4 which explains the rationale and details of the runtime mechanism to choose between the old behavior (sc) and the new one (scv 0). Tested on powerpc, powerpc64, and powerpc64le (with and without scv) Matheus Castanho (3): powerpc: Make PT_THREAD_POINTER available to assembly code powerpc: Runtime selection between sc and scv for syscalls powerpc: Use scv instruction on clone when available Tulio Magno Quites Machado Filho (1): powerpc: Replace brk.S with a C implementation sysdeps/powerpc/nptl/tls.h | 26 +++--- sysdeps/powerpc/powerpc32/sysdep.h | 19 ++-- sysdeps/powerpc/powerpc64/sysdep.h | 90 ++++++++++++++++++- .../linux/powerpc/{powerpc64/brk.S => brk.c} | 41 ++++----- sysdeps/unix/sysv/linux/powerpc/dl-brk.S | 1 - .../unix/sysv/linux/powerpc/powerpc32/brk.S | 52 ----------- .../unix/sysv/linux/powerpc/powerpc64/clone.S | 36 +++++++- .../unix/sysv/linux/powerpc/powerpc64/vfork.S | 6 +- sysdeps/unix/sysv/linux/powerpc/syscall.S | 11 ++- sysdeps/unix/sysv/linux/powerpc/sysdep.h | 78 +++++++++++----- 10 files changed, 235 insertions(+), 125 deletions(-) rename sysdeps/unix/sysv/linux/powerpc/{powerpc64/brk.S => brk.c} (58%) delete mode 100644 sysdeps/unix/sysv/linux/powerpc/dl-brk.S delete mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/brk.S --- 2.26.2