Remove checks for old gcc versions for LLVM_ATTRIBUTE_*
authorArthur Eubanks <aeubanks@google.com>
Mon, 11 Oct 2021 21:45:34 +0000 (14:45 -0700)
committerArthur Eubanks <aeubanks@google.com>
Tue, 12 Oct 2021 18:19:48 +0000 (11:19 -0700)
commit26827337dff26ba3450721f880d4c6caaf2a8219
tree0a0ac6aae582b62508f0fd66fb48a82c482d6e0d
parent9e9803bf82500b8a075d9658d2b4c248115f4a6f
Remove checks for old gcc versions for LLVM_ATTRIBUTE_*

According to [1] we only support gcc 5.1+. So these checks for older gcc versions are not supported.

Some gcc 5.1+ versions still don't support __has_builtin, so just check __GNUC__ in those cases.

Add a missing #endif for LLVM_ATTRIBUTE_UNREACHABLE.

[1] https://llvm.org/docs/GettingStarted.html#host-c-toolchain-both-compiler-and-standard-library

Reviewed By: MaskRay

Differential Revision: https://reviews.llvm.org/D111581
llvm/include/llvm/Support/Compiler.h