Hi.

On the i370 target of a slightly modified
GCC 3.2.3, I am getting this strange padding:

        DC    46X'00'

I asked Dave Pitts about it, and he
told me it is not related to the i370
machine definition and I should ask
the group for advice instead.

Note that one variable needs a padding
of 46 and another variable needs a
padding of 66, but for some reason only
the "46" appears at all, and that
appearance is completely redundant, and
the code does not use it at all (which
is why it causes no actual problem with
the variable that needs 66 padding).

Any insights? See code below.

Thanks. Paul.





void foo(void)
{
   char buf[50] = "CDE";
   char buf2[70] = "CDE";
bar(buf, buf2);
   return;
}



        COPY  PDPTOP
        CSECT
* Program text area
@@LC0    EQU   *
        DC    C'CDE'
        DC    X'0'
        DC    46X'00'
        DS    0F
* X-func foo prologue
FOO      PDPPRLG CINDEX=0,FRAME=224,BASER=12,ENTRY=YES
        B     @@FEN0
        LTORG
@@FEN0   EQU   *
        DROP  12
        BALR  12,0
        USING *,12
@@PG0    EQU   *
        LR    11,1
        L     10,=A(@@PGT0)
* Function foo code
        L     2,=A(@@LC0)


* first buffer needs to copy the literal
* then 46 filler
        MVC   96(4,13),0(2)
        LA    6,100(,13)
        LA    7,46(0,0)
        SLR   4,4
        LR    5,4
        MVCL  6,4

* second bufer needs to copy the literal
* then 66 filler

        MVC   152(4,13),0(2)
        LA    6,156(,13)
        LA    7,66(0,0)
        SLR   4,4
        LR    5,4
        MVCL  6,4

* finished setting buffers, time for
* irrelevant function call

        LA    2,96(,13)
        ST    2,88(13)
        LA    2,152(,13)
        ST    2,92(13)
        LA    1,88(,13)
        L     15,=V(BAR)
        BALR  14,15
* Function foo epilogue
        PDPEPIL
* Function foo literal pool
        DS    0F
        LTORG
* Function foo page table
        DS    0F
@@PGT0   EQU   *
        DC    A(@@PG0)
        END




Reply via email to