<div dir="rtl"><div dir="ltr">Personally I prefer putting in a non obvious place (such as <span style="font-size:12.8px">include/llvm/Support) to duplicating code. It seems that every such duplication diverges in time, when someone modifies one copy and forgets the other. Since both projects still compile, everything is "OK". S</span><span style="font-size:12.8px">ometimes this results in very hard to find bugs. </span></div><div dir="ltr"><span style="font-size:12.8px">That may be a matter of personal preference, though.</span></div><div dir="ltr"><span style="font-size:12.8px"><br></span></div></div><div class="gmail_extra"><br><div class="gmail_quote"><div dir="ltr">2015-11-22 17:40 GMT+02:00 Krzysztof Parzyszek <span dir="ltr"><<a href="mailto:kparzysz@codeaurora.org" target="_blank">kparzysz@codeaurora.org</a>></span>:</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 11/22/2015 9:31 AM, Yaron Keren wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Instead of copy&paste duplication, wouldn't it be better to introduce a<br>
.h or .inc file shared by both cpp sources?<br>
</blockquote>
<br></span>
Yes. See my reply to Takumi's email.<br>
<br>
The problem is that if I put the common definitions in some file in include/llvm/CodeGen, then that violates layering.  I didn't want to put it in include/llvm/Support, and there isn't really any other obvious place for that common file.<br>
As a matter of fact, the file that this commit deletes (DFAPacketizerDefs.h) was my initial attempt to solve the hard cycle by extracting the minimal set of common definitions into its own file.<br>
<br>
If you have suggestions on how to address this in a more elegant way, let me know.<span class="HOEnZb"><font color="#888888"><br>
<br>
-Krzysztof<br>
<br>
<br>
-- <br>
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation<br>
</font></span></blockquote></div><br></div>