The 1802's performance was terrible compared to that of the 6502 though.
A new article about 6502
- GARTHWILSON
- Forum Moderator
- Posts: 8773
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: A new article about 6502
Martin_H wrote:
Interestingly, the 1802 was an eight-bit that had sixteen-bit registers on chip. But it couldn't load them directly; all data had to pass through the D accumulator via eight bit put and get instructions. So both the 6502 and 1802 spent a fair amount of time moving data through the accumulator into the address registers.
The 1802's performance was terrible compared to that of the 6502 though.
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
- BigDumbDinosaur
- Posts: 9425
- Joined: 28 May 2009
- Location: Midwestern USA (JB Pritzker’s dystopia)
- Contact:
Re: A new article about 6502
dmsc wrote:
But this also meant that the 6502 was a dead end - there were very few opportunities for making a faster successor without completely changing the architecture, because it was tied to the RAM speed, and RAM did not increased speed at the same pace as processors.
As for a faster successor, the current version of the W65C02S with a 0.6µ TSMC core is many times faster than the original NMOS 6502. The 65C02 is officially rated at 14 MHz, and readily exceeds 20 MHz in a practical circuit. Other than the addition of some new instructions, the ISA of the 65C02 is the same as the 6502 of 40-odd years ago.
x86? We ain't got no x86. We don't NEED no stinking x86!
Re: A new article about 6502
GARTHWILSON wrote:
The 1802's performance was terrible compared to that of the 6502 though.
On the plus side. NASA chose the 1802 for the Galileo mission, so it did go to Jupiter. The built-in DMA controller and I/O lines have some merit as well. Plus you can put LED's on the N0, N1, N2, and Q lines for some blinkenlights.
- GARTHWILSON
- Forum Moderator
- Posts: 8773
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: A new article about 6502
Martin_H wrote:
GARTHWILSON wrote:
The 1802's performance was terrible compared to that of the 6502 though.
On the plus side. NASA chose the 1802 for the Galileo mission, so it did go to Jupiter. The built-in DMA controller and I/O lines have some merit as well. Plus you can put LED's on the N0, N1, N2, and Q lines for some blinkenlights.
Most instructions take 16 clock cycles, and some take 24. I seem to remember it was rad-hard though, and low-power, making it attractive for spacecraft. Having so many internal registers meant that for minimal jobs, you didn't have to use any RAM.
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
Re: A new article about 6502
Hi!
Except the 6502 family is not a dead end. If it were, Western Design Center would not be in business. In fact, it is estimated that the 65C02 in ASIC form is produced at the rate of several hundred million pieces per year.
As for a faster successor, the current version of the W65C02S with a 0.6µ TSMC core is many times faster than the original NMOS 6502. The 65C02 is officially rated at 14 MHz, and readily exceeds 20 MHz in a practical circuit. Other than the addition of some new instructions, the ISA of the 65C02 is the same as the 6502 of 40-odd years ago.
When I said "dead end" I was referring to advancing the architectures to 16 bit and beyond. Your comment sort of proves my point, even today - that people still uses the 6502 in microcontroller applications - you don't have faster designs.
Compare the 20MHz 65C02 at 0.6um with the 100MHz Pentium, the 80MHz PowerPC 601, and even the old, low power 16C84 PIC (at 1.2um) ran at 20MHz.
Of course, as a good and simple microcontroller, the 65C02 has a place!
Have Fun!
BigDumbDinosaur wrote:
dmsc wrote:
But this also meant that the 6502 was a dead end - there were very few opportunities for making a faster successor without completely changing the architecture, because it was tied to the RAM speed, and RAM did not increased speed at the same pace as processors.
As for a faster successor, the current version of the W65C02S with a 0.6µ TSMC core is many times faster than the original NMOS 6502. The 65C02 is officially rated at 14 MHz, and readily exceeds 20 MHz in a practical circuit. Other than the addition of some new instructions, the ISA of the 65C02 is the same as the 6502 of 40-odd years ago.
Compare the 20MHz 65C02 at 0.6um with the 100MHz Pentium, the 80MHz PowerPC 601, and even the old, low power 16C84 PIC (at 1.2um) ran at 20MHz.
Of course, as a good and simple microcontroller, the 65C02 has a place!
Have Fun!
- GARTHWILSON
- Forum Moderator
- Posts: 8773
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: A new article about 6502
dmsc wrote:
Compare the 20MHz 65C02 at 0.6um with the 100MHz Pentium, the 80MHz PowerPC 601, and even the old, low power 16C84 PIC (at 1.2um) ran at 20MHz.
WDC has said that they have a licensee running an '02 in an ASIC at over 200MHz. That was probably ten years ago. I have not seen any updates to know if they still are, or if they've further increased the clock rate since then. Obviously the memory, I/O, and other microprocessor support have to be all onboard the same chip, never running the processor's buses off-chip. It's a microcontroller.
Oh, and BTW, a 20MHz PIC16C84 would be about half the speed of a 20MHz 65c02, because of the 02's better instruction set, the fact that it doesn't need inefficient page and bank switching, etc.. I speak from plenty of experience on these two.
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
Re: A new article about 6502
GARTHWILSON wrote:
Oh, and BTW, a 20MHz PIC16C84 would be about half the speed of a 20MHz 65c02, because of the 02's better instruction set, the fact that it doesn't need inefficient page and bank switching, etc.. I speak from plenty of experience on these two.
https://en.wikipedia.org/wiki/XGameStation_series
Re: A new article about 6502
dmsc wrote:
This are the exact words from the 6502 programming manual:
Quote:
The 6502 has a number of features which the less enthusiastic might be inclined to call bugs or quirks.
Re: A new article about 6502
BillG wrote:
The 6502 version is not even twice as fast ...
viewtopic.php?f=2&t=6295
Re: A new article about 6502
litwr wrote:
BillG wrote:
The 6502 version is not even twice as fast ...
My manager walked into my office the other day while I was napping at my desk.
She gave me a knudge and said, "Hey, wake up! We have a problem!"
"Wha... wha... what?" I replied.
"Listen, we are getting lots of complaints from the field. Our widgets are just too slow to handle the load. If we cannot fix them, the firm will go under."
Me: "How much faster do they need to be? And at what cost?"
If her answer is: "I need all the speed you can give me. At any cost."
Then I will check this brute into source control:
Code: Select all
0000 1000 00001 Base fdb Tab
00002
0100 00003 org $100
00004
0100 00005 Start
0100 4F [2] 00006 clra
0101 C6 04 [2] 00007 ldab #1024/256
00008
0103 00009 Outer
0103 DE 00 [4] 00010 ldx Base
00011
0105 00012 Loop
0105 A8 00 [5] 00013 eora $00,X
0107 A8 01 [5] 00014 eora $01,X
0109 A8 02 [5] 00015 eora $02,X
010B A8 03 [5] 00016 eora $03,X
010D A8 04 [5] 00017 eora $04,X
010F A8 05 [5] 00018 eora $05,X
0111 A8 06 [5] 00019 eora $06,X
0113 A8 07 [5] 00020 eora $07,X
0115 A8 08 [5] 00021 eora $08,X
0117 A8 09 [5] 00022 eora $09,X
0119 A8 0A [5] 00023 eora $0A,X
011B A8 0B [5] 00024 eora $0B,X
011D A8 0C [5] 00025 eora $0C,X
011F A8 0D [5] 00026 eora $0D,X
0121 A8 0E [5] 00027 eora $0E,X
0123 A8 0F [5] 00028 eora $0F,X
0125 A8 10 [5] 00029 eora $10,X
0127 A8 11 [5] 00030 eora $11,X
0129 A8 12 [5] 00031 eora $12,X
012B A8 13 [5] 00032 eora $13,X
012D A8 14 [5] 00033 eora $14,X
012F A8 15 [5] 00034 eora $15,X
0131 A8 16 [5] 00035 eora $16,X
0133 A8 17 [5] 00036 eora $17,X
0135 A8 18 [5] 00037 eora $18,X
0137 A8 19 [5] 00038 eora $19,X
0139 A8 1A [5] 00039 eora $1A,X
013B A8 1B [5] 00040 eora $1B,X
013D A8 1C [5] 00041 eora $1C,X
013F A8 1D [5] 00042 eora $1D,X
0141 A8 1E [5] 00043 eora $1E,X
0143 A8 1F [5] 00044 eora $1F,X
0145 A8 20 [5] 00045 eora $20,X
BIG SNIP!
02C5 A8 E0 [5] 00237 eora $E0,X
02C7 A8 E1 [5] 00238 eora $E1,X
02C9 A8 E2 [5] 00239 eora $E2,X
02CB A8 E3 [5] 00240 eora $E3,X
02CD A8 E4 [5] 00241 eora $E4,X
02CF A8 E5 [5] 00242 eora $E5,X
02D1 A8 E6 [5] 00243 eora $E6,X
02D3 A8 E7 [5] 00244 eora $E7,X
02D5 A8 E8 [5] 00245 eora $E8,X
02D7 A8 E9 [5] 00246 eora $E9,X
02D9 A8 EA [5] 00247 eora $EA,X
02DB A8 EB [5] 00248 eora $EB,X
02DD A8 EC [5] 00249 eora $EC,X
02DF A8 ED [5] 00250 eora $ED,X
02E1 A8 EE [5] 00251 eora $EE,X
02E3 A8 EF [5] 00252 eora $EF,X
02E5 A8 F0 [5] 00253 eora $F0,X
02E7 A8 F1 [5] 00254 eora $F1,X
02E9 A8 F2 [5] 00255 eora $F2,X
02EB A8 F3 [5] 00256 eora $F3,X
02ED A8 F4 [5] 00257 eora $F4,X
02EF A8 F5 [5] 00258 eora $F5,X
02F1 A8 F6 [5] 00259 eora $F6,X
02F3 A8 F7 [5] 00260 eora $F7,X
02F5 A8 F8 [5] 00261 eora $F8,X
02F7 A8 F9 [5] 00262 eora $F9,X
02F9 A8 FA [5] 00263 eora $FA,X
02FB A8 FB [5] 00264 eora $FB,X
02FD A8 FC [5] 00265 eora $FC,X
02FF A8 FD [5] 00266 eora $FD,X
0301 A8 FE [5] 00267 eora $FE,X
0303 A8 FF [5] 00268 eora $FF,X
00269
0305 7C 0000 [6] 00270 inc Base
0308 5A [2] 00271 decb
0309 27 03 (030E) [4] 00272 beq Done
00273
030B 7E 0103 [3] 00274 jmp Outer
00275
030E 00276 Done
00277
1000 00278 org $1000
00279
1000 00280 Tab
5197 cycles
Then I check in this beast:
Anything more gets into diminishing returns.
Code: Select all
0000 1000 00001 Base fdb Tab
0002 00002 Count rmb 1
00003
0100 00004 org $100
00005
0100 00006 Start
0100 4F [2] 00007 clra
0101 C6 20 [2] 00008 ldab #1024/32
0103 D7 02 [4] 00009 stab Count
00010
0105 00011 Outer
0105 DE 00 [4] 00012 ldx Base
00013
0107 A8 00 [5] 00014 eora $00,X
0109 A8 01 [5] 00015 eora $01,X
010B A8 02 [5] 00016 eora $02,X
010D A8 03 [5] 00017 eora $03,X
010F A8 04 [5] 00018 eora $04,X
0111 A8 05 [5] 00019 eora $05,X
0113 A8 06 [5] 00020 eora $06,X
0115 A8 07 [5] 00021 eora $07,X
0117 A8 08 [5] 00022 eora $08,X
0119 A8 09 [5] 00023 eora $09,X
011B A8 0A [5] 00024 eora $0A,X
011D A8 0B [5] 00025 eora $0B,X
011F A8 0C [5] 00026 eora $0C,X
0121 A8 0D [5] 00027 eora $0D,X
0123 A8 0E [5] 00028 eora $0E,X
0125 A8 0F [5] 00029 eora $0F,X
0127 A8 10 [5] 00030 eora $10,X
0129 A8 11 [5] 00031 eora $11,X
012B A8 12 [5] 00032 eora $12,X
012D A8 13 [5] 00033 eora $13,X
012F A8 14 [5] 00034 eora $14,X
0131 A8 15 [5] 00035 eora $15,X
0133 A8 16 [5] 00036 eora $16,X
0135 A8 17 [5] 00037 eora $17,X
0137 A8 18 [5] 00038 eora $18,X
0139 A8 19 [5] 00039 eora $19,X
013B A8 1A [5] 00040 eora $1A,X
013D A8 1B [5] 00041 eora $1B,X
013F A8 1C [5] 00042 eora $1C,X
0141 A8 1D [5] 00043 eora $1D,X
0143 A8 1E [5] 00044 eora $1E,X
0145 A8 1F [5] 00045 eora $1F,X
00046
0147 D6 01 [3] 00047 ldab Base+1
0149 CB 20 [2] 00048 addb #32
014B D7 01 [4] 00049 stab Base+1
014D 26 03 (0152) [4] 00050 bne 2f
014F 7C 0000 [6] 00051 inc Base
00052
0152 00053 2
0152 7A 0002 [6] 00054 dec Count
0155 26 AE (0105) [4] 00055 bne Outer
6016 cycles
Edit: added some accidentally omitted code.
Last edited by BillG on Tue Sep 22, 2020 4:21 am, edited 1 time in total.
Re: A new article about 6502
litwr wrote:
BillG wrote:
The 6502 version is not even twice as fast ...
litwr wrote:
I am sure, for instance, that division for the 6800 is faster than for the 6502.
litwr wrote:
The FOR-loop statement code is too large for me and it relies on a compiler...
litwr wrote:
You know that the Z80 can be even faster than the 6502 at the same frequency but generally it is more than 2 times slower.
litwr wrote:
IMHO we need more plain algorithms. I can propose several quite simple calculations for the 6502, it will be interesting to compare them with their implementations for the 6800.
viewtopic.php?f=2&t=6295
viewtopic.php?f=2&t=6295
- GARTHWILSON
- Forum Moderator
- Posts: 8773
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: A new article about 6502
BillG wrote:
Can the 6502 even do this if it's life depended on it?
Turn up the clock speed? Bill Mensch had 6502's that'd run at 10MHz even in the 1970's.
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
Re: A new article about 6502
GARTHWILSON wrote:
BillG wrote:
Can the 6502 even do this if it's life depended on it?
Turn up the clock speed? Bill Mensch had 6502's that'd run at 10MHz even in the 1970's.
But we are talking about code quality.
What if that story took place in 1979?
Edit: Not that WDC did not have a 10MHz part, but memory at that time was not so fast. 6502 and 680x systems maxed out at 2 MHz.
Re: A new article about 6502
I think overclocking was what was meant.
Certainly the NMOS 6502, the CMOS 65C02 as well as the WDC versions can all be overclocked to some extent.
But the NMOS Z80 and the CMOS Z80 microprocessors can also be overclocked.
I don’t know about other 8 bit MPUs.
Mark
Certainly the NMOS 6502, the CMOS 65C02 as well as the WDC versions can all be overclocked to some extent.
But the NMOS Z80 and the CMOS Z80 microprocessors can also be overclocked.
I don’t know about other 8 bit MPUs.
Mark
- GARTHWILSON
- Forum Moderator
- Posts: 8773
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: A new article about 6502
The earliest 6502 data sheet I have is from Synertek, from 1979, and it lists options rated to 3MHz. Bill Mensch said in an interview that to rate a 6502 for a given speed, he required it to work on the tester at twice that speed; so a 1MHz had to work at 2, a 2MHz had to work at 4, etc.. If one worked at 5.9MHz but not 6MHz, it could not be sold as a 3MHz part, but could be sold as a 2MHz part. He also said he really did have ones working at 10MHz in the 70's.
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?