[llvm-dev] RFC: New function attribute HasInaccessibleState
Hal Finkel via llvm-dev
llvm-dev at lists.llvm.org
Fri Dec 4 12:21:46 PST 2015
----- Original Message -----
> From: "David Majnemer via llvm-dev" <llvm-dev at lists.llvm.org>
> To: "Krzysztof Parzyszek" <kparzysz at codeaurora.org>
> Cc: "llvm-dev" <llvm-dev at lists.llvm.org>
> Sent: Friday, December 4, 2015 11:16:29 AM
> Subject: Re: [llvm-dev] RFC: New function attribute
> I'd like to suggest a different direction which should accomplish
> similar ends.
> I think it would make sense to introduce an attribute: csecandidate.
> If we see a call-site "X" marked as csecandidate, it would imply that
> it can be replaced with any other call-site "Y" with the same
> arguments which dominate the call-site at "X".
> However, there are some cases that this would not be able to
> optimize. For example, if we have two csecandidates ("X" and "Y")
> which do not dominate one another.
Does this make it different than readnone?
> This is solvable using another
> attribute: speculatable. This attribute would tell us that we can
> hoist the call out of arbitrary conditions. This would allow us to
> move our csecandidate call-site to the common dominator of "X" and
> "Y" and RAUW.
I agree that speculatable would be nice to have.
> On Fri, Dec 4, 2015 at 8:54 AM, Krzysztof Parzyszek via llvm-dev <
> llvm-dev at lists.llvm.org > wrote:
> > On 12/4/2015 10:48 AM, Vaivaswatha Nagaraj via llvm-dev wrote:
> > > This point however reminds me to add, functions that transitively
> > > call
> > > functions with HasInaccessibleState must also have the flag set.
> > That's in practice impossible to guarantee, both by the compiler
> > and
> > by the programmer.
> > -Krzysztof
> > --
> > Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
> > hosted by The Linux Foundation
> > _______________________________________________
> > LLVM Developers mailing list
> > llvm-dev at lists.llvm.org
> > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
Assistant Computational Scientist
Leadership Computing Facility
Argonne National Laboratory
More information about the llvm-dev