Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.compilers > #3373

Re: C arithmetic, was Software proofs, was Are there different

From gah4 <gah4@u.washington.edu>
Newsgroups comp.compilers
Subject Re: C arithmetic, was Software proofs, was Are there different
Date 2023-02-08 01:10 -0800
Organization Compilers Central
Message-ID <23-02-032@comp.compilers> (permalink)
References (1 earlier) <23-02-003@comp.compilers> <23-02-019@comp.compilers> <23-02-025@comp.compilers> <23-02-026@comp.compilers> <23-02-029@comp.compilers>

Show all headers | View raw


On Tuesday, February 7, 2023 at 6:30:40 PM UTC-8, Hans-Peter Diettrich wrote:
> On 2/6/23 10:26 PM, gah4 wrote:

> > Too bad for those CDC computers, and Unisys computers.
> > Last I know of sign-magnitude is the IBM 7090 and 7094.

> AFAIK use IEEE-754 floating point numbers still sign-magnitude
> representation.
> Then the same representation of integral numbers may have advantages in
> computations.

> [I presume the sign-magnitude is to enable the hidden bit trick,
> which doesn't apply in unscaled integers. -John]

Yes, I meant integer representation.

Well, I have been wondering for years when we get a C compiler
for the 7090 so we can test out sign-magnitude integers.

I think the 7090 does 16 bit integers, at least that is what
its Fortran compilers did, stored in 36 bit words.

As for floating point, the PDP-10 uses a two's complement
floating point format.  It does two's complement on the
whole 36 bit word.  The result is that fixed point compare
instructions work on floating point values.
[The 704x/709x series did 36 bit sign-magnitude arithmetic.  Fortran
integers were limited to 15 bits plus a sign, probably because that
was the size of addresses, and they expected integer arithmetic to
be used only for counting and subscripts.  In 709 Fortran II they
expanded them to 17 bits, in 7090 Fortran IV they were finally a
full word. -John]

Back to comp.compilers | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Re: Are there different programming languages that are compiled to the same intermediate language? Martin Ward <mwardgkc@gmail.com> - 2023-01-31 14:04 +0000
  Re: Are there different programming languages that are compiled to the same intermediate language? arnold@freefriends.org (Aharon Robbins) - 2023-02-01 08:07 +0000
    Re: Software proofs, was Are there different programming languages that are compiled to the same intermediate language? Spiros Bousbouras <spibou@gmail.com> - 2023-02-05 15:14 +0000
      Re: C arithmetic, was Software proofs, was Are there different Keith Thompson <Keith.S.Thompson+u@gmail.com> - 2023-02-05 16:14 -0800
        Re: C arithmetic, was Software proofs, was Are there different gah4 <gah4@u.washington.edu> - 2023-02-06 13:26 -0800
          Re: C arithmetic, was Software proofs, was Are there different Hans-Peter Diettrich <DrDiettrich1@netscape.net> - 2023-02-07 14:31 +0100
            Re: C arithmetic, was Software proofs, was Are there different gah4 <gah4@u.washington.edu> - 2023-02-08 01:10 -0800
              Re: C arithmetic, was Software proofs, was Are there different gah4 <gah4@u.washington.edu> - 2023-02-09 00:26 -0800
                Re: C arithmetic, was Software proofs, was Are there different gah4 <gah4@u.washington.edu> - 2023-02-11 00:01 -0800
                Re: C arithmetic, was Software proofs, was Are there different drb@ihatespam.msu.edu (Dennis Boone) - 2023-02-12 04:37 +0000
            Re: C arithmetic, was Software proofs, was Are there different anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2023-02-08 10:19 +0000
              Re: C arithmetic, was Software proofs, was Are there different Hans-Peter Diettrich <DrDiettrich1@netscape.net> - 2023-02-10 19:11 +0100
                Re: C arithmetic, was Software proofs, was Are there different gah4 <gah4@u.washington.edu> - 2023-02-10 23:47 -0800
                Re: C arithmetic, was Software proofs, was Are there different anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2023-02-11 22:34 +0000
                Re: old floating point, C arithmetic, was Software proofs, was Are there different gah4 <gah4@u.washington.edu> - 2023-02-11 22:48 -0800
            Re: C arithmetic, was Software proofs, was Are there different Hans-Peter Diettrich <DrDiettrich1@netscape.net> - 2023-02-08 15:24 +0100
              Re: C arithmetic, was Software proofs, was Are there different gah4 <gah4@u.washington.edu> - 2023-02-09 00:37 -0800

csiph-web