<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi Kevin<div class=""><br class=""></div><div class="">That is a very good concern and we have ways to address the issue in our bitcode implementation to achieve similar something similar to ‘strip’ (hiding unnecessary symbols and debug info). It wasn’t in the proposal because we would like to get the basics in before diving into something more detailed and controversial. </div><div class="">Here is a short description about how we deal with the issue. Our implementation requires linker support which runs a ‘Linkage-Unit’ pass that consistently rename all the symbols and metadata that are not exported. This has to be done after resolving all the symbols. We would be happy to upstream our implementation if it is beneficial.</div><div class=""><br class=""></div><div class="">Thanks</div><div class=""><br class=""></div><div class="">Steven</div><div class=""><br class=""></div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Feb 6, 2016, at 2:57 PM, Smith, Kevin B <<a href="mailto:kevin.b.smith@intel.com" class="">kevin.b.smith@intel.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="WordSection1" style="page: WordSection1; font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: 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=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">Hal,<o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class=""><o:p class=""> </o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">No, it is not more of a problem than with DWARF info. DWARF info definitely contains personally identifiable information. However, people usually realize that is the case,<o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">and will turn off or strip debug info if they are worried about such issues, or make a specific plan to cleanse that information.<o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class=""><o:p class=""> </o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">You really just want to attempt to eliminate such information to the greatest extent possible. The desirability of using embedded Bitcode in libraries (which is a very<o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">natural use model, that I'm pretty sure this is intended to support), will be improved by taking into consideration this aspect of the implementation.<o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class=""><o:p class=""> </o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">Kevin Smith<o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class=""><o:p class=""> </o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class=""><o:p class=""> </o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class=""><o:p class=""> </o:p></span></div><div style="border-style: none none none solid; border-left-color: blue; border-left-width: 1.5pt; padding: 0in 0in 0in 4pt;" class=""><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; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><a name="_____replyseparator" class=""></a><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>Hal Finkel [<a href="mailto:hfinkel@anl.gov" class="">mailto:hfinkel@anl.gov</a>]<span class="Apple-converted-space"> </span><br class=""><b class="">Sent:</b><span class="Apple-converted-space"> </span>Saturday, February 06, 2016 2:37 PM<br class=""><b class="">To:</b><span class="Apple-converted-space"> </span>Smith, Kevin B <<a href="mailto:kevin.b.smith@intel.com" class="">kevin.b.smith@intel.com</a>><br class=""><b class="">Cc:</b><span class="Apple-converted-space"> </span><a href="mailto:llvm-dev@lists.llvm.org" class="">llvm-dev@lists.llvm.org</a>; Clang Dev <<a href="mailto:cfe-dev@lists.llvm.org" class="">cfe-dev@lists.llvm.org</a>>; James Y Knight <<a href="mailto:jyknight@google.com" class="">jyknight@google.com</a>>; Steven Wu <<a href="mailto:stevenwu@apple.com" class="">stevenwu@apple.com</a>><br class=""><b class="">Subject:</b><span class="Apple-converted-space"> </span>Re: [llvm-dev] [RFC] Embedding Bitcode in Object Files<o:p class=""></o:p></span></div></div></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 class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif;" class=""><o:p class=""> </o:p></span></div><div class="MsoNormal" align="center" style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif; text-align: center;"><span style="font-size: 10pt; font-family: Arial, sans-serif;" class=""><hr size="2" width="100%" align="center" id="zwchr" class=""></span></div><blockquote style="border-style: none none none solid; border-left-color: rgb(16, 16, 255); border-left-width: 1.5pt; padding: 0in 0in 0in 4pt; margin-left: 3.75pt; margin-top: 5pt; margin-bottom: 5pt;" class=""><p class="MsoNormal" style="margin: 0in 0in 12pt; font-size: 12pt; font-family: 'Times New Roman', serif;"><b class=""><span style="font-family: Helvetica, sans-serif;" class="">From:<span class="Apple-converted-space"> </span></span></b><span style="font-family: Helvetica, sans-serif;" class="">"Kevin B via llvm-dev Smith" <<a href="mailto:llvm-dev@lists.llvm.org" style="color: purple; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>><br class=""><b class="">To:<span class="Apple-converted-space"> </span></b>"James Y Knight" <<a href="mailto:jyknight@google.com" style="color: purple; text-decoration: underline;" class="">jyknight@google.com</a>>, "Steven Wu" <<a href="mailto:stevenwu@apple.com" style="color: purple; text-decoration: underline;" class="">stevenwu@apple.com</a>><br class=""><b class="">Cc:<span class="Apple-converted-space"> </span></b><a href="mailto:llvm-dev@lists.llvm.org" style="color: purple; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>, "Clang Dev" <<a href="mailto:cfe-dev@lists.llvm.org" style="color: purple; text-decoration: underline;" class="">cfe-dev@lists.llvm.org</a>><br class=""><b class="">Sent:<span class="Apple-converted-space"> </span></b>Saturday, February 6, 2016 4:30:20 PM<br class=""><b class="">Subject:<span class="Apple-converted-space"> </span></b>Re: [llvm-dev] [RFC] Embedding Bitcode in Object Files<o:p class=""></o:p></span></p><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">I don't know whether this is an issue in the current implementation, but I wanted to bring up a potential privacy issue.</span><span style="" class=""><o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class=""> </span><span style="" class=""><o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">In embedding the information, care should be taken to avoid embedding any information that contains personally identifiable information. This can certainly occur</span><span style="" class=""><o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">if paths need to be embedded, as user names, or other private/confidential information may be present in the naming of directories and paths.</span><span style="" class=""><o:p class=""></o:p></span></div></blockquote><p class="MsoNormal" style="margin: 0in 0in 12pt; font-size: 12pt; font-family: 'Times New Roman', serif;"><span style="font-size: 10pt; font-family: Arial, sans-serif;" class=""><br class="">Is this any more of a problem than the information that gets included in the DWARF sections?<br class=""><br class=""> -Hal<o:p class=""></o:p></span></p><blockquote style="border-style: none none none solid; border-left-color: rgb(16, 16, 255); border-left-width: 1.5pt; padding: 0in 0in 0in 4pt; margin-left: 3.75pt; margin-top: 5pt; margin-bottom: 5pt;" class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class=""> Generally, I suspect</span><span style="" class=""><o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">that it would be desirable to have an opt-in strategy for designating in the compiler which pieces of information/options need to be saved, and for all options marked</span><span style="" class=""><o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">as needed, determine whether there is the possibility/likelihood that they may contain personally identifiable information.</span><span style="" class=""><o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class=""> </span><span style="" class=""><o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class="">Kevin B. Smith</span><span style="" class=""><o:p class=""></o:p></span></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif; color: rgb(68, 84, 106);" class=""> </span><span style="" class=""><o:p class=""></o:p></span></div><div style="border-style: none none none solid; border-left-color: windowtext; border-left-width: 1.5pt; padding: 0in 0in 0in 4pt;" class=""><div class=""><div style="border-style: solid none none; border-top-color: windowtext; border-top-width: 1pt; padding: 3pt 0in 0in;" class=""><div style="margin: 0in 0in 0.0001pt; 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>llvm-dev [<a href="mailto:llvm-dev-bounces@lists.llvm.org" style="color: purple; text-decoration: underline;" class="">mailto:llvm-dev-bounces@lists.llvm.org</a>]<span class="Apple-converted-space"> </span><b class="">On Behalf Of<span class="Apple-converted-space"> </span></b>James Y Knight via llvm-dev<br class=""><b class="">Sent:</b><span class="Apple-converted-space"> </span>Friday, February 05, 2016 3:13 PM<br class=""><b class="">To:</b><span class="Apple-converted-space"> </span>Steven Wu <<a href="mailto:stevenwu@apple.com" style="color: purple; text-decoration: underline;" class="">stevenwu@apple.com</a>><br class=""><b class="">Cc:</b><span class="Apple-converted-space"> </span>LLVM Developers Mailing List <<a href="mailto:llvm-dev@lists.llvm.org" style="color: purple; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>>; Clang Dev <<a href="mailto:cfe-dev@lists.llvm.org" style="color: purple; text-decoration: underline;" class="">cfe-dev@lists.llvm.org</a>><br class=""><b class="">Subject:</b><span class="Apple-converted-space"> </span>Re: [llvm-dev] [RFC] Embedding Bitcode in Object Files</span><span style="" class=""><o:p class=""></o:p></span></div></div></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="" class=""> <o:p class=""></o:p></span></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="" class=""> <o:p class=""></o:p></span></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="" class=""> <o:p class=""></o:p></span></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="" class="">On Fri, Feb 5, 2016 at 6:06 PM, Steven Wu <<a href="mailto:stevenwu@apple.com" target="_blank" style="color: purple; text-decoration: underline;" class="">stevenwu@apple.com</a>> wrote:<o:p class=""></o:p></span></div><blockquote style="border-style: none none none solid; border-left-color: windowtext; border-left-width: 1pt; padding: 0in 0in 0in 6pt; margin: 5pt 0in 5pt 4.8pt;" class=""><div class=""><div class=""><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="color: rgb(34, 34, 34);" class="">I don't think we need any path in the command line section. We only record the command-line options that will affect CodeGen. See my example in one of the preview reply:</span><span style="" class=""><o:p class=""></o:p></span></div></div></div><div class=""><blockquote style="margin-top: 5pt; margin-bottom: 5pt;" class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="" class="">$ clang -fembed-bitcode -O0 test.c -c -###<br class="">"clang" "-cc1" (...lots of options...) "-o" "test.bc" "-x" "c" "test.c" <--- First stage<br class="">"clang" "-cc1" "-triple" "x86_64-apple-macosx10.11.0" "-emit-obj" "-fembed-bitcode" "-O0" "-disable-llvm-optzns" "-o" "test.o" "-x" "ir" "test.bc" <--- Second stage<o:p class=""></o:p></span></div></blockquote><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="" class="">I can't think of any source path that can affect CodeGen. There should not be any paths other than the bitcode input path and binary output path exists in the second stage and they are excluded from the command line section as well. -fdebug-prefix-map is consumed by the front-end and prefixed paths are a part of the debug info in the metadata. You don't need to encode -fdebug-prefix-map in the bitcode section to reproduce the object file with the same debug info. Did that answer your concern?<o:p class=""></o:p></span></div></div></div></blockquote></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="" class=""> <o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="" class="">Great -- it wasn't clear from the first message if you were just embedding the whole command-line as is. If the plan instead to embed only a few relevant options, I agree there should be no issue as far as paths go.<o:p class=""></o:p></span></div></div></div></div><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-family: Helvetica, sans-serif;" class=""><br class="">_______________________________________________<br class="">LLVM Developers mailing list<br class=""><a href="mailto:llvm-dev@lists.llvm.org" style="color: purple; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a><br class=""><a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" style="color: purple; text-decoration: underline;" class="">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><o:p class=""></o:p></span></div></blockquote><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif;" class=""><br class=""><br class=""><br class="">--<span class="Apple-converted-space"> </span><o:p class=""></o:p></span></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 12pt; font-family: 'Times New Roman', serif;" class=""><span style="font-size: 10pt; font-family: Arial, sans-serif;" class="">Hal Finkel<br class="">Assistant Computational Scientist<br class="">Leadership Computing Facility<br class="">Argonne National Laboratory</span></div></div></div></div></div></div></blockquote></div><br class=""></div></body></html>