ant…@mips.complang.tuwien.ac.at (Anton Ertl) posted:
> Tim Rentsch <tr.1…@z991.linuxsc.com> writes:
> >ant…@mips.complang.tuwien.ac.at (Anton Ertl) writes:
> >> I have the benefit of hindsight. You also have that, but you imply > >> that the architects of the PDP-11, 6800, 6502, Z80 (the first > >> Datapoint 2200 descendent that also had an overflow flag) and 8086 > >> (the first in that line from Intel with an overflow flag), 68000, > >> etc. didn't know what they were doing when they selected NZCV instead > >> of following the example of S/360.
> > > >I implied no such thing. Those processors were designed under > >different circumstances and having very different constraints.
> > And in what way would these circumstances and constraints influence > the outcome?
When one designs an ISA where the data-path is 8-wide, flags are an anathema--so flags (as we understand them) would not make the cut. But those ISAs were before that kind of constraint, so they get a pass.
> It seems to me that the circumstances and constraints were not that > different. The S/360 designers had to design an instruction set that > can be implemented with low hardware resources, just like the PDP-11 > designers and the microprocessor designers. And they used binary > representation and two's-complement representation of signed numbers, > like the others.
We are no longer in that world, an entire S/360/67 is no larger than a single I/O Pad (which can toggle at 16 GHz). Give them a pass, but realize we don't want to do those things again.
> If they had seen the examples of the architectures mentioned before > designing the S/360, would they have designed the flag-handling of the > S/360 as they did? I doubt it. There is a reason why so many > architectures chose NZCV flags (if they chose flags at all). And even > the few that don't use the NZCV flags do not handle flags in the S/360 > way, not even Power.
Even COZAPS is an anathema at 8-wide, Athlon and Opteron used as much circuitry to track {C, O, ZAPS} independently than we used to track Src1 and Src2 through the GBOoO...
> - anton