From bda3d407185047106bde6af5367ddab7d3a3142f Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Thu, 19 Feb 2015 20:57:58 +0000 Subject: [PATCH 1/3] Vendor import of clang RELEASE_360/rc4 tag r229772 (effectively, 3.6.0 RC4): https://llvm.org/svn/llvm-project/cfe/tags/RELEASE_360/rc4@229772 --- docs/ReleaseNotes.rst | 39 ++++++++++++--------------------- lib/CodeGen/TargetInfo.cpp | 18 ++++++--------- lib/Driver/ToolChains.cpp | 3 ++- test/CodeGen/x86_64-arguments.c | 22 +++++++++++++++++++ 4 files changed, 45 insertions(+), 37 deletions(-) diff --git a/docs/ReleaseNotes.rst b/docs/ReleaseNotes.rst index 337f9387fe6..5aeb2ad5a4f 100644 --- a/docs/ReleaseNotes.rst +++ b/docs/ReleaseNotes.rst @@ -1,6 +1,6 @@ -===================================== -Clang 3.6 (In-Progress) Release Notes -===================================== +======================= +Clang 3.6 Release Notes +======================= .. contents:: :local: @@ -8,12 +8,6 @@ Clang 3.6 (In-Progress) Release Notes Written by the `LLVM Team `_ -.. warning:: - - These are in-progress notes for the upcoming Clang 3.6 release. You may - prefer the `Clang 3.5 Release Notes - `_. - Introduction ============ @@ -22,8 +16,8 @@ frontend, part of the LLVM Compiler Infrastructure, release 3.6. Here we describe the status of Clang in some detail, including major improvements from the previous release and new feature work. For the general LLVM release notes, see `the LLVM -documentation `_. All LLVM -releases may be downloaded from the `LLVM releases web +documentation `_. +All LLVM releases may be downloaded from the `LLVM releases web site `_. For more information about Clang or LLVM, including information about @@ -31,11 +25,6 @@ the latest release, please check out the main please see the `Clang Web Site `_ or the `LLVM Web Site `_. -Note that if you are reading this file from a Subversion checkout or the -main Clang web page, this document applies to the *next* release, not -the current one. To see the release notes for a specific release, please -see the `releases page `_. - What's New in Clang 3.6? ======================== @@ -163,15 +152,15 @@ OpenCL C Language Changes in Clang OpenMP Language Changes in Clang -------------------------------- -Clang 3.6 contains codegen for many individual pragmas for OpenMP but combinations are not completed as yet. -We plan to continue codegen code drop aiming for completion for 3.7. Please see this link for up-to-date -`status _` -LLVM’s OpenMP runtime library, originally developed by Intel, has been modified to work on ARM, PowerPC, -as well as X86. The Runtime Library's compatibility with GCC 4.9 is improved -- missed entry points added, Barrier and fork/join code improved, one more type of barrier enabled. -Support for ppc64le architecture is now available and automatically detected when using cmake system. -Using makefile the new "ppc64le" arch type is available. -Contributors to this work include AMD, Argonne National Lab., IBM, Intel, Texas Instruments, University of Houston and many others. +Clang 3.6 contains codegen for many individual OpenMP pragmas, but combinations are not completed as yet. +We plan to continue codegen code drop aiming for completion in 3.7. Please see this link for up-to-date +`status _`. +LLVM's OpenMP runtime library, originally developed by Intel, has been modified to work on ARM, PowerPC, +as well as X86. The Runtime Library's compatibility with GCC 4.9 is improved +- missed entry points added, barrier and fork/join code improved, one more type of barrier enabled. +Support for ppc64le architecture is now available and automatically detected when using cmake system. +Using makefile the new "ppc64le" arch type is available. +Contributors to this work include AMD, Argonne National Lab., IBM, Intel, Texas Instruments, University of Houston and many others. Internal API Changes -------------------- diff --git a/lib/CodeGen/TargetInfo.cpp b/lib/CodeGen/TargetInfo.cpp index 6ad34951576..39cc7e5d99c 100644 --- a/lib/CodeGen/TargetInfo.cpp +++ b/lib/CodeGen/TargetInfo.cpp @@ -2134,19 +2134,15 @@ ABIArgInfo X86_64ABIInfo::getIndirectResult(QualType Ty, return ABIArgInfo::getIndirect(Align); } -/// GetByteVectorType - The ABI specifies that a value should be passed in an -/// full vector XMM/YMM register. Pick an LLVM IR type that will be passed as a -/// vector register. +/// The ABI specifies that a value should be passed in a full vector XMM/YMM +/// register. Pick an LLVM IR type that will be passed as a vector register. llvm::Type *X86_64ABIInfo::GetByteVectorType(QualType Ty) const { - llvm::Type *IRType = CGT.ConvertType(Ty); + // Wrapper structs/arrays that only contain vectors are passed just like + // vectors; strip them off if present. + if (const Type *InnerTy = isSingleElementStruct(Ty, getContext())) + Ty = QualType(InnerTy, 0); - // Wrapper structs that just contain vectors are passed just like vectors, - // strip them off if present. - llvm::StructType *STy = dyn_cast(IRType); - while (STy && STy->getNumElements() == 1) { - IRType = STy->getElementType(0); - STy = dyn_cast(IRType); - } + llvm::Type *IRType = CGT.ConvertType(Ty); // If the preferred type is a 16-byte vector, prefer to pass it. if (llvm::VectorType *VT = dyn_cast(IRType)){ diff --git a/lib/Driver/ToolChains.cpp b/lib/Driver/ToolChains.cpp index 4d97ab3bf48..f789fd55598 100644 --- a/lib/Driver/ToolChains.cpp +++ b/lib/Driver/ToolChains.cpp @@ -3154,7 +3154,8 @@ void Linux::AddClangSystemIncludeArgs(const ArgList &DriverArgs, SmallVector dirs; CIncludeDirs.split(dirs, ":"); for (StringRef dir : dirs) { - StringRef Prefix = llvm::sys::path::is_absolute(dir) ? SysRoot : ""; + StringRef Prefix = + llvm::sys::path::is_absolute(dir) ? StringRef(SysRoot) : ""; addExternCSystemInclude(DriverArgs, CC1Args, Prefix + dir); } return; diff --git a/test/CodeGen/x86_64-arguments.c b/test/CodeGen/x86_64-arguments.c index 5d01d3bf69e..e82e7b067ad 100644 --- a/test/CodeGen/x86_64-arguments.c +++ b/test/CodeGen/x86_64-arguments.c @@ -184,6 +184,28 @@ struct v4f32wrapper f27(struct v4f32wrapper X) { return X; } +// PR22563 - We should unwrap simple structs and arrays to pass +// and return them in the appropriate vector registers if possible. + +typedef float v8f32 __attribute__((__vector_size__(32))); +struct v8f32wrapper { + v8f32 v; +}; + +struct v8f32wrapper f27a(struct v8f32wrapper X) { + // AVX-LABEL: define <8 x float> @f27a(<8 x float> %X.coerce) + return X; +} + +struct v8f32wrapper_wrapper { + v8f32 v[1]; +}; + +struct v8f32wrapper_wrapper f27b(struct v8f32wrapper_wrapper X) { + // AVX-LABEL: define <8 x float> @f27b(<8 x float> %X.coerce) + return X; +} + // rdar://5711709 struct f28c { double x; From b6bcb9a905dec7821221e8ceaf1504c1f329815e Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Wed, 25 Feb 2015 18:25:34 +0000 Subject: [PATCH 2/3] Vendor import of llvm RELEASE_360/final tag r230434 (effectively, 3.6.0 release): https://llvm.org/svn/llvm-project/llvm/tags/RELEASE_360/final@230434 --- bindings/go/llvm/linker.go | 11 +++- bindings/ocaml/linker/linker_ocaml.c | 6 +- bindings/ocaml/linker/llvm_linker.ml | 8 ++- bindings/ocaml/linker/llvm_linker.mli | 9 ++- docs/ReleaseNotes.rst | 93 +++++++++++++++++++++++---- include/llvm-c/Linker.h | 10 ++- lib/Linker/LinkModules.cpp | 2 +- test/Bindings/OCaml/linker.ml | 2 +- 8 files changed, 119 insertions(+), 22 deletions(-) diff --git a/bindings/go/llvm/linker.go b/bindings/go/llvm/linker.go index 64d794efb94..31e9ad24bf5 100644 --- a/bindings/go/llvm/linker.go +++ b/bindings/go/llvm/linker.go @@ -20,9 +20,16 @@ package llvm import "C" import "errors" -func LinkModules(Dest, Src Module) error { +type LinkerMode C.LLVMLinkerMode + +const ( + LinkerDestroySource = C.LLVMLinkerDestroySource + LinkerPreserveSource = C.LLVMLinkerPreserveSource +) + +func LinkModules(Dest, Src Module, Mode LinkerMode) error { var cmsg *C.char - failed := C.LLVMLinkModules(Dest.C, Src.C, 0, &cmsg) + failed := C.LLVMLinkModules(Dest.C, Src.C, C.LLVMLinkerMode(Mode), &cmsg) if failed != 0 { err := errors.New(C.GoString(cmsg)) C.LLVMDisposeMessage(cmsg) diff --git a/bindings/ocaml/linker/linker_ocaml.c b/bindings/ocaml/linker/linker_ocaml.c index 3b8512aa595..ed37777d852 100644 --- a/bindings/ocaml/linker/linker_ocaml.c +++ b/bindings/ocaml/linker/linker_ocaml.c @@ -23,11 +23,11 @@ void llvm_raise(value Prototype, char *Message); -/* llmodule -> llmodule -> unit */ -CAMLprim value llvm_link_modules(LLVMModuleRef Dst, LLVMModuleRef Src) { +/* llmodule -> llmodule -> Mode.t -> unit */ +CAMLprim value llvm_link_modules(LLVMModuleRef Dst, LLVMModuleRef Src, value Mode) { char* Message; - if (LLVMLinkModules(Dst, Src, 0, &Message)) + if (LLVMLinkModules(Dst, Src, Int_val(Mode), &Message)) llvm_raise(*caml_named_value("Llvm_linker.Error"), Message); return Val_unit; diff --git a/bindings/ocaml/linker/llvm_linker.ml b/bindings/ocaml/linker/llvm_linker.ml index 3044abd8b6c..5854d70bb52 100644 --- a/bindings/ocaml/linker/llvm_linker.ml +++ b/bindings/ocaml/linker/llvm_linker.ml @@ -11,5 +11,11 @@ exception Error of string let () = Callback.register_exception "Llvm_linker.Error" (Error "") -external link_modules : Llvm.llmodule -> Llvm.llmodule -> unit +module Mode = struct + type t = + | DestroySource + | PreserveSource +end + +external link_modules : Llvm.llmodule -> Llvm.llmodule -> Mode.t -> unit = "llvm_link_modules" diff --git a/bindings/ocaml/linker/llvm_linker.mli b/bindings/ocaml/linker/llvm_linker.mli index 06c3b92a577..4def7a8cc98 100644 --- a/bindings/ocaml/linker/llvm_linker.mli +++ b/bindings/ocaml/linker/llvm_linker.mli @@ -14,6 +14,13 @@ exception Error of string +(** Linking mode. *) +module Mode : sig + type t = + | DestroySource + | PreserveSource +end + (** [link_modules dst src mode] links [src] into [dst], raising [Error] if the linking fails. *) -val link_modules : Llvm.llmodule -> Llvm.llmodule -> unit \ No newline at end of file +val link_modules : Llvm.llmodule -> Llvm.llmodule -> Mode.t -> unit \ No newline at end of file diff --git a/docs/ReleaseNotes.rst b/docs/ReleaseNotes.rst index d769b348ab7..04d7f526651 100644 --- a/docs/ReleaseNotes.rst +++ b/docs/ReleaseNotes.rst @@ -37,7 +37,8 @@ Non-comprehensive list of changes in this release * Added support for a `native object file-based bitcode wrapper format `_. -* ... next change ... +* Added support for MSVC's ``__vectorcall`` calling convention as + ``x86_vectorcallcc``. .. NOTE If you would like to document a larger change, then you can add a @@ -293,12 +294,13 @@ The old JIT has been removed All users should transition to MCJIT. -object::Binary doesn't owns the file buffer +object::Binary doesn't own the file buffer ------------------------------------------- It is now just a wrapper, which simplifies using object::Binary with other users of the underlying file. + IR in object files is now supported ----------------------------------- @@ -318,7 +320,7 @@ The new implementation is also lazier and has a ``save-temps`` option. Change in the representation of lazy loaded funcs ------------------------------------------------- -Lazy loaded functions are now represented is a way that ``isDeclaration`` +Lazy loaded functions are now represented in a way that ``isDeclaration`` returns the correct answer even before reading the body. @@ -333,10 +335,11 @@ Python 2.7 is now required This was done to simplify compatibility with python 3. + The leak detector has been removed ---------------------------------- -In practice tools like asan and valgrind were finding way more bugs than +In practice, tools like asan and valgrind were finding way more bugs than the old leak detector, so it was removed. @@ -351,12 +354,25 @@ The syntax of comdats was changed to @g = global i32 0, comdat($c) @c = global i32 0, comdat -The version without the parentheses is a syntatic sugar for a comdat with +The version without the parentheses is a syntactic sugar for a comdat with the same name as the global. -Diagnotic infrastructure used by lib/Linker and lib/Bitcode ------------------------------------------------------------ +Added support for Win64 unwind information +------------------------------------------ + +LLVM now obeys the `Win64 prologue and epilogue conventions +`_ documented by +Microsoft. Unwind information is also emitted into the .xdata section. + +As a result of the ABI-required prologue changes, it is now no longer possible +to unwind the stack using a standard frame pointer walk on Win64. Instead, +users should call ``CaptureStackBackTrace``, or implement equivalent +functionality by consulting the unwind tables present in the binary. + + +Diagnostic infrastructure used by lib/Linker and lib/Bitcode +------------------------------------------------------------ These libraries now use the diagnostic handler to print errors and warnings. This provides better error messages and simpler error handling. @@ -367,12 +383,27 @@ The PreserveSource linker mode was removed It was fairly broken and was removed. +The mode is currently still available in the C API for source +compatibility, but it doesn't have any effect. -Changes to the ARM Backend --------------------------- +Garbage Collection +------------------ +A new experimental mechanism for describing a garbage collection safepoint was +added to LLVM. The new mechanism was not complete at the point this release +was branched so it is recommended that anyone interested in using this +mechanism track the ongoing development work on tip of tree. The hope is that +these intrinsics will be ready for general use by 3.7. Documentation can be +found `here `_. - During this release ... +The existing gc.root implementation is still supported and as fully featured +as it ever was. However, two features from GCStrategy will likely be removed +in the 3.7 release (performCustomLowering and findCustomSafePoints). If you +have a use case for either, please mention it on llvm-dev so that it can be +considered for future development. + +We are expecting to migrate away from gc.root in the 3.8 time frame, +but both mechanisms will be supported in 3.7. Changes to the MIPS Target @@ -385,6 +416,7 @@ compile the Linux kernel for 32-bit targets. Additionally, LLD now supports microMIPS for the O32 ABI on little endian targets, and code generation for microMIPS is almost completely passing the test-suite. + ABI ^^^ @@ -417,6 +449,7 @@ few notable ones: has been fixed when the fastcc calling convention is used with 64-bit FPU's and -mno-odd-spreg. + LLVMLinux ^^^^^^^^^ @@ -433,6 +466,7 @@ number of kernel patches. See the `LLVMLinux project * Added support for a number of directives used by Linux to the Integrated Assembler. + Miscellaneous ^^^^^^^^^^^^^ @@ -449,6 +483,7 @@ Miscellaneous is in use and will be removed in LLVM 3.7. These names have never been supported by the GNU Assembler for these ABI's. + Changes to the PowerPC Target ----------------------------- @@ -459,7 +494,7 @@ There are numerous improvements to the PowerPC target in this release: * LLVM now has a POWER8 instruction scheduling description. -* Address Sanitizer (ASAN) support is now fully functional. +* AddressSanitizer (ASan) support is now fully functional. * Performance of simple atomic accesses has been greatly improved. @@ -470,8 +505,11 @@ There are numerous improvements to the PowerPC target in this release: * PPC32 SVR4 now supports small-model PIC. +* Experimental support for the stackmap/patchpoint intrinsics has been added. + * There have been many smaller bug fixes and performance improvements. + Changes to the OCaml bindings ----------------------------- @@ -498,6 +536,14 @@ Changes to the OCaml bindings * As usual, many more functions have been exposed to OCaml. + +Go bindings +----------- + +* A set of Go bindings based on `gollvm `_ + was introduced in this release. + + External Open Source Projects Using LLVM 3.6 ============================================ @@ -505,6 +551,7 @@ An exciting aspect of LLVM is that it is used as an enabling technology for a lot of other language and tools projects. This section lists some of the projects that have already been updated to work with LLVM 3.6. + Portable Computing Language (pocl) ---------------------------------- @@ -517,6 +564,7 @@ statically parallelize multiple work-items with the kernel compiler, even in the presence of work-group barriers. This enables static parallelization of the fine-grained static concurrency in the work groups in multiple ways. + TTA-based Co-design Environment (TCE) ------------------------------------- @@ -535,11 +583,12 @@ new LLVM-based code generators "on the fly" for the designed processors and loads them in to the compiler backend as runtime libraries to avoid per-target recompilation of larger parts of the compiler chain. + Likely ------ `Likely `_ is an embeddable just-in-time Lisp for -image recognition and heterogenous computing. Algorithms are just-in-time +image recognition and heterogeneous computing. Algorithms are just-in-time compiled using LLVM's MCJIT infrastructure to execute on single or multi-threaded CPUs and potentially OpenCL SPIR or CUDA enabled GPUs. Likely seeks to explore new optimizations for statistical learning @@ -547,6 +596,7 @@ algorithms by moving them from an offline model generation step to the compile-time evaluation of a function (the learning algorithm) with constant arguments (the training data). + LDC - the LLVM-based D compiler ------------------------------- @@ -562,6 +612,25 @@ x86/x86_64 systems like Linux, OS X, FreeBSD and Windows and also Linux on PowerPC (32/64 bit). Ports to other architectures like ARM, AArch64 and MIPS64 are underway. + +LLVMSharp & ClangSharp +---------------------- + +`LLVMSharp `_ and +`ClangSharp `_ are type-safe C# bindings for +Microsoft.NET and Mono that Platform Invoke into the native libraries. +ClangSharp is self-hosted and is used to generated LLVMSharp using the +LLVM-C API. + +`LLVMSharp Kaleidoscope Tutorials `_ +are instructive examples of writing a compiler in C#, with certain improvements +like using the visitor pattern to generate LLVM IR. + +`ClangSharp PInvoke Generator `_ is the +self-hosting mechanism for LLVM/ClangSharp and is demonstrative of using +LibClang to generate Platform Invoke (PInvoke) signatures for C APIs. + + Additional Information ====================== diff --git a/include/llvm-c/Linker.h b/include/llvm-c/Linker.h index cedde5ea8e3..a932c6d0f07 100644 --- a/include/llvm-c/Linker.h +++ b/include/llvm-c/Linker.h @@ -20,13 +20,21 @@ extern "C" { #endif + +/* Note: LLVMLinkerPreserveSource has no effect. */ +typedef enum { + LLVMLinkerDestroySource = 0, /* Allow source module to be destroyed. */ + LLVMLinkerPreserveSource = 1 /* Preserve the source module. */ +} LLVMLinkerMode; + + /* Links the source module into the destination module, taking ownership * of the source module away from the caller. Optionally returns a * human-readable description of any errors that occurred in linking. * OutMessage must be disposed with LLVMDisposeMessage. The return value * is true if an error occurred, false otherwise. */ LLVMBool LLVMLinkModules(LLVMModuleRef Dest, LLVMModuleRef Src, - unsigned Unused, char **OutMessage); + LLVMLinkerMode Mode, char **OutMessage); #ifdef __cplusplus } diff --git a/lib/Linker/LinkModules.cpp b/lib/Linker/LinkModules.cpp index 767d465d1be..d5170adb36a 100644 --- a/lib/Linker/LinkModules.cpp +++ b/lib/Linker/LinkModules.cpp @@ -1749,7 +1749,7 @@ bool Linker::LinkModules(Module *Dest, Module *Src) { //===----------------------------------------------------------------------===// LLVMBool LLVMLinkModules(LLVMModuleRef Dest, LLVMModuleRef Src, - unsigned Unused, char **OutMessages) { + LLVMLinkerMode Mode, char **OutMessages) { Module *D = unwrap(Dest); std::string Message; raw_string_ostream Stream(Message); diff --git a/test/Bindings/OCaml/linker.ml b/test/Bindings/OCaml/linker.ml index 1ea0be9d3dc..0a365ff8148 100644 --- a/test/Bindings/OCaml/linker.ml +++ b/test/Bindings/OCaml/linker.ml @@ -45,7 +45,7 @@ let test_linker () = let m1 = make_module "one" and m2 = make_module "two" in - link_modules m1 m2; + link_modules m1 m2 Mode.DestroySource; dispose_module m1; let m1 = make_module "one" From 624e91b063cecc3671eeb40e4b0fa08d71b59284 Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Wed, 25 Feb 2015 18:26:53 +0000 Subject: [PATCH 3/3] Vendor import of clang RELEASE_360/final tag r230434 (effectively, 3.6.0 release): https://llvm.org/svn/llvm-project/cfe/tags/RELEASE_360/final@230434 --- docs/ReleaseNotes.rst | 125 +++++++++++++++++++++--------------------- lib/Basic/Version.cpp | 2 +- 2 files changed, 64 insertions(+), 63 deletions(-) diff --git a/docs/ReleaseNotes.rst b/docs/ReleaseNotes.rst index 5aeb2ad5a4f..b11960f7df3 100644 --- a/docs/ReleaseNotes.rst +++ b/docs/ReleaseNotes.rst @@ -52,63 +52,112 @@ Clang's diagnostics are constantly being improved to catch more issues, explain them more clearly, and provide more accurate source information about them. The improvements since the 3.5 release include: -- ... +- Smarter typo correction. Clang now tries a bit harder to give a usable + suggestion in more cases, and can now successfully recover in more + situations where the suggestion changes how an expression is parsed. + New Compiler Flags ------------------ -The option .... +The ``-fpic`` option now uses small pic on PowerPC. + The __EXCEPTIONS macro ---------------------- -``__EXCEPTIONS`` is now defined when landing pads are emitted, not when c++ exceptions are enabled. The two can be different in Objective-C files: If C++ exceptions are disabled but Objective-C exceptions are enabled, landing pads will be emitted. Clang 3.6 is switching the behavior of ``__EXCEPTIONS``. Clang 3.5 confusingly changed the behavior of ``has_feature(cxx_exceptions)``, which used to be set if landing pads were emitted, but is now set if C++ exceptions are enabled. So there are 3 cases: +``__EXCEPTIONS`` is now defined when landing pads are emitted, not when +C++ exceptions are enabled. The two can be different in Objective-C files: +If C++ exceptions are disabled but Objective-C exceptions are enabled, +landing pads will be emitted. Clang 3.6 is switching the behavior of +``__EXCEPTIONS``. Clang 3.5 confusingly changed the behavior of +``has_feature(cxx_exceptions)``, which used to be set if landing pads were +emitted, but is now set if C++ exceptions are enabled. So there are 3 cases: Clang before 3.5: - ``__EXCEPTIONS`` is set if C++ exceptions are enabled, ``cxx_exceptions`` enabled if C++ or ObjC exceptions are enabled + ``__EXCEPTIONS`` is set if C++ exceptions are enabled, ``cxx_exceptions`` + enabled if C++ or ObjC exceptions are enabled Clang 3.5: - ``__EXCEPTIONS`` is set if C++ exceptions are enabled, ``cxx_exceptions`` enabled if C++ exceptions are enabled + ``__EXCEPTIONS`` is set if C++ exceptions are enabled, ``cxx_exceptions`` + enabled if C++ exceptions are enabled Clang 3.6: - ``__EXCEPTIONS`` is set if C++ or ObjC exceptions are enabled, ``cxx_exceptions`` enabled if C++ exceptions are enabled + ``__EXCEPTIONS`` is set if C++ or ObjC exceptions are enabled, + ``cxx_exceptions`` enabled if C++ exceptions are enabled -To reliably test if C++ exceptions are enabled, use ``__EXCEPTIONS && __has_feature(cxx_exceptions)``, else things won't work in all versions of clang in Objective-C++ files. +To reliably test if C++ exceptions are enabled, use +``__EXCEPTIONS && __has_feature(cxx_exceptions)``, else things won't work in +all versions of Clang in Objective-C++ files. New Pragmas in Clang ----------------------- -Clang now supports the ... +Clang now supports the `#pragma unroll` and `#pragma nounroll` directives to +specify loop unrolling optimization hints. Placed just prior to the desired +loop, `#pragma unroll` directs the loop unroller to attempt to fully unroll the +loop. The pragma may also be specified with a positive integer parameter +indicating the desired unroll count: `#pragma unroll _value_`. The unroll count +parameter can be optionally enclosed in parentheses. The directive `#pragma +nounroll` indicates that the loop should not be unrolled. These unrolling hints +may also be expressed using the `#pragma clang loop` directive. See the Clang +`language extensions +`_ +for details. Windows Support --------------- -- Many, many bug fixes +- Many, many bug fixes. -- Basic support for DWARF debug information in COFF files +- Clang can now self-host using the ``msvc`` environment on x86 and x64 + Windows. This means that Microsoft C++ ABI is more or less feature-complete, + minus exception support. -- Support for Visual C++ '__super' keyword +- Added more MSVC compatibility hacks, such as allowing more lookup into + dependent bases of class templates when there is a known template pattern. + As a result, applications using Active Template Library (ATL) or Windows + Runtime Library (WRL) headers should compile correctly. + +- Added support for the Visual C++ ``__super`` keyword. + +- Added support for MSVC's ``__vectorcall`` calling convention, which is used + in the upcoming Visual Studio 2015 STL. + +- Added basic support for DWARF debug information in COFF files. C Language Changes in Clang --------------------------- -... +- The default language mode for C compilations with Clang has been changed from + C99 with GNU extensions to C11 with GNU extensions. C11 is largely + backwards-compatible with C99, but if you want to restore the former behavior + you can do so with the `-std=gnu99` flag. C11 Feature Support ^^^^^^^^^^^^^^^^^^^ -... +- Clang now provides an implementation of the standard C11 header ``. C++ Language Changes in Clang ----------------------------- +- An `upcoming change to C++ _` + changes the semantics of certain deductions of `auto` from a braced initializer + list. Following the intent of the C++ committee, this change will be applied to + our C++11 and C++14 modes as well as our experimental C++17 mode. Clang 3.6 + does not yet implement this change, but to provide a transition period, it + warns on constructs whose meaning will change. The fix in all cases is to + add an `=` prior to the left brace. + - Clang now supports putting identical constructors and destructors in the C5/D5 comdat, reducing code duplication. - Clang will put individual ``.init_array/.ctors`` sections in comdats, reducing code duplication and speeding up startup. + C++17 Feature Support ^^^^^^^^^^^^^^^^^^^^^ @@ -139,20 +188,10 @@ For more details on C++ feature support, see `the C++ status page `_. -Objective-C Language Changes in Clang -------------------------------------- - -... - -OpenCL C Language Changes in Clang ----------------------------------- - -... - OpenMP Language Changes in Clang -------------------------------- -Clang 3.6 contains codegen for many individual OpenMP pragmas, but combinations are not completed as yet. +Clang 3.6 contains codegen for many individual OpenMP pragmas, but combinations are not completed yet. We plan to continue codegen code drop aiming for completion in 3.7. Please see this link for up-to-date `status _`. LLVM's OpenMP runtime library, originally developed by Intel, has been modified to work on ARM, PowerPC, @@ -162,44 +201,6 @@ Support for ppc64le architecture is now available and automatically detected whe Using makefile the new "ppc64le" arch type is available. Contributors to this work include AMD, Argonne National Lab., IBM, Intel, Texas Instruments, University of Houston and many others. -Internal API Changes --------------------- - -These are major API changes that have happened since the 3.5 release of -Clang. If upgrading an external codebase that uses Clang as a library, -this section should help get you past the largest hurdles of upgrading. - -... - -libclang --------- - -... - -Static Analyzer ---------------- - -... - -Core Analysis Improvements -========================== - -- ... - -New Issues Found -================ - -- ... - -Python Binding Changes ----------------------- - -The following methods have been added: - -- ... - -Significant Known Problems -========================== Additional Information ====================== diff --git a/lib/Basic/Version.cpp b/lib/Basic/Version.cpp index 9e0b91a8489..b631b3e8a76 100644 --- a/lib/Basic/Version.cpp +++ b/lib/Basic/Version.cpp @@ -36,7 +36,7 @@ std::string getClangRepositoryPath() { // If the SVN_REPOSITORY is empty, try to use the SVN keyword. This helps us // pick up a tag in an SVN export, for example. - StringRef SVNRepository("$URL: https://llvm.org/svn/llvm-project/cfe/tags/RELEASE_360/rc1/lib/Basic/Version.cpp $"); + StringRef SVNRepository("$URL: https://llvm.org/svn/llvm-project/cfe/tags/RELEASE_360/final/lib/Basic/Version.cpp $"); if (URL.empty()) { URL = SVNRepository.slice(SVNRepository.find(':'), SVNRepository.find("/lib/Basic"));