<div dir="ltr"><br><br><div class="gmail_quote"><div dir="ltr">On Mon, Sep 12, 2016 at 5:00 PM Paul Robinson <<a href="mailto:paul.robinson@sony.com">paul.robinson@sony.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">probinson added a subscriber: probinson.<br class="gmail_msg">
<br class="gmail_msg">
================<br class="gmail_msg">
Comment at: lib/CodeGen/CGDebugInfo.cpp:3691<br class="gmail_msg">
@@ -3635,1 +3690,3 @@<br class="gmail_msg">
+ if (D->hasAttr<AlignedAttr>())<br class="gmail_msg">
+ AlignInBits = D->getMaxAlignment();<br class="gmail_msg">
StringRef DeclName, LinkageName;<br class="gmail_msg">
----------------<br class="gmail_msg">
dblaikie wrote:<br class="gmail_msg">
> is max alignment the right thing here? Should it be min alignment?<br class="gmail_msg">
> (is alignment in bits the desired thing across all of this too? It looked like in the backend patch there was some division by CHAR_BITS, etc?)<br class="gmail_msg">
I should think bits is the right choice here; seems more the province of the backend to convert it into the appropriate addressable units (commonly but not universally chars).<br class="gmail_msg"></blockquote><div><br>The alternative thinking is that we've a generally sense we want to make more of this type information opaque to LLVM - so I'm somewhat inclined to make the frontend do the work of choosing what to emit and the backend just being as simple as possible.<br><br>Hmm, seems like the DWARF spec details I can find: <a href="http://www.dwarfstd.org/ShowIssue.php?issue=140528.1">http://www.dwarfstd.org/ShowIssue.php?issue=140528.1</a> don't really specify what the value of DW_AT_alignment is, it's sort of assumed, by the looks of it? I'm assuming it's bytes, the same as the byte_size attribute.<br><br><br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br class="gmail_msg">
<br class="gmail_msg">
<a href="https://reviews.llvm.org/D24426" rel="noreferrer" class="gmail_msg" target="_blank">https://reviews.llvm.org/D24426</a><br class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg">
</blockquote></div></div>