<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=""><br class=""><div><blockquote type="cite" class=""><div class="">On May 20, 2015, at 6:14 PM, Richard Smith <<a href="mailto:richard@metafoo.co.uk" class="">richard@metafoo.co.uk</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class=""><div class="gmail_extra"><div class="gmail_quote">On Wed, May 20, 2015 at 5:59 PM, Thompson, John <span dir="ltr" class=""><<a href="mailto:John_Thompson@playstation.sony.com" target="_blank" class="">John_Thompson@playstation.sony.com</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">





<div lang="EN-US" link="blue" vlink="purple" class="">
<div class=""><p class="MsoNormal">Hi,<u class=""></u><u class=""></u></p><p class="MsoNormal"><u class=""></u> <u class=""></u></p><p class="MsoNormal">I’ve experienced a few situations where I’ve been changing a module map during development, or passing module maps to others to try, who then get mysterious warnings or errors, such as:<u class=""></u><u class=""></u></p><p class="MsoNormal"><u class=""></u> <u class=""></u></p><p class="">test.cpp:2:2: warning: missing submodule '_Builtin_intrinsics.intel.x86intrin'<u class=""></u><u class=""></u></p><p class="">      [-Wincomplete-umbrella]<u class=""></u><u class=""></u></p><p class="">#include <x86intrin.h><u class=""></u><u class=""></u></p><p class="">^       ~<u class=""></u><u class=""></u></p><p class="">1 warning generated.<u class=""></u><u class=""></u></p><p class="MsoNormal"><u class=""></u> <u class=""></u></p><p class="MsoNormal">Sometimes clang detects it, and issues a relevant warning.  Other times it does not.  (Perhaps due to a time tag being earlier?)  The recovery is to delete the module cache manually.<u class=""></u><u class=""></u></p><p class="MsoNormal"><u class=""></u> <u class=""></u></p><p class="MsoNormal">Is there something we could do to better detect a changed module map, and perhaps even better, also automatically delete the prior module cache to avoid potential problems?  Checksum/CRC the module map?  Use size and file time?</p></div></div></blockquote><div class=""><br class=""></div><div class="">We do these things, but the checks are turned off by default for system modules (to avoid stat'ing all the system headers on every compile). I think there's a flag to turn on the checks even for system modules, -fmodules-validate-system-headers I think?</div></div></div></div></div></blockquote><div><br class=""></div><div>Maybe we should flip the default, and make the unsafe behaviour opt-in?  IDEs and build systems can also use -fmodules-validate-once-per-build-session to avoid unnecessary re-checking without making it hard to edit system module maps.</div><br class=""><blockquote type="cite" class=""><div class="">
_______________________________________________<br class="">cfe-dev mailing list<br class=""><a href="mailto:cfe-dev@cs.uiuc.edu" class="">cfe-dev@cs.uiuc.edu</a><br class="">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev<br class=""></div></blockquote></div><br class=""></body></html>