This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: About the format of floating point...



You need to define "failed". 

This could mean any number of things:

1) The compiler failed to generate an arithmetic operation, 
   such as add, subtract, multiply, etc. This is probably not
   precision related.

2) The compiler generated floating-point constants using the ".float"
   directive, but the assembler mangled them because your single
   precision format is nonstandard. This is not a compile problem
   per se. It is an assembler problem.

3) The generated code doesn't print floating point properly.
   This could be a problem with floatconv.c, which needs
   to be modified to handle your nonstandard floats.

It could be any number of other problems, but simply saying
"it failed" without any details does not help track down a bug
somewhere in over 100,000 lines of code.

Toshi

> 
> Dear all,
> 
> Now we are porting GCC as a cross-platform compiler for our Java CPU.
> We got a problem about the format of floating point...
> 
> The IEEE single-float format is: (1, 8, 23) for it's (S, E, F).
> However, our single-float format is: (1, 11, 20).
> 
> This format (1, 11, 20) is the high 32 bits for IEEE double-precision and
> we found that our compiler works fine with double precision, but failed
> in single precision since the single-float format is wrong. Is there any
> clues
> for changing the single-float format to the correct one?
> 
> By the way, we've defined our float format as IEEE_FLOAT_FORMAT
> in vax.h. And I don't know if we will get into troubles since we choose the
> vax as target machine to do our porting work for Java CPU.
> 
> Please give us some advises ^_^
> 
> ==================
> Kuo-Yu Slayer Chuang
> Computer & Communications Research Laboratories
> Software Engineer
> Industrial Technology Research Institute, Taiwan.
> E-mail: slayer@itri.org.tw
> ==================
> 
> 
> 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]