pro64-support
[Top] [All Lists]

Re: Software pipelining

To: raya <raya@xxxxxxxxxxxxxxxxxxxxx>
Subject: Re: Software pipelining
From: Raymond Lo <lo@xxxxxxxxxxxxx>
Date: Mon, 19 Mar 2001 09:43:48 -0800
Cc: pro64 <pro64-support@xxxxxxxxxxx>
Organization: RouteFree Inc.
References: <3AB5CA81.42C09D3F@xxxxxxxxxxxxxxxxxxxxx>
Sender: owner-pro64-support@xxxxxxxxxxx
If my memory is correct, Itanium specifies that register write-after-read
dependence at the same cycle is legal. Please check the Itanium manuals for
confirmation.

 -Raymond


raya wrote:

> Hello,
> I do not understand the code produced by PRO64:
> For the following  C program:
>
> int a[100];
> int b[100];
> main()
> {
>   int i;
>   for (i =0;i<100;i++)
>     {
>       a[i] = b[i] + 5;
>     }
> }
>
> Compiling with -O2 produced the following pipelined loop:
>  {       .mii
>  (p19) st4 [r3]=r35,4           // [3*II+0]  id:12 a+0x0
>  (p18) adds r34=5,r37           // [2*II+0]
>  (p18) nop.i 0                  // [2*II+0]
>  }; {       .mfb
>  (p16) ld4 r35=[r2],4           // [0*II+0]  id:11 b+0x0
>  (p16) nop.f 0                  // [0*II+0]
>        br.ctop.dptk.few .Lt_0_4 ;; // [3*II+0]
>  };
>
> Is this a  legal code? there is a store from r35 and load to r35 within
> the same instruction group.
>
> (The full assembly code, as well as the C source are attached).
> --
> Raya Leviathan
> Tel. 972-8-9344208 (office)
> Tel. 972-3-6358481 (home)
> Email: raya@xxxxxxxxxxxxxxxxxxxxx
>
>   
> ------------------------------------------------------------------------------
>                  Name: simpleO2.s
>    simpleO2.s    Type: application/x-unknown-content-type-S_auto_file
>              Encoding: base64
>
>                Name: simple.c
>    simple.c    Type: application/x-unknown-content-type-c_auto_file
>            Encoding: base64


<Prev in Thread] Current Thread [Next in Thread>