<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Jun 8, 2021, at 2:56 PM, Sriraman Tallam <<a href="mailto:tmsriram@google.com" class="">tmsriram@google.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta charset="UTF-8" class=""><br class="Apple-interchange-newline"><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div class="gmail_quote" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;"><div dir="ltr" class="gmail_attr">On Tue, Jun 8, 2021 at 1:16 PM Akshith Gunasekaran <<a href="mailto:akshith.573@gmail.com" class="">akshith.573@gmail.com</a>> wrote:<br class=""></div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><div dir="ltr" class=""><div dir="ltr" class="">Hi,<div class=""><br class=""><div class="">Here is a public gist with the repro steps: <a href="https://gist.github.com/akshithg/e5a58fc7012a65e6ec2e94794d66569f" target="_blank" class="">https://gist.github.com/akshithg/e5a58fc7012a65e6ec2e94794d66569f</a></div></div><div class="">It should have 1) the config i'm using 2) the toolchain version 3) build steps</div><div class=""><br class=""></div><div class="">Feel free to shoot more questions if you need more details :)</div></div></div></blockquote><div class=""><br class=""></div><div class="">Thanks, in the interests of simplifying this further,  would it be possible to give me the preprocessed source and the failing command?</div></div></div></blockquote><div><br class=""></div>Here you go: <a href="https://gist.github.com/akshithg/e5a58fc7012a65e6ec2e94794d66569f#gistcomment-3773366" class="">https://gist.github.com/akshithg/e5a58fc7012a65e6ec2e94794d66569f#gistcomment-3773366</a></div><div>Thanks for your time and effort :)</div><div><br class=""><blockquote type="cite" class=""><div class=""><div class="gmail_quote" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;"><div class="">  </div><div class=""> </div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><div dir="ltr" class=""><div dir="ltr" class=""><div class=""><br class=""></div></div></div><br class=""><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Jun 8, 2021 at 7:24 AM Sriraman Tallam <<a href="mailto:tmsriram@google.com" target="_blank" class="">tmsriram@google.com</a>> wrote:<br class=""></div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><div dir="ltr" class=""><div dir="ltr" class=""><br class=""></div><br class=""><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Jun 7, 2021 at 10:39 PM David Blaikie <<a href="mailto:dblaikie@gmail.com" target="_blank" class="">dblaikie@gmail.com</a>> wrote:<br class=""></div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><div dir="ltr" class="">BB sections has only been tested/implemented with a fairly narrow set of flags so far as I know, and is sufficiently novel that various features won't interact correctly with it without some work to support the combination of bb sections and those features.<br class=""><br class="">I'd /guess/ BPF, for instance, probably doesn't work with BB sections out of the box & may require some work (like some work was needed to support BB sections with DWARF) - I believe BPF is mandatory/used by default when building the Linux kernel? So maybe that's what's being tripped over here. But could something else entirely - that's just my first guess.</div></blockquote><div class=""><br class=""></div><div class="">Right, we have not tried to build the linux kernel with these flags but it is something we would like to test and fix.</div><div class=""> </div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><div dir="ltr" class=""><div class=""><br class=""></div></div><br class=""><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Jun 7, 2021 at 9:15 PM A G via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" class="">llvm-dev@lists.llvm.org</a>> wrote:<br class=""></div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><div dir="ltr" class=""><div dir="ltr" class=""><div dir="ltr" class=""><div dir="ltr" class=""><div dir="ltr" class="">Hi,<div class="">I'm trying to build the linux kernel with<span class="Apple-converted-space"> </span><b class="">`clang -fbasic-block-sections=labels`.</b></div></div></div></div></div></div></blockquote></div></blockquote><div class=""><br class=""></div><div class="">Labels does not actually generate sections and it must be a simpler step as it only adds metadata to the binary.</div><div class=""> </div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><div dir="ltr" class=""><div dir="ltr" class=""><div dir="ltr" class=""><div dir="ltr" class=""><div dir="ltr" class=""><div class=""><br class=""></div>I ran into this error:</div><div dir="ltr" class=""><br class=""><font face="monospace" class="">/tmp/main-81886d.s: Assembler messages:<br class="">/tmp/main-81886d.s: Error: .size expression for .BB.set_reset_devices does not evaluate to a constant<br class="">/tmp/main-81886d.s: Error: .size expression for .BB.debug_kernel does not evaluate to a constant<br class="">/tmp/main-81886d.s: Error: .size expression for .BB.quiet_kernel does not evaluate to a constant<br class="">/tmp/main-81886d.s: Error: .size expression for .BB.loglevel does not evaluate to a constant</font></div></div></div></div></div></blockquote></div></blockquote><div class=""><br class=""></div><div class=""><br class=""></div><div class="">Would you be able to give us a smaller repro for this, we can take a look.  Basic block labels uses size expressions when generating metadata and it looks like we are not doing this right under some circumstances. </div><div class=""><br class=""></div><div class=""> </div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><div dir="ltr" class=""><div dir="ltr" class=""><div dir="ltr" class=""><div dir="ltr" class=""><div dir="ltr" class=""><br class=""></div><div class=""><span style="font-family: Roboto, RobotoDraft, Helvetica, Arial, sans-serif; font-size: 14px;" class="">make kernelversion</span><br style="font-family: Roboto, RobotoDraft, Helvetica, Arial, sans-serif; font-size: 14px;" class=""><span style="font-family: Roboto, RobotoDraft, Helvetica, Arial, sans-serif; font-size: 14px;" class="">5.10.0</span><br class=""></div><div class=""><span style="font-family: Roboto, RobotoDraft, Helvetica, Arial, sans-serif; font-size: 14px;" class=""><br class=""></span></div><div class=""><div style="font-family: Roboto, RobotoDraft, Helvetica, Arial, sans-serif; font-size: 14px;" class="">clang version 11.1.0 (g...@<a href="http://github.com" class="">github.com</a>:llvm/llvm-project.git 1fdec59bffc11ae37eb51a1b9869f0696bfd5312)<br class="">Target: x86_64-unknown-linux-gnu</div><br style="" class=""></div><div dir="ltr" class=""><br class=""></div><div class="">1. Can someone help me understand what this error means?</div><div class="">2. Is<span class="Apple-converted-space"> </span><b class="">clang-built-linux</b> a better place to ask this question?</div><div class="">3. Is there a workaround for this?</div><div class=""><br class=""></div><div class="">Thanks</div><div class="">Akshith</div><div class=""><br class=""></div></div></div></div></div>_______________________________________________<br class="">LLVM Developers mailing list<br class=""><a href="mailto:llvm-dev@lists.llvm.org" target="_blank" class="">llvm-dev@lists.llvm.org</a><br class=""><a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank" class="">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br class=""></blockquote></div></blockquote></div><br clear="all" class=""><div class=""><br class=""></div>--<span class="Apple-converted-space"> </span><br class=""><div dir="ltr" class=""><div dir="ltr" class=""><span class=""><br class=""><div dir="ltr" align="left" style="margin-left: 0pt;" class=""><table style="border: none; border-collapse: collapse;" class=""><colgroup class=""><col width="111" class=""><col width="158" class=""><col width="190" class=""><col width="16" class=""></colgroup><tbody class=""><tr style="height: 29.25pt;" class=""><td style="border-top-width: 1.5pt; border-top-style: solid; border-top-color: rgb(213, 15, 37); vertical-align: top; padding: 5pt; overflow: hidden;" class=""><div style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;" class=""><span style="font-size: 13pt; font-family: Roboto, sans-serif; color: rgb(136, 136, 136); font-weight: 700; vertical-align: baseline; white-space: pre-wrap;" class="">Sri</span><span style="font-size: 12pt; font-family: Roboto, sans-serif; color: rgb(136, 136, 136); vertical-align: baseline; white-space: pre-wrap;" class="">    Tallam |</span></div></td><td style="border-top-width: 1.5pt; border-top-style: solid; border-top-color: rgb(51, 105, 232); vertical-align: top; padding: 5pt; overflow: hidden;" class=""><div style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;" class=""><span style="font-size: 12pt; font-family: Roboto, sans-serif; color: rgb(136, 136, 136); vertical-align: baseline; white-space: pre-wrap;" class=""> Software Engineer |</span></div></td><td style="border-top-width: 1.5pt; border-top-style: solid; border-top-color: rgb(0, 153, 57); vertical-align: top; padding: 5pt; overflow: hidden;" class=""><div style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;" class=""><span style="font-size: 12pt; font-family: Roboto, sans-serif; color: rgb(136, 136, 136); vertical-align: baseline; white-space: pre-wrap;" class=""> </span><span style="font-size: 12pt; font-family: Roboto, sans-serif; color: rgb(17, 85, 204); vertical-align: baseline; white-space: pre-wrap;" class=""><a href="mailto:tmsriram@google.com" target="_blank" class="">tmsriram@google.com</a></span><span style="font-size: 12pt; font-family: Roboto, sans-serif; color: rgb(136, 136, 136); vertical-align: baseline; white-space: pre-wrap;" class=""> |</span></div></td></tr></tbody></table></div></span><div class=""></div></div></div></div></blockquote></div></blockquote></div><br clear="all" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><br class=""></div><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">--<span class="Apple-converted-space"> </span></span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div dir="ltr" class="gmail_signature" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;"><div dir="ltr" class=""><span class=""><br class=""><div dir="ltr" align="left" style="margin-left: 0pt;" class=""><table style="border: none; border-collapse: collapse;" class=""><colgroup class=""><col width="111" class=""><col width="158" class=""><col width="190" class=""><col width="16" class=""></colgroup><tbody class=""><tr style="height: 29.25pt;" class=""><td style="border-top-width: 1.5pt; border-top-style: solid; border-top-color: rgb(213, 15, 37); vertical-align: top; padding: 5pt; overflow: hidden;" class=""><div style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;" class=""><span style="font-size: 13pt; font-family: Roboto, sans-serif; color: rgb(136, 136, 136); font-weight: 700; vertical-align: baseline; white-space: pre-wrap;" class="">Sri</span><span style="font-size: 12pt; font-family: Roboto, sans-serif; color: rgb(136, 136, 136); vertical-align: baseline; white-space: pre-wrap;" class="">    Tallam |</span></div></td><td style="border-top-width: 1.5pt; border-top-style: solid; border-top-color: rgb(51, 105, 232); vertical-align: top; padding: 5pt; overflow: hidden;" class=""><div style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;" class=""><span style="font-size: 12pt; font-family: Roboto, sans-serif; color: rgb(136, 136, 136); vertical-align: baseline; white-space: pre-wrap;" class=""> Software Engineer |</span></div></td><td style="border-top-width: 1.5pt; border-top-style: solid; border-top-color: rgb(0, 153, 57); vertical-align: top; padding: 5pt; overflow: hidden;" class=""><div style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;" class=""><span style="font-size: 12pt; font-family: Roboto, sans-serif; color: rgb(136, 136, 136); vertical-align: baseline; white-space: pre-wrap;" class=""> </span><span style="font-size: 12pt; font-family: Roboto, sans-serif; color: rgb(17, 85, 204); vertical-align: baseline; white-space: pre-wrap;" class=""><a href="mailto:tmsriram@google.com" target="_blank" class="">tmsriram@google.com</a></span><span style="font-size: 12pt; font-family: Roboto, sans-serif; color: rgb(136, 136, 136); vertical-align: baseline; white-space: pre-wrap;" class=""> |</span></div></td></tr></tbody></table></div></span></div></div></div></blockquote></div><br class=""></body></html>