Hello, I am developing now a compiler, based on llvm infrastructure, so I am building my own sequence of llvm passes with some adjustable options. I can't find really clear info about some cases, so maybe you can help, and write: 0) Why I should always delete attributes before applying optimizations with opt command? With attributes specified no optimization can be applied. Where I can get real benefit from: 1) Constant Hoisting -only when we have some large reusable constants in program? 2) argpomotion - this option does not always replace all my args by reerence with values, when I specify it. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170704/a111132c/attachment-0001.html>
On 07/04/2017 04:25 AM, Anastasiya Ruzhanskaya via llvm-dev wrote:> Hello, > I am developing now a compiler, based on llvm infrastructure, so I am > building my own sequence of llvm passes with some adjustable options. > > I can't find really clear info about some cases, so maybe you can > help, and write: > > 0) Why I should always delete attributes before applying optimizations > with opt command? With attributes specified no optimization can be > applied.You definitely shouldn't delete attributes in general. Does your attribute set include optnone? -Hal> > Where I can get real benefit from: > 1) Constant Hoisting > -only when we have some large reusable constants in program? > 2) argpomotion > - this option does not always replace all my args by reerence with > values, when I specify it. > > > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev-- Hal Finkel Lead, Compiler Technology and Programming Languages Leadership Computing Facility Argonne National Laboratory -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170705/d3c2c292/attachment.html>
Oh, yes...strange
attributes #0 = { noinline nounwind optnone uwtable
"correctly-rounded-divide-sqrt-fp-math"="false"
"disable-tail-calls"="false"
"less-precise-fpmad"="false"
"no-frame-pointer-elim"="true"
"no-frame-pointer-elim-non-leaf"
"no-infs-fp-math"="false"
"no-jump-tables"="false"
"no-nans-fp-math"="false"
"no-signed-zeros-fp-math"="false"
"no-trapping-math"="false"
"stack-protector-buffer-size"="8"
"target-cpu"="x86-64"
"target-features"="+fxsr,+mmx,+sse,+sse2,+x87"
"unsafe-fp-math"="false"
"use-soft-float"="false" }
How this can be avoided? it is always so after clang -s -emit-llvm
2017-07-05 16:49 GMT+02:00 Hal Finkel <hfinkel at anl.gov>:
>
> On 07/04/2017 04:25 AM, Anastasiya Ruzhanskaya via llvm-dev wrote:
>
> Hello,
> I am developing now a compiler, based on llvm infrastructure, so I am
> building my own sequence of llvm passes with some adjustable options.
>
> I can't find really clear info about some cases, so maybe you can help,
> and write:
>
> 0) Why I should always delete attributes before applying optimizations
> with opt command? With attributes specified no optimization can be applied.
>
>
> You definitely shouldn't delete attributes in general. Does your
attribute
> set include optnone?
>
> -Hal
>
>
> Where I can get real benefit from:
> 1) Constant Hoisting
> -only when we have some large reusable constants in program?
> 2) argpomotion
> - this option does not always replace all my args by reerence with values,
> when I specify it.
>
>
> _______________________________________________
> LLVM Developers mailing listllvm-dev at
lists.llvm.orghttp://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>
>
> --
> Hal Finkel
> Lead, Compiler Technology and Programming Languages
> Leadership Computing Facility
> Argonne National Laboratory
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20170705/6a9fd7c3/attachment.html>