[all-commits] [llvm/llvm-project] 89f1ad: [LangRef] Introduce `noundef` attribute for fully ...
Gui Andrade via All-commits
all-commits at lists.llvm.org
Wed Jul 8 12:02:25 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: 89f1ad88b3f1ecf32e797247b9eab5662ed4bcf4
https://github.com/llvm/llvm-project/commit/89f1ad88b3f1ecf32e797247b9eab5662ed4bcf4
Author: Gui Andrade <guiand at google.com>
Date: 2020-07-08 (Wed, 08 Jul 2020)
Changed paths:
M llvm/docs/BitCodeFormat.rst
M llvm/docs/LangRef.rst
Log Message:
-----------
[LangRef] Introduce `noundef` attribute for fully defined function params
LLVM currently does not require function parameters or return values
to be fully initialized, and does not care if they are poison. This can
be useful if the frontend ABI makes no such demands, but may prevent
helpful backend transformations in case they do. Specifically, the C
and C++ languages require all scalar function operands to be fully
determined.
Introducing this attribute is of particular use to MemorySanitizer
today, although other transformations may benefit from it as well.
We can modify MemorySanitizer instrumentation to provide modest (17%)
space savings where `frozen` is present.
This commit only adds the attribute to the Language Reference, and
the actual implementation of the attribute will follow in a separate
commit.
Differential Revision: https://reviews.llvm.org/D82316
Commit: ff7900d5def4f645a6675d99ad39a38d8a468a63
https://github.com/llvm/llvm-project/commit/ff7900d5def4f645a6675d99ad39a38d8a468a63
Author: Gui Andrade <guiand at google.com>
Date: 2020-07-08 (Wed, 08 Jul 2020)
Changed paths:
M llvm/include/llvm/Bitcode/LLVMBitCodes.h
M llvm/include/llvm/IR/Attributes.td
M llvm/lib/AsmParser/LLLexer.cpp
M llvm/lib/AsmParser/LLParser.cpp
M llvm/lib/AsmParser/LLToken.h
M llvm/lib/Bitcode/Reader/BitcodeReader.cpp
M llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
M llvm/lib/IR/Attributes.cpp
M llvm/lib/Transforms/Utils/CodeExtractor.cpp
M llvm/test/Bitcode/attributes.ll
Log Message:
-----------
[LLVM] Accept `noundef` attribute in function definitions/calls
The `noundef` attribute indicates an argument or return value which
may never have an undef value representation.
This patch allows LLVM to parse the attribute.
Differential Revision: https://reviews.llvm.org/D83412
Compare: https://github.com/llvm/llvm-project/compare/512c90389839...ff7900d5def4
More information about the All-commits
mailing list