PIC17C42 Microchip Technology, PIC17C42 Datasheet - Page 49

no-image

PIC17C42

Manufacturer Part Number
PIC17C42
Description
High-Performance 8-Bit CMOS EPROM/ROM Microcontroller
Manufacturer
Microchip Technology
Datasheets

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
PIC17C42-16/JW
Manufacturer:
AD
Quantity:
12
Part Number:
PIC17C42A-16/L
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC17C42A-16/PQ
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC17C42A-16/PQ
Manufacturer:
MICROCH
Quantity:
20 000
Part Number:
PIC17C42A-16/PT
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC17C42A-16E/L
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC17C42A-16E/PQ
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC17C42A-25/P
Manufacturer:
MICROCLOCK
Quantity:
20 000
8.0
All PIC17C4X devices except the PIC17C42, have an
8 x 8 hardware multiplier included in the ALU of the
device. By making the multiply a hardware operation, it
completes in a single instruction cycle. This is an
unsigned multiply that gives a 16-bit result. The result
is
(PRODH:PRODL). The multiplier does not affect any
flags in the ALUSTA register.
Making the 8 x 8 multiplier execute in a single cycle
gives the following advantages:
• Higher computational throughput
• Reduces code size requirements for multiply
The performance increase allows the device to be used
in applications previously reserved for Digital Signal
Processors.
Table 8-1 shows a performance comparison between
the PIC17C42 and all other PIC17CXX devices, which
have the single cycle hardware multiply.
Example 8-1 shows the sequence to do an 8 x 8
unsigned multiply. Only one instruction is required
when one argument of the multiply is already loaded in
the WREG register.
TABLE 8-1:
8 x 8 unsigned
8 x 8 signed
16 x 16 unsigned
16 x 16 signed
1996 Microchip Technology Inc.
algorithms
stored
Routine
HARDWARE MULTIPLIER
into
PERFORMANCE COMPARISON
the
PIC17C42
All other PIC17CXX devices
PIC17C42
All other PIC17CXX devices
PIC17C42
All other PIC17CXX devices
PIC17C42
All other PIC17CXX devices
16-bit
This document was created with FrameMaker 4 0 4
Device
PRODuct
register
Program Memory
(Words)
13
21
24
52
36
1
6
Example 8-2 shows the sequence to do an 8 x 8 signed
multiply. To account for the sign bits of the arguments,
each argument’s most significant bit (MSb) is tested
and the appropriate subtractions are done.
EXAMPLE 8-1:
EXAMPLE 8-2:
MOVFP
MULWF
MOVFP
MULWF
BTFSC
SUBWF
MOVFP
BTFSC
SUBWF
Cycles (Max)
ARG1, WREG
ARG2
ARG1, WREG
ARG2
ARG2, SB
PRODH, F
ARG2, WREG
ARG1, SB
PRODH, F
242
254
69
24
36
1
6
8 x 8 MULTIPLY ROUTINE
8 x 8 SIGNED MULTIPLY
ROUTINE
PIC17C4X
@ 25 MHz
11.04 s
38.72 s
40.64 s
3.84 s
5.76 s
160 ns
960 ns
; ARG1 * ARG2 ->
;
; ARG1 * ARG2 ->
;
; Test Sign Bit
; PRODH = PRODH
;
; Test Sign Bit
; PRODH = PRODH
;
PRODH:PRODL
PRODH:PRODL
DS30412C-page 49
Time
@ 33 MHz
- ARG1
- ARG2
2.91 s
4.36 s
121 ns
727 ns
N/A
N/A
N/A
N/A

Related parts for PIC17C42