From dev-return-5320-archive-asf-public=cust-asf.ponee.io@groovy.apache.org Wed Sep 5 13:08:45 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id BFA2D180654 for ; Wed, 5 Sep 2018 13:08:44 +0200 (CEST) Received: (qmail 13311 invoked by uid 500); 5 Sep 2018 11:08:43 -0000 Mailing-List: contact dev-help@groovy.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@groovy.apache.org Delivered-To: mailing list dev@groovy.apache.org Received: (qmail 13292 invoked by uid 99); 5 Sep 2018 11:08:43 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Sep 2018 11:08:43 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id A8E20C1C64 for ; Wed, 5 Sep 2018 11:08:42 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.699 X-Spam-Level: X-Spam-Status: No, score=-0.699 tagged_above=-999 required=6.31 tests=[HEADER_FROM_DIFFERENT_DOMAINS=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id aw6e3zqAYQ_A for ; Wed, 5 Sep 2018 11:08:39 +0000 (UTC) Received: from smtpout20.partage.renater.fr (smtpout02-ext4.partage.renater.fr [194.254.241.31]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 500C15F3CD for ; Wed, 5 Sep 2018 11:08:39 +0000 (UTC) Received: from zmtaout02.partage.renater.fr (zmtaout02.partage.renater.fr [194.254.241.30]) by smtpout20.partage.renater.fr (Postfix) with ESMTP id 2EEE4BFAA3 for ; Wed, 5 Sep 2018 13:08:32 +0200 (CEST) Received: from zmtaout02.partage.renater.fr (localhost [127.0.0.1]) by zmtaout02.partage.renater.fr (Postfix) with ESMTPS id 249C0200B0 for ; Wed, 5 Sep 2018 13:08:32 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by zmtaout02.partage.renater.fr (Postfix) with ESMTP id 132602009D for ; Wed, 5 Sep 2018 13:08:32 +0200 (CEST) X-Virus-Scanned: amavisd-new at zmtaout02.partage.renater.fr Received: from zmtaout02.partage.renater.fr ([127.0.0.1]) by localhost (zmtaout02.partage.renater.fr [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id 3uAfouOhUGPn for ; Wed, 5 Sep 2018 13:08:32 +0200 (CEST) Received: from zstore-b1-015.partage.renater.fr (zstore-b1-015.partage.renater.fr [10.254.241.127]) by zmtaout02.partage.renater.fr (Postfix) with ESMTP id EDC43200B0 for ; Wed, 5 Sep 2018 13:08:31 +0200 (CEST) Date: Wed, 5 Sep 2018 13:08:31 +0200 (CEST) From: Remi Forax To: dev Message-ID: <1818952964.816975.1536145711908.JavaMail.zimbra@u-pem.fr> In-Reply-To: References: <04700f3a-9e92-1ad7-ed21-0cc05fffeff1@gmx.org> <276382603.808114.1536143813314.JavaMail.zimbra@u-pem.fr> Subject: Re: Old bytecode targets MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Originating-IP: [88.187.40.25] X-Mailer: Zimbra 8.8.8_GA_3008 (ZimbraWebClient - FF61 (Linux)/8.8.8_GA_1703) Thread-Topic: Old bytecode targets Thread-Index: M6oRb28+MwGI8oaZset9DA2iRehQeA== COMPUTE_FRAMES + getCommonSuperClass is one option, calling visitFrame by y= ourself is the other option, for the later usually you have more context to= find the super type but it means you have to generate the visitFrame at th= e right place. R=C3=A9mi ----- Mail original ----- > De: "Jochen Theodorou" > =C3=80: "dev" > Envoy=C3=A9: Mercredi 5 Septembre 2018 12:44:45 > Objet: Re: Old bytecode targets > Am 05.09.2018 um 12:36 schrieb Remi Forax: > [...] >>=20 >> it's not free if you ask ASM (COMPUTE_FRAMES) to do the fix point algori= thm >> (which is not linear) and to infer the common supertype, if you generate= the >> StackFrames in the groovy compiler by calling explicitly visitFrame, the >> runtime cost is not big (but you need to modify your compiler backend wh= ich has >> development a cost). >=20 >=20 > we cannot let asm just do this 100% for us. The classes under > compilation are possibly not available through classloading, and asm > might not even use the right classloader if they would. what we do then > is using COMPUTE_FRAMES, but override >=20 > protected String getCommonSuperClass(String arg1, String arg2) >=20 > which does a not 100% correct calculation of the common super class. > (not 100% correct means here to claim it is Object in some cases, where > there would be a better fit) >=20 > bye Jochen