Comparison of Parallel and Pipelined CORDIC Algorithm Using RCA and CSA

Comparison of Parallel and Pipelined CORDIC Algorithm Using RCA and CSA

Comparison of Parallel and Pipelined CORDIC algorithm using RCA and CSA Diego Barragan´ Guerrero Lu´ıs Geraldo P. Meloni FEEC - UNICAMP FEEC - UNICAMP Campinas, Sao˜ Paulo, Brazil, 13083-852 Campinas, Sao˜ Paulo, Brazil, 13083-852 +5519 9308-9952 +5519 9778-1523 [email protected] [email protected] Abstract— This paper presents an implementation of the algorithm has two modes of operation: the rotational mode CORDIC algorithm in digital hardware using two types of (RM) where the vector (xi; yi) is rotated by an angle θ to algebraic adders: Ripple-Carry Adder (RCA) and Carry-Select obtain a new vector (x ; y ), and the vectoring mode (VM) Adder (CSA), both in parallel and pipelined architectures. Anal- N N ysis of time performance and resources utilization was carried in which the algorithm computes the modulus R and phase α out by changing the algorithm number of iterations. These results from the x-axis of the vector (x0; y0). The basic principle of demonstrate the efficiency in operating frequency of the pipelined the algorithm is shown in Figure 1. architecture with respect to the parallel architecture. Also it is shown that the use of CSA reduce the timing processing without significantly increasing the slice use. The code was synthesized us- ing FPGA development tools for the Xilinx Spartan-3E xc3s500e ' ' E N y family. N E N Index Terms— CORDIC, pipelined, parallel, RCA, CSA, y N trigonometrics functions. Rotação Pseudo-rotação R N I. INTRODUCTION E i In Digital Signal Processing with FPGA, trigonometric y i R i functions are used in many signal algorithms, for instance N synchronization and equalization [12]. As a first approach, we can use Taylor series to approximate these functions, then ' x N x N x i the problem is to cut down into a series of multiplication and addition operations, but the program is complex and the consumption of resources is high, which is not very Fig. 1. CORDIC: RM and VM. convenient. A more effective method to solve this problem is based on Coordinate Rotation Digital Computer (CORDIC). The CORDIC algorithm, executed by a finite number of N The CORDIC algorithm provides an iterative method for micro-rotations indexed by i = 0: N-1, was originally described performing vector rotations by arbitrary angles using only for a circular coordinate system [9], then the algorithm was shifts and adds [13]. CORDIC based VLSI architectures are extended to linear and hyperbolic systems and described very attractive alternatives to the architectures based on con- briefly in the following set of equations [14]. ventional multiply-and-add hardware for an extensive variety −i y of DSP algorithms. xi+1 = xi −m di 2 i (1) −i In this article, we present a FPGA implementation of yi+1 = yi + di 2 xi (2) CORDIC algorithm employing two class of adders (RCA and CSA) and two types of architectures (parallel unrolled and zi+1 = zi − di αi (3) pipelined). By taking use of EDA Xilinx tools and hardware n2−i; Linear αi = −1 −i (4) description language VHDL, the algorithms were implemented tan (2 ); Circular n and verified. −sign(yi); for V M i = (5) d sign(zi); for RM II. CORDIC ALGORITHM PRINCIPLE By choosing appropriate values for the parameters m and CORDIC is a versatile algorithm to compute a wide range αi, we can select the different coordinate systems. When m −1 −i −i of operations including logarithmic, hyperbolic, linear, and = 0, 1 or -1, and the values of αi are tan 2 , 2 , or trigonometric functions [3]. The CORDIC algorithm provides tanh−1 2−i the algorithm operates in linear, circular, and an iterative method for performing vector rotations or a vector hyperbolic coordinate systems, respectively, which provides translation by arbitrary angles using only shifts and adds. The the following result for rotation mode. z i MSB(y) y i x i xn = An [x0 cos z0 − y0 sin z0] (6) Tab[0] >>0 >>0 yn = An [y0 cos z0 + x0 sin z0] (7) A B A B A B s s s MSB(y) zn = 0 (8) Tab[1] >>1 >>1 Y p −2i An = 1 + 2 (9) A B A B A B n s s s MSB(y) . And for vectoring mode. q MSB(y) 2 2 xn = An x0 + y0 (10) Tab[n-1] >>n-1 >>n-1 A B A B A B yn = 0 (11) s s s y −1 y0 zn n xn zn = z0 + tan (12) x0 Fig. 2. Parallel CORDIC architecture. Y p −2i An = 1 + 2 (13) n z i MSB(y) y i x i In both cases, the rotation algorithm has a gain of An that Tab[0] depends on the number of iterations. >>0 >>0 A B A B A B III. PARALLEL, PIPELINED, RCA AND CSA s s s ARCHITECTURES Pipelined Register A. Parallel and pipelined architectures MSB(y) CORDIC is an iterative algorithm that has the same compo- Tab[1] >>1 >>1 nents at each step of pseudo-rotation: three algebraic adders, A B A B A B two shifters, one inverter and a LUT containing the value of s s s α MSB(y) i. Pipelined Register . Parallel architecture, showed in Figure 2, results in two sig- . nificant simplifications. First the shifters are each a fixed shift, MSB(y) which means that they can be implemented by wiring. Second, Tab[n-1] >>n-1 >>n-1 the lookup values for the angle accumulator are distributed as constants to each adder in the angle accumulator chain. A B A B A B Those constants can be hardwired instead of using storage s s s space. The need for registers is also eliminated, making the zn y n xn unrolled processor strictly combinatorial. However, in order to measure the operating frequency of the architecture, a register was added both the input and output of the circuit. Fig. 3. Pipelined CORDIC architecture. The parallel architecture is easily pipelined by inserting registers between every iteration step. In the case of most B. RCA and CSA architectures FPGA architectures there are already registers present in each logic cell, so the addition of the pipeline registers has no Because the CORDIC algorithm needs to perform a binary additional hardware cost [2]. A pipelined design conceptually sum several times throughout the process, we have imple- works very similar to an assembly line in that the raw material mented two types of adders in order to quantify the effect or data inputs enter the front end, they pass through various on processing time and resource consumption of the FPGA. stages of manipulation and processing, and then exist as a While Ripple-Carry Adders (RCA) have the most compact finished products or data outputs. The beauty of pipelined design (O (n) area) among all types of adders, they are the design is that new data can begin processing before the prior slowest types of adders (O (n) time). On the other hand, Carry data has finished. Pipelines are used in nearly all very-high- Look-ahead Adder (CLA) are the fastest adders (O (log (n)) performance devices [7]. Figure 3 show pipelined architecture. time), but they are the worst from the area point of view (O (n log (n)) area). Carry-Select Adder (CSA) have been calculated in parallel. When the actual carry-in signal for the consideredp as a compromise solution between RCAs and block arrives, multiplexers are used to select the correct one of CLAs (O ( n) time and O (2n) area) because they offer a both precalculated partial sums. Also, the resulting carry-out good tradeoff between the compact area of RCA and the short is selected and propagated to the next carry-select block [6]. delay of CLA [1]. Thereby, the architectures were chosen are In other words, the Carry-Select Adder improves speed further Ripple-Carry Adder and Carry-Select Adder [5] [11]. Figure with more hardware. 4 present RCA arqcitecture. Thus, the sum bits si and group outgoing carry ci+1 signals can be expressed as. Y(n-1) X(n-1) Y(2) X(2) Y(1) X(1) Y(0) X(0) 0 0 M sm = sm c¯j + sm cj; m = j; j + 1; :::; i (18) 0 1 ci+1 = ci+1 c¯j + ci+1 cj (19) C C I C C ... C C C O n I I O O O ( n n ( The Figure 5 shows the CSA architecture. n n ( ( ( ( Full Adder Full Adder ( Full Adder Full Adder - 2 1 0 1 2 - 1 1 ) ) ) ) ) ) ) S(n-1) S(2) S(1) S(0) , ,..., xi x i1 x j k , ,..., yi y i1 y j Y(n-1) X(n-1) Y(2) X(2) Fig. 4. Ripple Carry Adder. Signal 0 C i1 C C C E c S E S ( ( n n ( The Ripple-Carry Adder is composed of a chain of full Full Adder Full Adder ( 2 2 0 - - 1 1 ) ) ) adders with length n, where n is the length of the input ) operands. The following boolean expressions describe the full 2 : 1 M U adder. c i1 X Y(n-1) X(n-1) Y(2) X(2) Sinal 0, 0 ,..., 0 p = a ⊕ b (14) si s i1 s j C C C C E S E S ( ( n n Y(1) X(1) y(0) X(0) ( Full Adder Full Adder ( 1 2 2 - - 1 1 ) ) ) g = a • b (15) 1 ) ci1 M Where ⊕ is exclusive OR and • represent AND operation c j C 1 1 1 C C E S S ( ( Full Adder ( Full Adder 1 0 , ,..., 2:1 MUX 1 ) ) and where a and b are the input operands and p and g si s i1 s j ) are the propagate and generate signals respectively.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    4 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us