While I agree it is not semantics, we already encode similar things,
e.g. related to toolchains and architectures, optnone, ... in different
places of the IR.
Maybe I'm missing why having such information in the IR is inherently bad.
I say this because I very much like to encode all optimizations levels
in IR, incl. O0/1/2/3/z/s/..., such that we can select the level per
function rather than per file.
We have a prototype for that incl. some pass manager work but it's not
ready for prime time yet (IIRC).
~ Johannes
> -Matt
>
> _______________________________________________
> LLVM Developers mailing list
> llvm...@lists.llvm.org
> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
_______________________________________________
LLVM Developers mailing list
llvm...@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
It's complicated yes, but we got it wrong already. You said so yourself
and any `no-ipa` discussion/bug will also attest to that. The idea that
*not* changing anything anymore is therefore somewhat counter-intuitive
to me. If we would actually sit down to define what the interactions are
we could fix existing problems and make progress. However, using the
`no-ipa` discussions again as example, w/o a new attribute there is no way
to make everyone happy. The problem is not that we "add too much", the
problem (often) is that we do overload what we have rather than
differentiate properly what we want. (Why we do that is a different
question.)
`optnone`/`noinline` means different things to different people,
as did `derferenceable` and other attributes. The solution to these problems
was, and will continue to be, differentiation through new
attributes/options.
Long story short, it's not the number of attributes/options that is the
problem
but nailing down their semantics and interplay. That is not to say we get it
right by adding more, but history shows problems are solved through new
ones if
the problems of existing ones are taken into account during their
definition.
~ Johannes
Hi Arthur,
If -Oz/-Os are implemented via front-end setting the optnone/minsize attribute, would that have any impact on code-size related IPOs like machine outlining?
~ Todd
From: llvm-dev <llvm-dev...@lists.llvm.org>
On Behalf Of Matt Arsenault via llvm-dev
Sent: Friday, November 12, 2021 2:10 PM
To: Arthur Eubanks <aeub...@google.com>
Cc: llvm-dev <llvm...@lists.llvm.org>