search for: __clang__

Displaying 20 results from an estimated 55 matches for "__clang__".

2017 Feb 15
3
about "cpu.h: Fix compiler detection" patch
...s patch, all FLAC__SSEN_SUPPORTED variables are undefined for GCC, so intrinsic versions of functions are not compiled into libFLAC. Previously, the code was: #if defined __INTEL_COMPILER // definitions for ICC #elif defined _MSC_VER // definitions for MSVC #elif defined __GNUC__ || defined __clang__ #if defined __clang__ && __has_attribute(__target__) // definitions for newer clang #elif !defined __clang__ && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 9)) // definitions for newer GCC #else // definitions for older GCC and clang...
2015 Dec 01
2
Compilation errors
...In file included from /home/tthtlc/llvm/llvm/projects/compiler-rt/lib/builtins/x86_64/floatdidf.c:9:0: /home/tthtlc/llvm/llvm/projects/compiler-rt/lib/builtins/x86_64/../int_lib.h:131:8: error: C++ style comments are not allowed in ISO C90 [-Werror] #endif // defined(_MSC_VER) && !defined(__clang__) ^ /home/tthtlc/llvm/llvm/projects/compiler-rt/lib/builtins/x86_64/../int_lib.h:131:8: error: (this will be reported only once per input file) [-Werror] cc1: all warnings being treated as errors make[2]: *** [projects/compiler-rt/lib/builtins/CMakeFiles/clang_rt.builtins-x86_64.dir/x86_64/f...
2020 Aug 30
5
BUG: complete misunterstanding of the MS-ABI
Objects compiled for the MS-ABI don't conform to it! Data types beyond 64 bit MUST BE returned by the callee via the hidden first argument allocated by the caller, NOT in XMM0! Demo/proof: from this source --- llvm-bug.c --- #ifndef __clang__ typedef struct { unsigned __int64 low; unsigned __int64 high; } __uint128_t; #else __attribute__((ms_abi)) #endif __uint128_t __udivmodti4(__uint128_t dividend, __uint128_t divisor, __uint128_t *remainder) { if (remainder != 0) *remainder = divisor; return dividend; } --- E...
2019 Jul 12
8
[p2v PATCH 0/5] More small fixes
See individual patches for details. Pino Toscano (5): Include signal.h Remove unused variables Push -Wsuggest-attribute=noreturn only with GCC tests: do not set libguestfs environment variables Define the GCC version macro Makefile.am | 2 +- conversion.c | 3 +++ p2v.h | 7 +++++++ ssh.c | 8 +++++--- 4 files changed, 16 insertions(+), 4 deletions(-) -- 2.21.0
2015 Oct 28
4
RFC: Supporting macros in LLVM debug info
...Command line: clang -c -g -gmacro -O0 -DM3=Value3 -include myfile2.h mainfile.c AST ========================================================= MacroDecl 0xd6c5c0 <<invalid sloc>> <invalid sloc> __llvm__ defined MacroDecl 0xd6c618 <<invalid sloc>> <invalid sloc> __clang__ defined ... <More compiler macros> ... MacroDecl 0x11c01b0 <<invalid sloc>> <invalid sloc> M3 defined FileIncludeDecl 0x11c0208 <mainfile.c:1:1> col:1 |-FileIncludeDecl 0x11c0238 <myfile2.h:1:1> col:1 | `-MacroDecl 0x11c0268 <<invalid sloc>> <inv...
2011 May 13
0
[LLVMdev] Difficulty compiling LLVM-based tools with clang
...er had exactly the same problem trying to build rust with clang after having built llvm with gcc. The problem comes from SearchForAddressOfSpecialSymbol.cpp: // FIXME: Currently disabled when using Clang, as we don't always have our // runtime support libraries available. #ifndef __clang__ #ifdef __i386__ EXPLICIT_SYMBOL(__eprintf); #endif #endif Now, exactly what runtime library is not available is something that someone more familiar with OS X will have to answer :-) > -- > -- Talin Cheers, Rafael
2011 May 13
1
[LLVMdev] Difficulty compiling LLVM-based tools with clang
On 5/12/11 7:08 PM, Rafael Ávila de Espíndola wrote: > The problem comes from SearchForAddressOfSpecialSymbol.cpp: > > // FIXME: Currently disabled when using Clang, as we don't always > have our > // runtime support libraries available. > #ifndef __clang__ > #ifdef __i386__ > EXPLICIT_SYMBOL(__eprintf); > #endif > #endif > > Now, exactly what runtime library is not available is something that > someone more familiar with OS X will have to answer :-) The runtime support library the comment talks about is none other than com...
2015 Jul 27
1
[LLVMdev] tfloat support for mingw-w64
...ject: [PATCH 3/4] clang fixes and hacks diff --git a/mingw-w64-crt/math/log1pl.S b/mingw-w64-crt/math/log1pl.S --- a/mingw-w64-crt/math/log1pl.S +++ b/mingw-w64-crt/math/log1pl.S @@ -16,7 +16,11 @@ -1 + sqrt(2) / 2 <= x <= 1 - sqrt(2) / 2 0.29 is a safe value. */ +#ifdef __clang__ +limit: .double 0.29 // must enable .x86_fp80 for windows :) +#else // double is very dirrrrty limit: .tfloat 0.29 +#endif /* Please note: we use a double value here. Since 1.0 has an exact representation this does not effect the accuracy but it helps to optimiz...
2020 Jan 15
2
[tablegen] table readability / performance
On Wed Jan 15, 2020 at 6:58 PM, Reid Kleckner wrote: > Does the same limitation exist in VS 2017? I think that's our support > floor > these days: > https://llvm.org/docs/GettingStarted.html#host-c-toolchain-both-compiler-and-standard-library > It appears that all releases including the latest 2019 are affected. > > One *could* make the tablegen behavior conditional on the
2011 May 13
2
[LLVMdev] Difficulty compiling LLVM-based tools with clang
I recently modified my compiler's build files to use clang if it detects its available, however I'm running into a number of problems with this. I'm having one set of problems on OS X, and a different set of problems under Ubuntu. In both cases I'm attempting to link my frontend - compiled with clang - against the LLVM libraries - compiled with gcc. (I thought about compiling LLVM
2015 Nov 03
3
RFC: Supporting macros in LLVM debug info
...Command line: clang -c -g -gmacro -O0 -DM3=Value3 -include myfile2.h mainfile.c AST ========================================================= MacroDecl 0xd6c5c0 <<invalid sloc>> <invalid sloc> __llvm__ defined MacroDecl 0xd6c618 <<invalid sloc>> <invalid sloc> __clang__ defined … <More compiler macros> … MacroDecl 0x11c01b0 <<invalid sloc>> <invalid sloc> M3 defined FileIncludeDecl 0x11c0208 <mainfile.c:1:1> col:1 |-FileIncludeDecl 0x11c0238 <myfile2.h:1:1> col:1 | `-MacroDecl 0x11c0268 <<invalid sloc>> <invalid...
2020 Jan 15
2
[tablegen] table readability / performance
...CV_VER` usage in tablegen but > I'm happy to > besmirch it for this. > > > I think the cleanest way to do this would be to have a cl::opt to control > how string tables are emitted, and then control the default with `#if > defined(_MSC_VER) && !defined(__clang__)`. The !clang check is so I get the > benefits of this locally with clang-cl. :) Would this assume that the compiler compiling tablegen would be the same as compiling the generated code? I do occasionally cross compile from linux with MSVC, and in those cases, the tablegen is built as a nativ...
2014 Apr 29
2
[LLVMdev] 3.4 branch gcc 4.9 build error
...; > > > > > > > > > You can simply wrap it with #ifndef: > > > > > > > > > > namespace std > > > > > { > > > > > // We handle size_t, ptrdiff_t, and nullptr_t in c++config.h. > > > > > #ifndef __clang__ > > > > > using ::max_align_t; > > > > > #endif > > > > > } > > > > > #endif > > > > > > > > Yeah, but are you sure the bug is in libstdc++ and has to be > > > > fixed in gcc upstream? I mean, would...
2011 May 06
0
[LLVMdev] nightly test suite failure: ms_struct-bitfield-init-1.c
...o run the test-suite, for the first time in ages. It > stops rather abruptly with: > > $ make TEST=nightly report report.html This is a test that Fariborz has been working on with Clang. It is possible that llvm-gcc is expected to fail it, if this is so, the test can be put in an #ifdef __clang__. Fariborz, can you take a look? -Chris > > /home/jay/llvm/local/bin/llvm-gcc > -I/home/jay/llvm/gitobjdir/projects/test-suite/SingleSource/UnitTests > -I/home/jay/svn/llvm-project/test-suite/trunk/SingleSource/UnitTests > -I/home/jay/git/llvm/projects/test-suite/include -I../../i...
2015 Dec 01
2
Compilation errors
...started learning recently). So > take my words with a grain of salt. Nonetheless, you'll find my take > below: > > The relevant lines, I would suppose, are > > error: C++ style comments are not allowed in ISO C90 [-Werror] > #endif // defined(_MSC_VER) && !defined(__clang__) > > and > > error: (this will be reported only once per input file) [-Werror] > cc1: all warnings being treated as errors > > So, did you happen to have generated your make files using CMake > passing -DLLVM_ENABLE_WERROR=ON ? > > My reasoning is as follows (but pleas...
2014 Feb 24
3
[LLVMdev] RFC: Adding __INTEGRATED_ASSEMLER__ macro
...ht be nice to permit the user to detect that an integrated assembler is in use. The flag is intentionally generic so that if another compiler were to implement an integrated assembler, the same flag could be used. The variant could be detected similar to how the compiler is detected (e.g. defined(__clang__) && defined(__INTEGRATED_ASSEMBLER__) would indicate the LLVM IAS). This would allow for also checking the version of the assembler which is currently not possible. Doing would enable using newer features of the assembler over time, while not breaking compatibility will slightly older too...
2015 Nov 03
2
RFC: Supporting macros in LLVM debug info
...Command line: clang -c -g -gmacro -O0 -DM3=Value3 -include myfile2.h mainfile.c AST ========================================================= MacroDecl 0xd6c5c0 <<invalid sloc>> <invalid sloc> __llvm__ defined MacroDecl 0xd6c618 <<invalid sloc>> <invalid sloc> __clang__ defined … <More compiler macros> … MacroDecl 0x11c01b0 <<invalid sloc>> <invalid sloc> M3 defined FileIncludeDecl 0x11c0208 <mainfile.c:1:1> col:1 |-FileIncludeDecl 0x11c0238 <myfile2.h:1:1> col:1 | `-MacroDecl 0x11c0268 <<invalid sloc>> <invalid...
2018 Feb 09
0
retpoline mitigation and 6.0
...mpile with > -mregparm=2, but that would pessimize direct calls unnecessarily. > > It sounds like Linux is already providing its own thunks, so it might > be better to for us to go back to the __llvm_retpoline_push external > thunk name and then get Linux to provide that thunk ifdef __clang__. Yes, the thunks are different in this case. That one should indeed be renamed, and I'll provide the correct one in the kernel. However, even if I let LLVM emit the thunk for itself, code generation seems hosed. It looks like after a call to __llvm_retpoline_push (or perhaps more to the point...
2015 Nov 05
2
RFC: Supporting macros in LLVM debug info
...Command line: clang -c -g -gmacro -O0 -DM3=Value3 -include myfile2.h mainfile.c AST ========================================================= MacroDecl 0xd6c5c0 <<invalid sloc>> <invalid sloc> __llvm__ defined MacroDecl 0xd6c618 <<invalid sloc>> <invalid sloc> __clang__ defined … <More compiler macros> … MacroDecl 0x11c01b0 <<invalid sloc>> <invalid sloc> M3 defined FileIncludeDecl 0x11c0208 <mainfile.c:1:1> col:1 |-FileIncludeDecl 0x11c0238 <myfile2.h:1:1> col:1 | `-MacroDecl 0x11c0268 <<invalid sloc>> <invalid...
2015 Nov 13
2
RFC: Supporting macros in LLVM debug info
...e myfile2.h mainfile.c > > > > > > AST > > ========================================================= > > MacroDecl 0xd6c5c0 <<invalid sloc>> <invalid sloc> __llvm__ defined > > MacroDecl 0xd6c618 <<invalid sloc>> <invalid sloc> __clang__ defined > > > > … <More compiler macros> … > > > > MacroDecl 0x11c01b0 <<invalid sloc>> <invalid sloc> M3 defined > > FileIncludeDecl 0x11c0208 <mainfile.c:1:1> col:1 > > |-FileIncludeDecl 0x11c0238 <myfile2.h:1:1> col:1 > &...