This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
-msoft-float and assembler...
- To: GCC Mailing List <gcc at gcc dot gnu dot org>
- Subject: -msoft-float and assembler...
- From: Scott Bambrough <scottb at netwinder dot org>
- Date: Wed, 17 May 2000 18:19:17 -0400
- Organization: Rebel.com
If I try to compile the code below with `gcc -S -msoft-float sf.S`, it seems the
define __SOFT_FP__ is not passed to the assembler. Should it be? I ran into
this when building a multilibbed version of libgcj. There is some assembler in
libffi for calling foreign functions that uses floating point instructions. I
was trying to conditionally compile that file.
file: sf.S
@ Generated by gcc 2.95.2 20000212 (release) [Rebel.com] for ARM/elf
.file "sf.c"
gcc2_compiled.:
.text
.align 2
.global main
.type main,function
main:
@ args = 0, pretend = 0, frame = 8
@ frame_needed = 1, current_function_anonymous_args = 0
mov ip, sp
stmfd sp!, {fp, ip, lr, pc}
sub fp, ip, #4
sub sp, sp, #8
str r0, [fp, #-16]
str r1, [fp, #-20]
#ifdef __SOFT_FP__
@ compiled with -msoft-float
#else
@ compiled with hard float
#endif
.L2:
ldmea fp, {fp, sp, pc}
.Lfe1:
.size main,.Lfe1-main
.ident "GCC: (GNU) 2.95.2 20000212 (release) [Rebel.com]"
Scott
--
Scott Bambrough - Software Engineer
REBEL.COM http://www.rebel.com
NetWinder http://www.netwinder.org