[PATCH] D53765: [RFC prototype] Implementation of asm-goto support in LLVM
Nick Desaulniers via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 17 22:52:15 PST 2019
nickdesaulniers added a comment.
This looks like a codegen bug, from compiling more of the Linux kernel. It seems that an optimization from `-O1` is causing the problem: https://github.com/ClangBuiltLinux/linux/issues/320#issuecomment-455435791. I'm not sure how to help narrow it down further (which pass?). The output is from `creduce` and I've narrowed down the set of flags to Clang.
================
Comment at: lib/Transforms/Utils/InlineFunction.cpp:1512
+ if (isa<CallBrInst>(TheCall))
+ return false;
+
----------------
While I can understand punting in v1, this does cause at least one `-Wsection` like warning from the kernel: https://github.com/ClangBuiltLinux/linux/issues/317. I call it section like, because the kernel has its own tool that it uses to validate sections; some run-once kernel code and data is put into `init` sections that get discarded after first use to help save kernel memory.
The issue is that this `return false;` makes `__attribute__((always_inline))` fail. We can hack around that by converting always inline functions into macros, but I don't see that flying upstream.
So not the highest priority (it's just a warning, with no issues at runtime), but would be nice to have.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D53765/new/
https://reviews.llvm.org/D53765
More information about the llvm-commits
mailing list