Bug 20730 - Assembler illegal subtraction in libffi on Solaris 8 Intel
Summary: Assembler illegal subtraction in libffi on Solaris 8 Intel
Status: RESOLVED DUPLICATE of bug 26048
Alias: None
Product: gcc
Classification: Unclassified
Component: libffi (show other bugs)
Version: 4.0.0
: P2 normal
Target Milestone: ---
Assignee: Rainer Orth
URL:
Keywords: build
Depends on: 26048
Blocks:
  Show dependency treegraph
 
Reported: 2005-04-02 16:07 UTC by Peter Felecan
Modified: 2010-04-28 21:03 UTC (History)
3 users (show)

See Also:
Host: i386-pc-solaris2.8
Target: i386-pc-solaris2.8
Build: i386-pc-solaris2.8
Known to work:
Known to fail:
Last reconfirmed: 2010-04-28 21:02:31


Attachments
bootstrap log's tail (466 bytes, text/plain)
2005-04-02 16:10 UTC, Peter Felecan
Details
compiler run with verbose flag (817 bytes, text/plain)
2005-04-02 16:10 UTC, Peter Felecan
Details
preprocessor run (433 bytes, text/plain)
2005-04-02 16:12 UTC, Peter Felecan
Details
the assembler output (246 bytes, text/plain)
2005-04-02 16:13 UTC, Peter Felecan
Details
the preprocessed source (548 bytes, text/plain)
2005-04-02 16:13 UTC, Peter Felecan
Details
the configuration log for the library (7.00 KB, text/plain)
2005-04-02 16:14 UTC, Peter Felecan
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Felecan 2005-04-02 16:07:50 UTC
- The incriminated source file is libffi/src/x86/sysv.S
- Bootstrapping gcc 4.0 snapshot 20050326, fails. The relevant log's tail is in 
the attachment bootstrap.log
- The configuration log is in the config.log attachment
- Output of running the compiler with verbose options is in the attachment
verbose.log
- Output of running the prepocessor on the assembler source is in the attachment
preprocess.log and the preprocessed source is in the attachment sysv.s
- Output of running the assembler on the preprocessed source is in the
attachment assembler.log
Comment 1 Peter Felecan 2005-04-02 16:10:04 UTC
Created attachment 8514 [details]
bootstrap log's tail
Comment 2 Peter Felecan 2005-04-02 16:10:51 UTC
Created attachment 8515 [details]
compiler run with verbose flag
Comment 3 Andrew Pinski 2005-04-02 16:12:24 UTC
This does not make sense as line 91 is the following:
        jne   retdouble


Also what happens if you use GNU binutils instead of the tool chain from Sun?
Comment 4 Peter Felecan 2005-04-02 16:12:51 UTC
Created attachment 8516 [details]
preprocessor run

this phases obtains the source fed to the assembler
Comment 5 Peter Felecan 2005-04-02 16:13:26 UTC
Created attachment 8517 [details]
the assembler output
Comment 6 Peter Felecan 2005-04-02 16:13:54 UTC
Created attachment 8518 [details]
the preprocessed source
Comment 7 Peter Felecan 2005-04-02 16:14:34 UTC
Created attachment 8519 [details]
the configuration log for the library
Comment 8 Peter Felecan 2005-04-02 16:16:23 UTC
(In reply to comment #3)
> This does not make sense as line 91 is the following:
>         jne   retdouble
> 
> 
> Also what happens if you use GNU binutils instead of the tool chain from Sun?

The line 91 is in the preprocessed assembler... see the attachement containing
the source.
Comment 9 Andrew Pinski 2005-04-02 16:18:32 UTC
Ok for the preprocessed source line 91 for the preproceser source:
 .long .LFB1-.

This is valid as far as I know.
Again can you try with the GNU binutils.
Comment 10 Peter Felecan 2005-04-02 16:23:04 UTC
(In reply to comment #9)
> Ok for the preprocessed source line 91 for the preproceser source:
>  .long .LFB1-.
> 
> This is valid as far as I know.
> Again can you try with the GNU binutils.

Unfortunately, for the moment I cannot use gas. However, not being a specialist
in x86 assembler, can you confirm this such that I can look for a bug in Solaris
assembler.
Comment 11 Peter Felecan 2005-04-03 13:38:54 UTC
(In reply to comment #9)
> Ok for the preprocessed source line 91 for the preproceser source:
>  .long .LFB1-.

assembled on Solaris 10 Intel:

/usr/ccs/bin/as -V -Qy -s -o sysv.o sysv.s
as: Sun Compiler Common 10 s10_73 11/23/2004
Assembler:
         "sysv.s", line 91 : Warning: Illegal subtraction - symbols
from different sections: ".LFB1", ".DOT-0"

> This is valid as far as I know.
> Again can you try with the GNU binutils.

it's successful with gas:

gnu-as -v -o sysv.o sysv.s
GNU assembler version 2.14 (i386-pc-solaris2.8) using BFD version 2.14 20030612


Comment 12 Rainer Orth 2010-04-28 21:02:31 UTC
Mine.
Comment 13 Rainer Orth 2010-04-28 21:03:32 UTC
Dup of PR libffi/26048.

*** This bug has been marked as a duplicate of 26048 ***