<html>
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<p><br>
</p>
<div class="moz-cite-prefix">On 03/14/2017 11:21 AM, Adam Nemet
wrote:<br>
</div>
<blockquote
cite="mid:B6F61517-2F3B-46B6-9A10-6E1D534AFD83@apple.com"
type="cite">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<br class="">
<div>
<blockquote type="cite" class="">
<div class="">On Mar 14, 2017, at 6:00 AM, Nema, Ashutosh <<a
moz-do-not-send="true" href="mailto:Ashutosh.Nema@amd.com"
class="">Ashutosh.Nema@amd.com</a>> wrote:</div>
<br class="Apple-interchange-newline">
<div class="">
<div class="WordSection1" style="page: WordSection1;
font-family: Helvetica; font-size: 10px; font-style:
normal; font-variant-caps: normal; font-weight: normal;
letter-spacing: normal; orphans: auto; text-align: start;
text-indent: 0px; text-transform: none; white-space:
normal; widows: auto; word-spacing: 0px;
-webkit-text-stroke-width: 0px;">
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class="">Summarizing
the discussion on the implementation approaches.<o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class="">Discussed
about two approaches, first running
‘InnerLoopVectorizer’ again on the epilog loop
immediately after vectorizing the original loop within
the same vectorization pass, the second approach where
re-running vectorization pass and limiting vectorization
factor of epilog loop by metadata.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><Approach-2><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class="">Challenges
with re-running the vectorizer pass:<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
11pt; font-family: Calibri, sans-serif; text-indent:
-0.25in;" class=""><span class="">1)<span
style="font-style: normal; font-variant-caps:
normal; font-weight: normal; font-size: 7pt;
line-height: normal; font-family: 'Times New
Roman';" class=""> <span
class="Apple-converted-space"> </span></span></span>Reusing
alias check result:<span class="Apple-converted-space"> </span><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
11pt; font-family: Calibri, sans-serif;" class="">When
vectorizer pass runs again it finds the epilog loop as a
new loop and it may generates alias check, this new
alias check may overkill the gains of epilog
vectorization.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
11pt; font-family: Calibri, sans-serif;" class="">We
should use the already computed alias check result
instead of re computing again.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
11pt; font-family: Calibri, sans-serif; text-indent:
-0.25in;" class=""><span class="">2)<span
style="font-style: normal; font-variant-caps:
normal; font-weight: normal; font-size: 7pt;
line-height: normal; font-family: 'Times New
Roman';" class=""> <span
class="Apple-converted-space"> </span></span></span>Rerun
the vectorizer and hoist the new alias check:<o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
11pt; font-family: Calibri, sans-serif;" class="">It’s
not possible to hoist alias checks as its not fully
redundant (not dominated by other checks), it’s not
getting execute in all paths.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><img
id="Picture_x0020_1" class="" apple-inline="yes"
apple-width="yes" apple-height="yes"
src="cid:part2.8A601F10.7A15555C@anl.gov" height="156"
width="567"></div>
</div>
</div>
</blockquote>
<div><br class="">
</div>
<div><br class="">
</div>
<div>
<div>I don’t understand. Looks like you have the same alias
checks for the epilog loop too. How is this CFG different
from the re-vectorization of the scalar loop? </div>
</div>
</div>
</blockquote>
<br>
You're looking at the wrong thing. This *is* the image from
re-vectorization. The other image (linked below in step (3)) shows
the other option.<br>
<br>
<blockquote
cite="mid:B6F61517-2F3B-46B6-9A10-6E1D534AFD83@apple.com"
type="cite">
<div>
<div>
<div> Would be good to have both CFGs here and highlighting
the difference.</div>
<div><br class="">
</div>
<div>I thought that the whole point was that *if* you reached
the epilog vector loop via the first vector loop, you want
to bypass the alias checks before the epilog vector.</div>
</div>
</div>
</blockquote>
<br>
Yes, but, that's not quite true now. You can also reach the epilogue
loop if you fail the min-trip-count check, and so you don't know
anything about the aliasing checks.<br>
<br>
-Hal<br>
<br>
<blockquote
cite="mid:B6F61517-2F3B-46B6-9A10-6E1D534AFD83@apple.com"
type="cite">
<div>
<div>
<div><br class="">
</div>
<div>I still don’t understand why that’s not possible with
some sophisticated predicate propagation independent from
the vectorizer. I am not saying it’s already possible but
it should be.</div>
<div><br class="">
</div>
<div>Adam</div>
<div class=""><br class="">
</div>
</div>
<br class="">
<blockquote type="cite" class="">
<div class="">
<div class="WordSection1" style="page: WordSection1;
font-family: Helvetica; font-size: 10px; font-style:
normal; font-variant-caps: normal; font-weight: normal;
letter-spacing: normal; orphans: auto; text-align: start;
text-indent: 0px; text-transform: none; white-space:
normal; widows: auto; word-spacing: 0px;
-webkit-text-stroke-width: 0px;">
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class="">NOTE:
We cannot prepone alias check as its expensive compared
to other checks.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><Approach-1><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
11pt; font-family: Calibri, sans-serif; text-indent:
-0.25in;" class=""><span class="">1)<span
style="font-style: normal; font-variant-caps:
normal; font-weight: normal; font-size: 7pt;
line-height: normal; font-family: 'Times New
Roman';" class=""> <span
class="Apple-converted-space"> </span></span></span>Current
patch depends on the existing functionality of
LoopVectorizer, it uses ‘InnerLoopVectorizer’ again to
vectorize the epilog loop, as it happens in the same
vectorization pass we have flexibility to reuse already
computed alias result check & limit vectorization
factor for the epilog loop.<span
class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
11pt; font-family: Calibri, sans-serif; text-indent:
-0.25in;" class=""><span class="">2)<span
style="font-style: normal; font-variant-caps:
normal; font-weight: normal; font-size: 7pt;
line-height: normal; font-family: 'Times New
Roman';" class=""> <span
class="Apple-converted-space"> </span></span></span>It
does not generate the blocks for new block layout
explicitly, rather it depends on
‘InnerLoopVectorizer::createEmptyLoop’ to generate new
block layout. The new block layout get automatically
generated by calling the ‘InnerLoopVectorizer::
vectorize’ again.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
11pt; font-family: Calibri, sans-serif; text-indent:
-0.25in;" class=""><span class="">3)<span
style="font-style: normal; font-variant-caps:
normal; font-weight: normal; font-size: 7pt;
line-height: normal; font-family: 'Times New
Roman';" class=""> <span
class="Apple-converted-space"> </span></span></span>Block
layout description with epilog loop vectorization is
available at<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
11pt; font-family: Calibri, sans-serif;" class=""><a
moz-do-not-send="true"
href="https://reviews.llvm.org/file/data/fxg5vx3capyj257rrn5j/PHID-FILE-x6thnbf6ub55ep5yhalu/LayoutDescription.png"
style="color: purple; text-decoration: underline;"
class="">https://reviews.llvm.org/file/data/fxg5vx3capyj257rrn5j/PHID-FILE-x6thnbf6ub55ep5yhalu/LayoutDescription.png</a><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class="">Approach-1
looks feasible, please comment if any objections.<o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class="">Regards,<o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class="">Ashutosh<o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><span
style="font-size: 11pt; font-family: Calibri,
sans-serif; color: rgb(31, 73, 125);" class=""><o:p
class=""> </o:p></span></div>
<div class="">
<div style="border-style: solid none none;
border-top-color: rgb(225, 225, 225);
border-top-width: 1pt; padding: 3pt 0in 0in;" class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class=""><b class=""><span style="font-size: 11pt;
font-family: Calibri, sans-serif;" class="">From:</span></b><span
style="font-size: 11pt; font-family: Calibri,
sans-serif;" class=""><span
class="Apple-converted-space"> </span>Nema,
Ashutosh<span class="Apple-converted-space"> </span><br
class="">
<b class="">Sent:</b><span
class="Apple-converted-space"> </span>Wednesday,
March 1, 2017 10:42 AM<br class="">
<b class="">To:</b><span
class="Apple-converted-space"> </span>'Daniel
Berlin' <<a moz-do-not-send="true"
href="mailto:dberlin@dberlin.org" style="color:
purple; text-decoration: underline;" class="">dberlin@dberlin.org</a>><br
class="">
<b class="">Cc:</b><span
class="Apple-converted-space"> </span><a
moz-do-not-send="true"
href="mailto:anemet@apple.com" style="color:
purple; text-decoration: underline;" class="">anemet@apple.com</a>;
Hal Finkel <<a moz-do-not-send="true"
href="mailto:hfinkel@anl.gov" style="color:
purple; text-decoration: underline;" class="">hfinkel@anl.gov</a>>;
Zaks, Ayal <<a moz-do-not-send="true"
href="mailto:ayal.zaks@intel.com" style="color:
purple; text-decoration: underline;" class="">ayal.zaks@intel.com</a>>;
Renato Golin <<a moz-do-not-send="true"
href="mailto:renato.golin@linaro.org"
style="color: purple; text-decoration:
underline;" class="">renato.golin@linaro.org</a>>;<span
class="Apple-converted-space"> </span><a
moz-do-not-send="true"
href="mailto:mkuper@google.com" style="color:
purple; text-decoration: underline;" class="">mkuper@google.com</a>;
Mehdi Amini <<a moz-do-not-send="true"
href="mailto:mehdi.amini@apple.com"
style="color: purple; text-decoration:
underline;" class="">mehdi.amini@apple.com</a>>;
llvm-dev <<a moz-do-not-send="true"
href="mailto:llvm-dev@lists.llvm.org"
style="color: purple; text-decoration:
underline;" class="">llvm-dev@lists.llvm.org</a>><br
class="">
<b class="">Subject:</b><span
class="Apple-converted-space"> </span>RE:
[llvm-dev] [Proposal][RFC] Epilog loop
vectorization<o:p class=""></o:p></span></div>
</div>
</div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
12pt; font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
12pt; font-family: 'Times New Roman', serif;" class=""><span
style="font-size: 11pt; font-family: Calibri,
sans-serif; color: rgb(31, 73, 125);" class="">Sorry I
misunderstood, gvn/newgvn/gvnhoist cannot help here as
these checks are not dominated by all paths.<o:p
class=""></o:p></span></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
12pt; font-family: 'Times New Roman', serif;" class=""><span
style="font-size: 11pt; font-family: Calibri,
sans-serif; color: rgb(31, 73, 125);" class=""><o:p
class=""> </o:p></span></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
12pt; font-family: 'Times New Roman', serif;" class=""><span
style="font-size: 11pt; font-family: Calibri,
sans-serif; color: rgb(31, 73, 125);" class="">Regards,<o:p
class=""></o:p></span></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
12pt; font-family: 'Times New Roman', serif;" class=""><span
style="font-size: 11pt; font-family: Calibri,
sans-serif; color: rgb(31, 73, 125);" class="">Ashutosh<o:p
class=""></o:p></span></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size:
12pt; font-family: 'Times New Roman', serif;" class=""><span
style="font-size: 11pt; font-family: Calibri,
sans-serif; color: rgb(31, 73, 125);" class=""><o:p
class=""> </o:p></span></div>
<div style="margin: 0in 0in 0.0001pt 1in; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><b
class=""><span style="font-size: 11pt; font-family:
Calibri, sans-serif;" class="">From:</span></b><span
style="font-size: 11pt; font-family: Calibri,
sans-serif;" class=""><span
class="Apple-converted-space"> </span>Daniel Berlin
[<a moz-do-not-send="true"
href="mailto:dberlin@dberlin.org" style="color:
purple; text-decoration: underline;" class="">mailto:dberlin@dberlin.org</a>]<span
class="Apple-converted-space"> </span><br class="">
<b class="">Sent:</b><span
class="Apple-converted-space"> </span>Tuesday,
February 28, 2017 6:58 PM<br class="">
<b class="">To:</b><span class="Apple-converted-space"> </span>Nema,
Ashutosh <<a moz-do-not-send="true"
href="mailto:Ashutosh.Nema@amd.com" style="color:
purple; text-decoration: underline;" class="">Ashutosh.Nema@amd.com</a>><br
class="">
<b class="">Cc:</b><span class="Apple-converted-space"> </span><a
moz-do-not-send="true"
href="mailto:anemet@apple.com" style="color: purple;
text-decoration: underline;" class="">anemet@apple.com</a>;
Hal Finkel <<a moz-do-not-send="true"
href="mailto:hfinkel@anl.gov" style="color: purple;
text-decoration: underline;" class="">hfinkel@anl.gov</a>>;
Zaks, Ayal <<a moz-do-not-send="true"
href="mailto:ayal.zaks@intel.com" style="color:
purple; text-decoration: underline;" class="">ayal.zaks@intel.com</a>>;
Renato Golin <<a moz-do-not-send="true"
href="mailto:renato.golin@linaro.org" style="color:
purple; text-decoration: underline;" class="">renato.golin@linaro.org</a>>;<span
class="Apple-converted-space"> </span><a
moz-do-not-send="true"
href="mailto:mkuper@google.com" style="color:
purple; text-decoration: underline;" class="">mkuper@google.com</a>;
Mehdi Amini <<a moz-do-not-send="true"
href="mailto:mehdi.amini@apple.com" style="color:
purple; text-decoration: underline;" class="">mehdi.amini@apple.com</a>>;
llvm-dev <<a moz-do-not-send="true"
href="mailto:llvm-dev@lists.llvm.org" style="color:
purple; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>><br
class="">
<b class="">Subject:</b><span
class="Apple-converted-space"> </span>Re: [llvm-dev]
[Proposal][RFC] Epilog loop vectorization<o:p class=""></o:p></span></div>
<div style="margin: 0in 0in 0.0001pt 1in; font-size: 12pt;
font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;" class="">Hoisting
or removing?<br class="">
Neither pass does hoisting, you'd need gvnhoist for
that.<o:p class=""></o:p></div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class=""><o:p class=""> </o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class="">Even then:<br class="">
Staring at your example, none of the checks are
fully redundant (IE they are not dominated by other
checks) or execute on all paths.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class=""><o:p class=""> </o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class="">Thus, hoisting them would be purely
speculative code motion, which none of our passes
do.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class=""><o:p class=""> </o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class="">If you would like these sets of checks to
be removed, you would need to place them in a place
that they execute unconditionally.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class=""><o:p class=""> </o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class="">Otherwise, this is not a standard code
hoisting/removal transform.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class=""><o:p class=""> </o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class="">The only redundancy i can see here at all
is the repeated getelementptr computation.<o:p
class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class="">If you move it to the preheader, it will be
eliminated.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class="">Otherwise, none of the checks are
redundant.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class=""><br class="">
What would you hope to happen in this case?<o:p
class=""></o:p></div>
</div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;" class=""><o:p
class=""> </o:p></div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in; font-size:
12pt; font-family: 'Times New Roman', serif;"
class="">On Tue, Feb 28, 2017 at 5:09 AM, Nema,
Ashutosh <<a moz-do-not-send="true"
href="mailto:Ashutosh.Nema@amd.com"
target="_blank" style="color: purple;
text-decoration: underline;" class="">Ashutosh.Nema@amd.com</a>>
wrote:<o:p class=""></o:p></div>
<blockquote style="border-style: none none none solid;
border-left-color: rgb(204, 204, 204);
border-left-width: 1pt; padding: 0in 0in 0in 6pt;
margin: 5pt 0in 5pt 4.8pt;" class="">
<div class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class="">I have tried running both
gvn and newgvn but it did not helped in
hoisting the alias checks:</span><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class="">Please check, maybe I have
missed something.</span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""><TestCase></span><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class="">void foo (char *A, char *B,
char *C, int len) {</span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> int i = 0;</span><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> for (i=0 ; i< len; i++)</span><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> A[i] = B[i] + C[i];</span><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class="">}</span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""><Command></span><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> $ opt –O3 –gvn test.ll –o
test.opt.ll</span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> $ opt –O3 –newgvn test.ll
–o test.opt.ll</span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class="">“test.ll” is attached, it
got already vectorized by the approach
running vectorizer twice by annotate the
remainder loop with metadata to limit the
vectorization factor for epilog vector loop.</span><o:p
class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class="">Regards,</span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class="">Ashutosh</span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif; color: rgb(31, 73,
125);" class=""> </span><o:p class=""></o:p></div>
<div class="">
<div style="border-style: solid none none;
border-top-color: rgb(225, 225, 225);
border-top-width: 1pt; padding: 3pt 0in
0in;" class="">
<div style="margin: 0in 0in 0.0001pt 1.5in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""><b class=""><span
style="font-size: 11pt; font-family:
Calibri, sans-serif;" class="">From:</span></b><span
style="font-size: 11pt; font-family:
Calibri, sans-serif;" class=""><span
class="Apple-converted-space"> </span><a
moz-do-not-send="true"
href="mailto:anemet@apple.com"
target="_blank" style="color: purple;
text-decoration: underline;" class="">anemet@apple.com</a><span
class="Apple-converted-space"> </span>[mailto:<a
moz-do-not-send="true"
href="mailto:anemet@apple.com"
target="_blank" style="color: purple;
text-decoration: underline;" class="">anemet@apple.com</a>]<span
class="Apple-converted-space"> </span><br
class="">
<b class="">Sent:</b><span
class="Apple-converted-space"> </span>Tuesday,
February 28, 2017 1:33 AM<br class="">
<b class="">To:</b><span
class="Apple-converted-space"> </span>Hal
Finkel <<a moz-do-not-send="true"
href="mailto:hfinkel@anl.gov"
target="_blank" style="color: purple;
text-decoration: underline;" class="">hfinkel@anl.gov</a>><br
class="">
<b class="">Cc:</b><span
class="Apple-converted-space"> </span>Daniel
Berlin <<a moz-do-not-send="true"
href="mailto:dberlin@dberlin.org"
target="_blank" style="color: purple;
text-decoration: underline;" class="">dberlin@dberlin.org</a>>;
Nema, Ashutosh <<a
moz-do-not-send="true"
href="mailto:Ashutosh.Nema@amd.com"
target="_blank" style="color: purple;
text-decoration: underline;" class="">Ashutosh.Nema@amd.com</a>>;
Zaks, Ayal <<a moz-do-not-send="true"
href="mailto:ayal.zaks@intel.com"
target="_blank" style="color: purple;
text-decoration: underline;" class="">ayal.zaks@intel.com</a>>;
Renato Golin <<a
moz-do-not-send="true"
href="mailto:renato.golin@linaro.org"
target="_blank" style="color: purple;
text-decoration: underline;" class="">renato.golin@linaro.org</a>>;<span
class="Apple-converted-space"> </span><a
moz-do-not-send="true"
href="mailto:mkuper@google.com"
target="_blank" style="color: purple;
text-decoration: underline;" class="">mkuper@google.com</a>;
Mehdi Amini <<a
moz-do-not-send="true"
href="mailto:mehdi.amini@apple.com"
target="_blank" style="color: purple;
text-decoration: underline;" class="">mehdi.amini@apple.com</a>>;
llvm-dev <<a moz-do-not-send="true"
href="mailto:llvm-dev@lists.llvm.org"
target="_blank" style="color: purple;
text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>><br
class="">
<b class="">Subject:</b><span
class="Apple-converted-space"> </span>Re:
[llvm-dev] [Proposal][RFC] Epilog loop
vectorization</span><o:p class=""></o:p></div>
</div>
</div>
<div style="margin: 0in 0in 0.0001pt 1.5in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""> <o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1.5in;
font-size: 12pt; font-family: 'Times New
Roman', serif;" class=""> <o:p class=""></o:p></div>
<div class="">
<blockquote style="margin-top: 5pt;
margin-bottom: 5pt;" class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt
1.5in; font-size: 12pt; font-family:
'Times New Roman', serif;" class="">On
Feb 27, 2017, at 12:01 PM, Hal Finkel
<<a moz-do-not-send="true"
href="mailto:hfinkel@anl.gov"
target="_blank" style="color: purple;
text-decoration: underline;" class="">hfinkel@anl.gov</a>>
wrote:<o:p class=""></o:p></div>
</div>
<div class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt
1.5in; font-size: 12pt; font-family:
'Times New Roman', serif;" class=""> <o:p
class=""></o:p></div>
<div class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt
1.5in; font-size: 12pt;
font-family: 'Times New Roman',
serif;" class=""> <o:p class=""></o:p></div>
<div class="">
<div style="margin: 0in 0in
0.0001pt 1.5in; font-size: 12pt;
font-family: 'Times New Roman',
serif;" class="">On 02/27/2017
01:47 PM, Daniel Berlin wrote:<o:p
class=""></o:p></div>
</div>
<blockquote style="margin-top: 5pt;
margin-bottom: 5pt;" class="">
<div class="">
<div style="margin: 0in 0in
0.0001pt 1.5in; font-size:
12pt; font-family: 'Times New
Roman', serif;" class=""> <o:p
class=""></o:p></div>
<div class="">
<div style="margin: 0in 0in
0.0001pt 1.5in; font-size:
12pt; font-family: 'Times
New Roman', serif;" class=""> <o:p
class=""></o:p></div>
<div class="">
<div style="margin: 0in 0in
0.0001pt 1.5in; font-size:
12pt; font-family: 'Times
New Roman', serif;"
class="">On Mon, Feb 27,
2017 at 11:29 AM, Adam
Nemet <<a
moz-do-not-send="true"
href="mailto:anemet@apple.com"
target="_blank"
style="color: purple;
text-decoration:
underline;" class="">anemet@apple.com</a>>
wrote:<o:p class=""></o:p></div>
<blockquote
style="border-style: none
none none solid;
border-left-color:
rgb(204, 204, 204);
border-left-width: 1pt;
padding: 0in 0in 0in 6pt;
margin: 5pt 0in 5pt
4.8pt;" class="">
<div class="">
<div style="margin: 0in
0in 0.0001pt 1.5in;
font-size: 12pt;
font-family: 'Times
New Roman', serif;"
class=""> <o:p
class=""></o:p></div>
<div class="">
<div class="">
<div class="">
<blockquote
style="margin-top:
5pt;
margin-bottom:
5pt;" class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">On
Feb 27, 2017,
at 10:11 AM,
Hal Finkel
<<a
moz-do-not-send="true"
href="mailto:hfinkel@anl.gov" target="_blank" style="color: purple;
text-decoration:
underline;"
class="">hfinkel@anl.gov</a>>
wrote:<o:p
class=""></o:p></div>
</div>
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
<div class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">On
02/27/2017
11:47 AM, Adam
Nemet wrote:<o:p
class=""></o:p></div>
</div>
<blockquote
style="margin-top:
5pt;
margin-bottom:
5pt;" class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
<div class="">
<blockquote
style="margin-top:
5pt;
margin-bottom:
5pt;" class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">On
Feb 27, 2017,
at 9:39 AM,
Daniel Berlin
<<a
moz-do-not-send="true"
href="mailto:dberlin@dberlin.org" target="_blank" style="color: purple;
text-decoration: underline;" class="">dberlin@dberlin.org</a>> wrote:<o:p
class=""></o:p></div>
</div>
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
<div class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">On
Mon, Feb 27,
2017 at 9:29
AM, Adam Nemet
<<a
moz-do-not-send="true"
href="mailto:anemet@apple.com" target="_blank" style="color: purple;
text-decoration:
underline;"
class="">anemet@apple.com</a>>
wrote:<o:p
class=""></o:p></div>
<blockquote
style="border-style:
none none none
solid;
border-left-color:
rgb(204, 204,
204);
border-left-width:
1pt; padding:
0in 0in 0in
6pt; margin:
5pt 0in 5pt
4.8pt;"
class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
<div class="">
<blockquote
style="margin-top:
5pt;
margin-bottom:
5pt;" class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">On
Feb 27, 2017,
at 7:27 AM,
Hal Finkel
<<a
moz-do-not-send="true"
href="mailto:hfinkel@anl.gov" target="_blank" style="color: purple;
text-decoration:
underline;"
class="">hfinkel@anl.gov</a>>
wrote:<o:p
class=""></o:p></div>
</div>
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
<div class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman', serif;
background-color: white;" class=""><span style="font-size: 7.5pt;
font-family:
Helvetica,
sans-serif;"
class=""><br
class="">
On 02/27/2017
06:29 AM,
Nema, Ashutosh
wrote:</span><o:p
class=""></o:p></div>
</div>
<blockquote
style="margin-top:
5pt;
margin-bottom:
5pt;
font-variant-caps:
normal;
text-align:
start;
word-spacing:
0px;" class="">
<div class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman', serif;
background-color: white;" class=""><span style="font-size: 7.5pt;
font-family:
Helvetica,
sans-serif;"
class="">Thanks
for looking
into this.</span><o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman', serif;
background-color: white;" class=""><span style="font-size: 7.5pt;
font-family:
Helvetica,
sans-serif;"
class=""> </span><o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman', serif;
background-color: white;" class=""><span style="font-size: 7.5pt;
font-family:
Helvetica,
sans-serif;"
class="">1)
Issues with re
running
vectorizer:</span><o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman', serif;
background-color: white;" class=""><span style="font-size: 7.5pt;
font-family:
Helvetica,
sans-serif;"
class="">Vectorizer
might generate
redundant
alias checks
while
vectorizing
epilog loop.</span><o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman', serif;
background-color: white;" class=""><span style="font-size: 7.5pt;
font-family:
Helvetica,
sans-serif;"
class="">Redundant
alias checks
are expensive,
we like to
reuse the
results of
already
computed alias
checks.</span><o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman', serif;
background-color: white;" class=""><span style="font-size: 7.5pt;
font-family:
Helvetica,
sans-serif;"
class="">With
metadata we
can limit the
width of
epilog loop,
but not sure
about reusing
alias check
result.</span><o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman', serif;
background-color: white;" class=""><span style="font-size: 7.5pt;
font-family:
Helvetica,
sans-serif;"
class="">Any
thoughts on
rerunning
vectorizer
with reusing
the alias
check result ?</span><o:p
class=""></o:p></div>
</div>
</div>
</blockquote>
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""><span
style="font-size: 7.5pt; font-family: Helvetica, sans-serif;" class=""><br
class="">
<span
style="background-color:
white;
background-position:
initial
initial;
background-repeat:
initial
initial;"
class="">One
way of looking
at this is:
Reusing the
alias-check
result is
really just a
conditional
propagation
problem; if we
don't already
have an
optimization
that can
combine these
after the
fact, then we
should.</span></span><o:p
class=""></o:p></div>
</div>
</blockquote>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">+Danny<o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">Isn’t
Extended SSA
supposed to
help with
this?<o:p
class=""></o:p></div>
</div>
</div>
</div>
</blockquote>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">Yes,
it will solve
this with no
issue
already. GVN
probably does
already too.<o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">even
if if you have<o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">if (a
== b)<o:p
class=""></o:p></div>
</div>
<div class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">if (a
== c)<o:p
class=""></o:p></div>
</div>
</div>
<div class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> if
(a == d)<o:p
class=""></o:p></div>
</div>
</div>
<div class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> if
(a == e)<o:p
class=""></o:p></div>
</div>
</div>
<div class="">
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> if
(a == g)<o:p
class=""></o:p></div>
</div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">and
we can prove
a ... g
equivalent,
newgvn will
eliminate them
all and set
all the
branches true.<o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">If
you need a
simpler clean
up pass, we
could run it
on sub-graphs.<o:p
class=""></o:p></div>
</div>
</div>
</div>
</div>
</div>
</blockquote>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class="">Yes
we probably
don’t want to
run a full GVN
after the
“loop-scheduling”
passes.<o:p
class=""></o:p></div>
</div>
</div>
</blockquote>
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""><br
class="">
FWIW, we
could, just
without the
memory-dependence
analysis
enabled (i.e.
set the
NoLoads
constructor
parameter to
true). GVN is
pretty fast in
that mode.<o:p
class=""></o:p></div>
</div>
</div>
</blockquote>
<div class="">
<div
style="margin:
0in 0in
0.0001pt
1.5in;
font-size:
12pt;
font-family:
'Times New
Roman',
serif;"
class=""> <o:p
class=""></o:p></div>
</div>
</div>
</div>
<div class="">
<div style="margin:
0in 0in 0.0001pt
1.5in; font-size:
12pt; font-family:
'Times New Roman',
serif;" class="">OK.
Another data point
is that I’ve seen
cases in the past
where the alias
checks required
for the loop
passes could
enable GVN to
remove redundant
loads/stores.
Currently we can
only pick these up
with LTO when GVN
is rerun.<o:p
class=""></o:p></div>
</div>
</div>
</div>
</blockquote>
<div class="">
<div style="margin: 0in
0in 0.0001pt 1.5in;
font-size: 12pt;
font-family: 'Times New
Roman', serif;" class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in
0in 0.0001pt 1.5in;
font-size: 12pt;
font-family: 'Times New
Roman', serif;" class="">This
is just GVN brokenness,
newgvn should not have
this problem.<o:p
class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in
0in 0.0001pt 1.5in;
font-size: 12pt;
font-family: 'Times New
Roman', serif;" class="">If
it does, i'd love to see
it.<o:p class=""></o:p></div>
</div>
</div>
</div>
</div>
</blockquote>
<div style="margin: 0in 0in 0.0001pt
1.5in; font-size: 12pt;
font-family: 'Times New Roman',
serif;" class=""><br class="">
I thought that the problem is that
we just don't run GVN after that
point in the pipeline.<o:p
class=""></o:p></div>
</div>
</div>
</div>
</div>
</blockquote>
<div class="">
<div class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt
1.5in; font-size: 12pt; font-family:
'Times New Roman', serif;" class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt
1.5in; font-size: 12pt; font-family:
'Times New Roman', serif;" class="">Yeah,
that is the problem but I think Danny
misunderstood what I was trying to
say.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt
1.5in; font-size: 12pt; font-family:
'Times New Roman', serif;" class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt
1.5in; font-size: 12pt; font-family:
'Times New Roman', serif;" class="">This
was a datapoint to possibly rerun GVN
with memory-awareness.<o:p class=""></o:p></div>
</div>
<p class="MsoNormal" style="margin: 0in
0in 12pt 1.5in; font-size: 12pt;
font-family: 'Times New Roman', serif;"><o:p
class=""> </o:p></p>
<blockquote style="margin-top: 5pt;
margin-bottom: 5pt;" class="">
<div class="">
<div class="">
<p class="MsoNormal" style="margin:
0in 0in 12pt 1.5in; font-size:
12pt; font-family: 'Times New
Roman', serif;"><br class="">
-Hal<o:p class=""></o:p></p>
<blockquote style="margin-top: 5pt;
margin-bottom: 5pt;" class="">
<div class="">
<div class="">
<div class="">
<div class="">
<div style="margin: 0in
0in 0.0001pt 1.5in;
font-size: 12pt;
font-family: 'Times New
Roman', serif;" class=""> <o:p
class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in
0in 0.0001pt 1.5in;
font-size: 12pt;
font-family: 'Times New
Roman', serif;" class="">(I'm
working on the last few
parts of turning it on
by default, but it
requires a new
getModRefInfo interface
to be able to get the
last few testcases)<o:p
class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in
0in 0.0001pt 1.5in;
font-size: 12pt;
font-family: 'Times New
Roman', serif;" class=""> <o:p
class=""></o:p></div>
</div>
</div>
</div>
</div>
</blockquote>
<p class="MsoNormal" style="margin:
0in 0in 12pt 1.5in; font-size:
12pt; font-family: 'Times New
Roman', serif;"><o:p class=""> </o:p></p>
<pre style="margin: 0in 0in 0.0001pt 1.5in; font-size: 10pt; font-family: 'Courier New';" class="">-- <o:p class=""></o:p></pre>
<pre style="margin: 0in 0in 0.0001pt 1.5in; font-size: 10pt; font-family: 'Courier New';" class="">Hal Finkel<o:p class=""></o:p></pre>
<pre style="margin: 0in 0in 0.0001pt 1.5in; font-size: 10pt; font-family: 'Courier New';" class="">Lead, Compiler Technology and Programming Languages<o:p class=""></o:p></pre>
<pre style="margin: 0in 0in 0.0001pt 1.5in; font-size: 10pt; font-family: 'Courier New';" class="">Leadership Computing Facility<o:p class=""></o:p></pre>
<pre style="margin: 0in 0in 0.0001pt 1.5in; font-size: 10pt; font-family: 'Courier New';" class="">Argonne National Laboratory</pre>
</div>
</div>
</blockquote>
</div>
</div>
</div>
</div>
</div>
</blockquote>
</div>
</div>
</div>
</div>
</blockquote>
</div>
<br class="">
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Hal Finkel
Lead, Compiler Technology and Programming Languages
Leadership Computing Facility
Argonne National Laboratory</pre>
</body>
</html>