[all-commits] [llvm/llvm-project] a338d5: [clang] functions with the 'const' or 'pure' attri...
dobbelaj-snps via All-commits
all-commits at lists.llvm.org
Fri Feb 19 16:34:10 PST 2021
Branch: refs/heads/release/12.x
Home: https://github.com/llvm/llvm-project
Commit: a338d577bb4fbf9013cf0c22c211d25bf3c41a26
https://github.com/llvm/llvm-project/commit/a338d577bb4fbf9013cf0c22c211d25bf3c41a26
Author: Jeroen Dobbelaere <jeroen.dobbelaere at synopsys.com>
Date: 2021-02-19 (Fri, 19 Feb 2021)
Changed paths:
M clang/lib/CodeGen/CGCall.cpp
M clang/test/CodeGen/complex-builtins.c
M clang/test/CodeGen/complex-libcalls.c
M clang/test/CodeGen/function-attributes.c
M clang/test/CodeGenCXX/2009-05-04-PureConstNounwind.cpp
M clang/test/Sema/libbuiltins-ctype-powerpc64.c
M clang/test/Sema/libbuiltins-ctype-x86_64.c
Log Message:
-----------
[clang] functions with the 'const' or 'pure' attribute must always return.
As described in
* https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-pure-function-attribute
* https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-const-function-attribute
An `__attribute__((pure))` function must always return, as well as an `__attribute__((const))` function.
Reviewed By: jdoerfert
Differential Revision: https://reviews.llvm.org/D96960
(cherry picked from commit 46757ccb49ab88da54ca8ddd43665d5255ee80f7)
More information about the All-commits
mailing list