[llvm-commits] [PATCH] Use an alternate symbol for function-size calc
Hal Finkel
hfinkel at anl.gov
Fri Dec 30 08:53:31 PST 2011
On Fri, 2011-12-30 at 11:37 -0500, Rafael Ávila de Espíndola wrote:
> > I think that you can just use the output from llc with the test case in
> > my patch. I apologize as I may not have said this explicitly, but the
> > problem only appears on powerpc64 for linux
> > (powerpc64-unknown-linux-gnu). If that does not reproduce the problem
> > for you, I'll send you a failing .s file so that we can compare.
>
> OK, I can reproduce this, but it looks like a bug in our end. We are
> printing something like
>
> .text
> .section ".opd","aw"
> test1:
> .quad .L.test1,.TOC. at tocbase
> .previous
> .Ltmp0:
> .size test1, .Ltmp0-test1
>
> So test1 ends up in section ".opd". Is this really what we want? What
> does gcc print for
I am not sure, but that seems to be what gcc does:
.file "h.c"
.section ".toc","aw"
.section ".text"
.align 2
.p2align 4,,15
.globl test1
.section ".opd","aw"
.align 3
test1:
.quad .L.test1,.TOC. at tocbase
.previous
.type test1, @function
.L.test1:
blr
.long 0
.byte 0,0,0,0,0,0,0,0
.size test1,.-.L.test1
.ident "GCC: (GNU) 4.4.4 20100726 (Red Hat 4.4.4-13)"
.section .note.GNU-stack,"", at progbits
-Hal
>
> int test1(int x) {return x}
>
> ?
>
> > Thanks again,
> > Hal
>
> Cheers,
> Rafael
--
Hal Finkel
Postdoctoral Appointee
Leadership Computing Facility
Argonne National Laboratory
More information about the llvm-commits
mailing list