public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
@ 2015-04-01  3:09 skunk at iskunk dot org
  2015-04-01  7:35 ` [Bug target/65644] " ubizjak at gmail dot com
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: skunk at iskunk dot org @ 2015-04-01  3:09 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

            Bug ID: 65644
           Summary: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not
                    a valid 64 bit base/index expression
           Product: gcc
           Version: 4.9.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: skunk at iskunk dot org
              Host: x86_64-pc-solaris2.10
            Target: x86_64-pc-solaris2.10
             Build: x86_64-pc-solaris2.10

Created attachment 35197
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=35197&action=edit
test case

I built GCC 4.9.2 on a Solaris 10 system on x86-64, and then compiled a C
codebase that does some 64-bit-unsafe things (notably, assuming that pointers
are 32 bits, by casting unsigned ints to pointers). This resulted in "cast to
pointer from integer of different size" warnings as well as errors of the form

    {standard input}: Assembler messages:
    {standard input}:233: Error: `(%esi)' is not a valid 64 bit base/index
expression
    {standard input}:250: Error: `(%edx)' is not a valid 64 bit base/index
expression
    {standard input}:1150: Error: `(%edx)' is not a valid 64 bit base/index
expression

I have prepared a small test case that exhibits this same failure mode:

    $ gcc -m64 -O -c gcc-asm-bug.c
    gcc-asm-bug.c: In function 'foo1':
    gcc-asm-bug.c:14:4: warning: cast to pointer from integer of different size
[-Wint-to-pointer-cast]
       ((struct foo_struct *)xptr)->one = val;
        ^
    gcc-asm-bug.c: In function 'foo2':
    gcc-asm-bug.c:19:4: warning: cast to pointer from integer of different size
[-Wint-to-pointer-cast]
       ((struct foo_struct *)xptr)->two = val;
        ^
    /var/tmp//ccI3ovqk.s: Assembler messages:
    /var/tmp//ccI3ovqk.s:6: Error: `(%edi)' is not a valid 64 bit base/index
expression

No such error occurs when I compile this source on a Linux system, so this may
have to do with the Solaris assembler.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
@ 2015-04-01  7:35 ` ubizjak at gmail dot com
  2015-04-01  7:43 ` jakub at gcc dot gnu.org
                   ` (9 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: ubizjak at gmail dot com @ 2015-04-01  7:35 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

--- Comment #1 from Uroš Bizjak <ubizjak at gmail dot com> ---
(In reply to Daniel Richard G. from comment #0)

> No such error occurs when I compile this source on a Linux system, so this
> may have to do with the Solaris assembler.

This is perfectly valid addr32 prefixed address:

(set (mem:SI (zero_extend:DI (reg/v:SI 5 di)))
     (reg/v:SI 4 si [orig:90 val ] [90]))

0000000000000000 <foo1>:
   0:   67 89 37                addr32 mov %esi,(%edi)
   3:   c3                      retq   

I don't know why Solaris assembler emits error here. It should be at most a
warning.
>From gcc-bugs-return-482457-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Apr 01 07:41:31 2015
Return-Path: <gcc-bugs-return-482457-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 122982 invoked by alias); 1 Apr 2015 07:41:31 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 122946 invoked by uid 48); 1 Apr 2015 07:41:28 -0000
From: "ossman at cendio dot se" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/42159] unwinding issues on darwin
Date: Wed, 01 Apr 2015 07:41:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 4.4.2
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ossman at cendio dot se
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-42159-4-NDMWUtDixh@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-42159-4@http.gcc.gnu.org/bugzilla/>
References: <bug-42159-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2015-04/txt/msg00009.txt.bz2
Content-length: 781

https://gcc.gnu.org/bugzilla/show_bug.cgi?idB159

--- Comment #32 from Pierre Ossman <ossman at cendio dot se> ---
(In reply to Jack Howarth from comment #31)
>
> You might check out the original posting on this issue...
>
> http://lists.cs.uiuc.edu/pipermail/llvmdev/2009-September/025900.html
>

I believe that was one of the posts we found and what made us look at which
unwind implementation was used.

> IMHO, the static linkage of -lgcc_eh is evil as it potentially breaks the
> requirement that only a single unwinder (always the system one) be used.

I can understand that. But in that case why keep the gcc unwinder on OS X? If
it doesn't work then including it is just an accident waiting to happen. I
would suggest something along the lines of the attached patch.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
  2015-04-01  7:35 ` [Bug target/65644] " ubizjak at gmail dot com
@ 2015-04-01  7:43 ` jakub at gcc dot gnu.org
  2015-04-01  8:01 ` ubizjak at gmail dot com
                   ` (8 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: jakub at gcc dot gnu.org @ 2015-04-01  7:43 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org,
                   |                            |ro at gcc dot gnu.org,
                   |                            |uros at gcc dot gnu.org

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
(%edi) etc. in 64-bit mode should be assembled as addr32 (0x67) prefix on the
instruction.  If Solaris assembler doesn't handle it, guess first somebody
needs to investigate if it has a different syntax for the same thing, or just
doesn't support it at all, what versions are affected etc.
If it doesn't support it at all, it would mean -mx32 support would be
impossible, and the addr32 pieces in e.g. ix86_decompose_address would need to
be disabled based on some configure macro.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
  2015-04-01  7:35 ` [Bug target/65644] " ubizjak at gmail dot com
  2015-04-01  7:43 ` jakub at gcc dot gnu.org
@ 2015-04-01  8:01 ` ubizjak at gmail dot com
  2015-04-01 13:39 ` ro at CeBiTec dot Uni-Bielefeld.DE
                   ` (7 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: ubizjak at gmail dot com @ 2015-04-01  8:01 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

--- Comment #3 from Uroš Bizjak <ubizjak at gmail dot com> ---
(In reply to Jakub Jelinek from comment #2)

> impossible, and the addr32 pieces in e.g. ix86_decompose_address would need
> to be disabled based on some configure macro.

In this case, a better place for the test is just after

/* Index and base should have the same mode.  */

check in ix86_legitimate_address_p.
>From gcc-bugs-return-482464-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Apr 01 08:02:40 2015
Return-Path: <gcc-bugs-return-482464-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 63332 invoked by alias); 1 Apr 2015 08:02:40 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 63291 invoked by uid 48); 1 Apr 2015 08:02:36 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/65646] [5 Regression] ICE in invalid syntax
Date: Wed, 01 Apr 2015 08:02:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 5.0
X-Bugzilla-Keywords: ice-on-invalid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 5.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-65646-4-fpD8q9Oo4T@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-65646-4@http.gcc.gnu.org/bugzilla/>
References: <bug-65646-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2015-04/txt/msg00016.txt.bz2
Content-length: 151

https://gcc.gnu.org/bugzilla/show_bug.cgi?ide646

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Started with r213641.  Reducing.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
                   ` (2 preceding siblings ...)
  2015-04-01  8:01 ` ubizjak at gmail dot com
@ 2015-04-01 13:39 ` ro at CeBiTec dot Uni-Bielefeld.DE
  2015-04-01 14:14 ` ubizjak at gmail dot com
                   ` (6 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: ro at CeBiTec dot Uni-Bielefeld.DE @ 2015-04-01 13:39 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

--- Comment #4 from ro at CeBiTec dot Uni-Bielefeld.DE <ro at CeBiTec dot Uni-Bielefeld.DE> ---
> --- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
> (%edi) etc. in 64-bit mode should be assembled as addr32 (0x67) prefix on the
> instruction.  If Solaris assembler doesn't handle it, guess first somebody
> needs to investigate if it has a different syntax for the same thing, or just
> doesn't support it at all, what versions are affected etc.
> If it doesn't support it at all, it would mean -mx32 support would be
> impossible, and the addr32 pieces in e.g. ix86_decompose_address would need to
> be disabled based on some configure macro.

The versions of /usr/ccs/bin/as I have assemble it just fine, on both
Solaris 10 and 11.  I haven't investigated the original Solaris 10 FCS
assembler, but suggest just installing the latest assembler patch
(119961-11) and be done with it.

    Rainer


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
                   ` (3 preceding siblings ...)
  2015-04-01 13:39 ` ro at CeBiTec dot Uni-Bielefeld.DE
@ 2015-04-01 14:14 ` ubizjak at gmail dot com
  2015-04-02 20:31 ` skunk at iskunk dot org
                   ` (5 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: ubizjak at gmail dot com @ 2015-04-01 14:14 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

Uroš Bizjak <ubizjak at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |INVALID

--- Comment #5 from Uroš Bizjak <ubizjak at gmail dot com> ---
Not a GCC bug then.
>From gcc-bugs-return-482507-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Apr 01 14:21:31 2015
Return-Path: <gcc-bugs-return-482507-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 125294 invoked by alias); 1 Apr 2015 14:21:30 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 124271 invoked by uid 48); 1 Apr 2015 14:21:19 -0000
From: "drivshin at allworx dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug preprocessor/61977] [4.8/4.9/5 Regression] powerpc preprocessor breaks on lines that end with "vector"
Date: Wed, 01 Apr 2015 14:21:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: preprocessor
X-Bugzilla-Version: 4.9.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: drivshin at allworx dot com
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: jakub at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 4.8.5
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-61977-4-WgVqZdGufJ@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-61977-4@http.gcc.gnu.org/bugzilla/>
References: <bug-61977-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2015-04/txt/msg00059.txt.bz2
Content-length: 1132

https://gcc.gnu.org/bugzilla/show_bug.cgi?ida977

--- Comment #9 from David Rivshin <drivshin at allworx dot com> ---
I think the extra newline is the result of maybe_print_line() being invoked
when trying to peek past a newline in the input.

#0  maybe_print_line_1 (src_loc\x134, stream=0x361e3b8800 <_IO_2_1_stdout_>) at
c-ppoutput.c:352
#1  maybe_print_line (src_loc\x134) at c-ppoutput.c:385
#2  do_line_change (pfile=0x1ef2910, token=0x1f1dd68, src_loc\x134,
parsing_args=0) at c-ppoutput.c:463
#3  cb_line_change (pfile=0x1ef2910, token=0x1f1dd68, parsing_args=0) at
c-ppoutput.c:490
#4  _cpp_lex_token (pfile=0x1ef2910) at lex.c:2192
#5  cpp_peek_token (pfile=0x1ef2910, index=0) at lex.c:2085
#6  cpp_get_token_1 (pfile=0x1ef2910, location=0x7fffffffd8fc) at macro.c:2501

If I'm understanding the logic correctly, when _cpp_lex_direct() sees the
newline, the processing of the line is considered complete, and therefore that
line of output complete. But because of the conditional macro that's not
entirely true, and the output only has the line up to (but not including) the
conditional macro token itself at that point.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
                   ` (4 preceding siblings ...)
  2015-04-01 14:14 ` ubizjak at gmail dot com
@ 2015-04-02 20:31 ` skunk at iskunk dot org
  2015-04-06 20:29 ` skunk at iskunk dot org
                   ` (4 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: skunk at iskunk dot org @ 2015-04-02 20:31 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

--- Comment #6 from Daniel Richard G. <skunk at iskunk dot org> ---
My admin installed 119961-13, which is the current version of 119961-11:

    $ /usr/ccs/bin/as -V
    as: SunOS 5.10 119961-13 Patch 08/06/2014
     Usage: as [-a32] [-m] [-m32] [-m64] [-n]
    [...]

I'm still getting the same assembler error.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
                   ` (5 preceding siblings ...)
  2015-04-02 20:31 ` skunk at iskunk dot org
@ 2015-04-06 20:29 ` skunk at iskunk dot org
  2015-04-07 14:33 ` ro at CeBiTec dot Uni-Bielefeld.DE
                   ` (3 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: skunk at iskunk dot org @ 2015-04-06 20:29 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

Daniel Richard G. <skunk at iskunk dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |UNCONFIRMED
         Resolution|INVALID                     |---

--- Comment #7 from Daniel Richard G. <skunk at iskunk dot org> ---
Reopening due to lack of resolution.

If system patches should resolve the issue, then I am open to trying any that
are appropriate; if they work, then they can be noted in the documentation. But
it is also possible that this is a limitation of this particular version of
Solaris that cannot be patched, and thus will need a workaround in GCC.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
                   ` (6 preceding siblings ...)
  2015-04-06 20:29 ` skunk at iskunk dot org
@ 2015-04-07 14:33 ` ro at CeBiTec dot Uni-Bielefeld.DE
  2015-04-08  5:38 ` skunk at iskunk dot org
                   ` (2 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: ro at CeBiTec dot Uni-Bielefeld.DE @ 2015-04-07 14:33 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

--- Comment #8 from ro at CeBiTec dot Uni-Bielefeld.DE <ro at CeBiTec dot Uni-Bielefeld.DE> ---
> --- Comment #7 from Daniel Richard G. <skunk at iskunk dot org> ---
> Reopening due to lack of resolution.
>
> If system patches should resolve the issue, then I am open to trying any that
> are appropriate; if they work, then they can be noted in the documentation. But
> it is also possible that this is a limitation of this particular version of
> Solaris that cannot be patched, and thus will need a workaround in GCC.

Looking closer, you are *not* using the Solaris assembler (/usr/ccs/bin/as):

    {standard input}: Assembler messages:
    {standard input}:233: Error: `(%esi)' is not a valid 64 bit base/index
expression
    {standard input}:250: Error: `(%edx)' is not a valid 64 bit base/index
expression
    {standard input}:1150: Error: `(%edx)' is not a valid 64 bit base/index
expression

as cannot read from standard input, and doesn't contain the messages you
cite, while gas does.

To reproduce this, you need to provide much more information:

* How exactly was gcc configured?

* Please provide the output of

  gcc -v -m64 -O -c gcc-asm-bug.c

  for your testcase?

It might that the assembler used at configure and compile time differs,
e.g. you configured gcc to use as, but somehow it finds gas instead at
compile time.

    Rainer


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
                   ` (7 preceding siblings ...)
  2015-04-07 14:33 ` ro at CeBiTec dot Uni-Bielefeld.DE
@ 2015-04-08  5:38 ` skunk at iskunk dot org
  2015-04-08  9:43 ` ro at CeBiTec dot Uni-Bielefeld.DE
  2015-04-09 21:56 ` skunk at iskunk dot org
  10 siblings, 0 replies; 12+ messages in thread
From: skunk at iskunk dot org @ 2015-04-08  5:38 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

--- Comment #9 from Daniel Richard G. <skunk at iskunk dot org> ---
(In reply to ro@CeBiTec.Uni-Bielefeld.DE from comment #8)
> 
> Looking closer, you are *not* using the Solaris assembler (/usr/ccs/bin/as):

Good call, Rainer. GCC is in fact using /usr/sfw/bin/gas, which identifies as

    $ /usr/sfw/bin/gas --version
    GNU assembler 2.15
    Copyright 2002 Free Software Foundation, Inc.

I am bootstrapping again with explicit use of the Solaris assembler to confirm
that everything works that way, but am running into stage2 != stage3 errors and
am currently sorting those out.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
                   ` (8 preceding siblings ...)
  2015-04-08  5:38 ` skunk at iskunk dot org
@ 2015-04-08  9:43 ` ro at CeBiTec dot Uni-Bielefeld.DE
  2015-04-09 21:56 ` skunk at iskunk dot org
  10 siblings, 0 replies; 12+ messages in thread
From: ro at CeBiTec dot Uni-Bielefeld.DE @ 2015-04-08  9:43 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

--- Comment #10 from ro at CeBiTec dot Uni-Bielefeld.DE <ro at CeBiTec dot Uni-Bielefeld.DE> ---
> --- Comment #9 from Daniel Richard G. <skunk at iskunk dot org> ---
> (In reply to ro@CeBiTec.Uni-Bielefeld.DE from comment #8)
>> 
>> Looking closer, you are *not* using the Solaris assembler (/usr/ccs/bin/as):
>
> Good call, Rainer. GCC is in fact using /usr/sfw/bin/gas, which identifies as
>
>     $ /usr/sfw/bin/gas --version
>     GNU assembler 2.15
>     Copyright 2002 Free Software Foundation, Inc.

... which is pretty ancient by now.  No idea when I last tried to
bootstrap with that version, although install.texi claims that it does
work ;-(

> I am bootstrapping again with explicit use of the Solaris assembler to confirm
> that everything works that way, but am running into stage2 != stage3 errors and
> am currently sorting those out.

Ok, let me know how things work out and if I can help to get you going.

    Rainer


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug target/65644] Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression
  2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
                   ` (9 preceding siblings ...)
  2015-04-08  9:43 ` ro at CeBiTec dot Uni-Bielefeld.DE
@ 2015-04-09 21:56 ` skunk at iskunk dot org
  10 siblings, 0 replies; 12+ messages in thread
From: skunk at iskunk dot org @ 2015-04-09 21:56 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65644

Daniel Richard G. <skunk at iskunk dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |INVALID

--- Comment #11 from Daniel Richard G. <skunk at iskunk dot org> ---
(In reply to ro@CeBiTec.Uni-Bielefeld.DE from comment #10)
> Ok, let me know how things work out and if I can help to get you going.

Much appreciated :)  I have not been able to figure out the stage2 != stage3
issue, and have reported that in a new bug #65725.

So I built a non-bootstrapped 4.9.2 that uses the Solaris assembler, and it
builds the codebase without any complaints. GCC is in the clear here, and I've
thus re-closed this bug.

GCC does bootstrap successfully with this system's ancient version of the GNU
assembler, but there may be cause for the documentation to recommend a newer
version, or possibly even the Solaris assembler instead.


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2015-04-09 21:56 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-04-01  3:09 [Bug target/65644] New: Assembler errors on Solaris 10 x86-64: `(%eXX)' is not a valid 64 bit base/index expression skunk at iskunk dot org
2015-04-01  7:35 ` [Bug target/65644] " ubizjak at gmail dot com
2015-04-01  7:43 ` jakub at gcc dot gnu.org
2015-04-01  8:01 ` ubizjak at gmail dot com
2015-04-01 13:39 ` ro at CeBiTec dot Uni-Bielefeld.DE
2015-04-01 14:14 ` ubizjak at gmail dot com
2015-04-02 20:31 ` skunk at iskunk dot org
2015-04-06 20:29 ` skunk at iskunk dot org
2015-04-07 14:33 ` ro at CeBiTec dot Uni-Bielefeld.DE
2015-04-08  5:38 ` skunk at iskunk dot org
2015-04-08  9:43 ` ro at CeBiTec dot Uni-Bielefeld.DE
2015-04-09 21:56 ` skunk at iskunk dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).