From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm1-x32b.google.com (mail-wm1-x32b.google.com [IPv6:2a00:1450:4864:20::32b]) by sourceware.org (Postfix) with ESMTPS id CCA5A38708E5 for ; Sat, 9 Jan 2021 19:30:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org CCA5A38708E5 Received: by mail-wm1-x32b.google.com with SMTP id e25so11315430wme.0 for ; Sat, 09 Jan 2021 11:30:56 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=mDG4Lbo4/qaznczkkX5JfhM7bugtx3287JMAdSs/jo4=; b=UsMBuRp3Wim1HNJwxAUM6svACZObMhwJ6wuSEUyvCazCu1B6CD+zUSGmiIEmsp/9+/ 4j2sUPx2xc6w7Nv1ysUAdpuVgjZCHc0Keg6d6wrrWchBep0xrT/Nbg/TdncGKnzTA1/E cgnoboHVr6iZ9Lf9PeS2peWK5gp2E+LaoIkIvMyn8lJLranfGz+C3FMP7t8AHL8Hp5JJ pDbM2QVlh9hDvKPpeZ/gSTQhNrMUUMqKMD1JS97mjZUbGkAOHekR6f8vh3/YRDUytnUD 9gTvp6pp3nVE464LlonofXduIibMq6h7SuUWPI+NgZnDWbWlPqEsBVTKAMY9PGWTpZwW EMiA== X-Gm-Message-State: AOAM531g5EPyqrWRo7tKOj70rdbhH9lFI128GyC+I4nDkwkqg2WDumTt yfXsqx4dSvtJj4a7IzcdrQs= X-Google-Smtp-Source: ABdhPJx68u0FEUB/MMaZNtWnxw6+9oPSU7DlicQggBxgIqTnW/gV+1B3tsHyFJrhF7AwYe/9T55OoQ== X-Received: by 2002:a1c:2785:: with SMTP id n127mr8326466wmn.148.1610220655972; Sat, 09 Jan 2021 11:30:55 -0800 (PST) Received: from [192.168.1.212] (host81-138-1-83.in-addr.btopenworld.com. [81.138.1.83]) by smtp.googlemail.com with ESMTPSA id i11sm14480692wmq.10.2021.01.09.11.30.54 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sat, 09 Jan 2021 11:30:54 -0800 (PST) Content-Type: text/plain; charset=utf-8; delsp=yes; format=flowed Mime-Version: 1.0 (Mac OS X Mail 10.3 \(3273\)) Subject: Re: apple silicon fortran From: Iain Sandoe In-Reply-To: <291F2ED7-BFF4-4F8C-A902-62231FB75425@gmail.com> Date: Sat, 9 Jan 2021 19:30:53 +0000 Cc: Jerry DeLisle , Thomas Koenig , Fortran List , Rosemary Mardling Content-Transfer-Encoding: 8bit Message-Id: References: <941045F7-9782-408B-BF5A-015E2FAF246A@monash.edu> <7FCF49F0-EA95-44F1-B5B6-01393378783E@gmail.com> <1ED16F62-4E5F-4EC1-9CD6-3E5A59A6C415@googlemail.com> <291F2ED7-BFF4-4F8C-A902-62231FB75425@gmail.com> To: James Secan X-Mailer: Apple Mail (2.3273) X-Spam-Status: No, score=-3.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, 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: fortran@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Fortran mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 09 Jan 2021 19:30:58 -0000 Hi Jim, James Secan wrote: >> On Jan 9, 2021, at 11:07 AM, Iain Sandoe via Fortran >> wrote: >> I am testing out the Rosetta 2 alternative (which is, AFAIU, a >> binary-conversion done at install-time native on macOS). >> >> Useful to have some fall-back solutions in the short-term, but a native >> compiler is still the eventual objective. > > I would think that running the compiler under Rosetta 2 would still > produce a binary that is not compatible with the M1 processor (would it > run on a Mac Intel box?). Yes, that’s right - it would be an x86_64 compiler, running via Rosetta on Arm64, producing X86_64 object ... > Can you run the binary on M1 using Rosetta 2 again? … it would seem to defeat some use-case if not - given that the bootstrap succeeded, evidently yes (but perhaps using the JIT mechanism, which might not perform so well).. > And my admittedly-shallow understanding of Rosetta 2, isn’t it supposed > to generate a new binary the first time a code is run using it, said new > binary then being run directly in a subsequent invocation of > Rosetta2+userApp? Actually, (from limited reading, and likely equally shallow understaning), it seems that this operates two ways; a one-off when something is installed (so that from then-on one is running native code, with no translation phase). That’s different from the Rosetta 1 (PowerPC=>X86). The second mode is more akin to the Rosetta 1 case, a JIT that is run as needed... > I am interested to hear the results of your testing with Rosetta 2. I bootstrapped x86_64-apple-darwin20 on aarch64-darwin20.3, and currently running the Fortran testsuite - it’s not clear to me if some of the issues (PIE and no-executable stack) will be sidestepped or not. We shall see. Iain