From patchwork Fri Sep 23 09:59:55 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rainer Orth X-Patchwork-Id: 116035 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 72DB7B6F89 for ; Fri, 23 Sep 2011 20:00:20 +1000 (EST) Received: (qmail 23019 invoked by alias); 23 Sep 2011 10:00:16 -0000 Received: (qmail 23007 invoked by uid 22791); 23 Sep 2011 10:00:14 -0000 X-SWARE-Spam-Status: No, hits=-2.1 required=5.0 tests=AWL, BAYES_00, RP_MATCHES_RCVD, T_TVD_MIME_NO_HEADERS X-Spam-Check-By: sourceware.org Received: from snape.CeBiTec.Uni-Bielefeld.DE (HELO smtp-relay.CeBiTec.Uni-Bielefeld.DE) (129.70.160.84) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 23 Sep 2011 09:59:59 +0000 Received: from localhost (localhost.CeBiTec.Uni-Bielefeld.DE [127.0.0.1]) by smtp-relay.CeBiTec.Uni-Bielefeld.DE (Postfix) with ESMTP id D53ABF57; Fri, 23 Sep 2011 11:59:57 +0200 (CEST) Received: from smtp-relay.CeBiTec.Uni-Bielefeld.DE ([127.0.0.1]) by localhost (malfoy.CeBiTec.Uni-Bielefeld.DE [127.0.0.1]) (amavisd-new, port 10024) with LMTP id uwYOqGg-dwdf; Fri, 23 Sep 2011 11:59:56 +0200 (CEST) Received: from manam.CeBiTec.Uni-Bielefeld.DE (manam.CeBiTec.Uni-Bielefeld.DE [129.70.161.120]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp-relay.CeBiTec.Uni-Bielefeld.DE (Postfix) with ESMTPS id F1363F56; Fri, 23 Sep 2011 11:59:55 +0200 (CEST) Received: (from ro@localhost) by manam.CeBiTec.Uni-Bielefeld.DE (8.14.5+Sun/8.14.5/Submit) id p8N9xt1d001695; Fri, 23 Sep 2011 11:59:55 +0200 (MEST) From: Rainer Orth To: gcc-patches@gcc.gnu.org Cc: Arnaud Charlet , Uros Bizjak Subject: [ada] Restore Ada bootstrap on Solaris 8, 9/x86 Date: Fri, 23 Sep 2011 11:59:55 +0200 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (usg-unix-v) MIME-Version: 1.0 X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Mainline Ada bootstrap is currently broken on Solaris 8 and 9/x86 with Sun as: Assembler: a-strunb.adb "/var/tmp//cc6ZxWWa.s", line 2395 : Syntax error "/var/tmp//cc6ZxWWa.s", line 2591 : Syntax error make[7]: *** [a-strunb.o] Error 1 The problem is that s-atocou-x86.adb uses lock incl resp. lock decl, where older Sun as requires lock; incl. This is exactly what %; was introduced for, which is already used in i386/sync.md. The following patch uses it and allowed i386-pc-solaris2.[89] bootstraps to complete. Testing is currently running, and I'll also bootstrap with gas instead of as once that's finished. Ok for mainline if those tests pass? Thanks. Rainer 2011-09-23 Rainer Orth * s-atocou-x86.adb (Decrement): Use %;. (Increment): Likewise. # HG changeset patch # Parent 66b8372f5970a73e9957914fae8bfbeced71a512 Restore Ada bootstrap on Solaris 8, 9/x86 diff --git a/gcc/ada/s-atocou-x86.adb b/gcc/ada/s-atocou-x86.adb --- a/gcc/ada/s-atocou-x86.adb +++ b/gcc/ada/s-atocou-x86.adb @@ -50,7 +50,7 @@ package body System.Atomic_Counters is begin System.Machine_Code.Asm (Template => - "lock decl" & ASCII.HT & "%0" & ASCII.LF & ASCII.HT + "lock%; decl" & ASCII.HT & "%0" & ASCII.LF & ASCII.HT & "sete %1", Outputs => (Unsigned_32'Asm_Output ("=m", Item.Value), @@ -68,7 +68,7 @@ package body System.Atomic_Counters is procedure Increment (Item : in out Atomic_Counter) is begin System.Machine_Code.Asm - (Template => "lock incl" & ASCII.HT & "%0", + (Template => "lock%; incl" & ASCII.HT & "%0", Outputs => Unsigned_32'Asm_Output ("=m", Item.Value), Inputs => Unsigned_32'Asm_Input ("m", Item.Value), Volatile => True);