From 9f0e81dfb5d8b5ff3d39e5826bb6ce0999a7bd9a Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Mon, 24 Feb 2014 15:47:43 -0800 Subject: add version number (1.11.1) --- emscripten-version.txt | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 emscripten-version.txt diff --git a/emscripten-version.txt b/emscripten-version.txt new file mode 100644 index 0000000000..6d767a8a3c --- /dev/null +++ b/emscripten-version.txt @@ -0,0 +1,2 @@ +1.11.1 + -- cgit v1.2.3-18-g5258 From ec1178a11d6dbeb371f45dd94a1d1c0849bbf1cb Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Mon, 24 Feb 2014 15:49:05 -0800 Subject: 1.12.1 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index 6d767a8a3c..ef145fe777 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.11.1 +1.12.1 -- cgit v1.2.3-18-g5258 From 5591fd344bb55525a2df1a85381f9ffd7140c541 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Tue, 25 Feb 2014 12:27:07 -0800 Subject: 1.12.2 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index ef145fe777..b4e6e5f6bf 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.12.1 +1.12.2 -- cgit v1.2.3-18-g5258 From 2fcf508830783213d3c1ffc164c4d1979c3755d4 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Wed, 26 Feb 2014 17:09:16 -0800 Subject: 1.12.3 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index b4e6e5f6bf..86df511188 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.12.2 +1.12.3 -- cgit v1.2.3-18-g5258 From a5bbe64d08bc217af5daa43761b587a0c9cc88fa Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Wed, 26 Feb 2014 18:41:24 -0800 Subject: Check in the version of this test which is actually updated for asmjs-unknown-emscripten. --- test/Driver/asmjs-unknown-emscripten.cpp | 22 ++++++---------------- 1 file changed, 6 insertions(+), 16 deletions(-) diff --git a/test/Driver/asmjs-unknown-emscripten.cpp b/test/Driver/asmjs-unknown-emscripten.cpp index fb94f0ecf9..bf37734af4 100644 --- a/test/Driver/asmjs-unknown-emscripten.cpp +++ b/test/Driver/asmjs-unknown-emscripten.cpp @@ -45,19 +45,14 @@ int align_vl = __alignof(va_list); void __LITTLE_ENDIAN__defined() {} #endif -// CHECK: __native_client__defined -#ifdef __native_client__ -void __native_client__defined() {} +// CHECK: __asmjs__defined +#ifdef __asmjs__ +void __asmjs__defined() {} #endif -// CHECK: __le32__defined -#ifdef __le32__ -void __le32__defined() {} -#endif - -// CHECK: __pnacl__defined -#ifdef __pnacl__ -void __pnacl__defined() {} +// CHECK: __EMSCRIPTEN__defined +#ifdef __EMSCRIPTEN__ +void __EMSCRIPTEN__defined() {} #endif // CHECK: unixdefined @@ -65,11 +60,6 @@ void __pnacl__defined() {} void unixdefined() {} #endif -// CHECK: __ELF__defined -#ifdef __ELF__ -void __ELF__defined() {} -#endif - // CHECK: _GNU_SOURCEdefined #ifdef _GNU_SOURCE void _GNU_SOURCEdefined() {} -- cgit v1.2.3-18-g5258 From f59469c5a434866f9a69439555a3684faa16e7fc Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Fri, 28 Feb 2014 13:07:59 -0800 Subject: Drop addAsmMemoryAroundSyncSynchronize() and asmMemoryIsFence(). For us, staying in sync with upstream on issues related to the memory model is more important. None of clang, gcc, nor icc appear to offer these features. If such features are desirable, they should ideally be implemented in upstream clang, in a target-independent way, since this issue would affect users of all platforms which support threads, not just PNaCl or Emscripten. --- lib/CodeGen/TargetInfo.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/lib/CodeGen/TargetInfo.cpp b/lib/CodeGen/TargetInfo.cpp index 5aa982e255..7d0d1768ed 100644 --- a/lib/CodeGen/TargetInfo.cpp +++ b/lib/CodeGen/TargetInfo.cpp @@ -428,10 +428,6 @@ class EmscriptenTargetCodeGenInfo : public TargetCodeGenInfo { public: explicit EmscriptenTargetCodeGenInfo(CodeGen::CodeGenTypes &CGT) : TargetCodeGenInfo(new EmscriptenABIInfo(CGT)) {} - - // TODO: Re-evaluate whether these hacks, borrowed from PNaCl, are necessary. - bool addAsmMemoryAroundSyncSynchronize() const { return true; } - bool asmMemoryIsFence() const { return true; } }; /// \brief Classify argument of given type \p Ty. -- cgit v1.2.3-18-g5258 From d2556a585b3695704cc385a1edb80851bebc3cb1 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Mon, 3 Mar 2014 13:39:44 -0800 Subject: release 1.13.0 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index 86df511188..bf2b5ccfef 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.12.3 +1.13.0 -- cgit v1.2.3-18-g5258 From f92a8f0ef8f7b349d653e97a8fb154719ef6117f Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Mon, 3 Mar 2014 14:08:08 -0800 Subject: Fix handling of byval arguments to set the alignment properly. Also, fix the way we override DefaultABIInfo methods, since classifyArgumentType and classifyReturnType are not actually virtual. Also, DefaultABIInfo does the right thing for floating-point types, so we don't need to special-case them. --- lib/CodeGen/TargetInfo.cpp | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/lib/CodeGen/TargetInfo.cpp b/lib/CodeGen/TargetInfo.cpp index 7d0d1768ed..196596d40a 100644 --- a/lib/CodeGen/TargetInfo.cpp +++ b/lib/CodeGen/TargetInfo.cpp @@ -421,7 +421,16 @@ class EmscriptenABIInfo : public DefaultABIInfo { explicit EmscriptenABIInfo(CodeGen::CodeGenTypes &CGT) : DefaultABIInfo(CGT) {} ABIArgInfo classifyReturnType(QualType RetTy) const; - ABIArgInfo classifyArgumentType(QualType RetTy) const; + ABIArgInfo classifyArgumentType(QualType Ty) const; + + // DefaultABIInfo's classifyReturnType and classifyArgumentType are + // non-virtual, but computeInfo is virtual, so we overload that. + virtual void computeInfo(CGFunctionInfo &FI) const { + FI.getReturnInfo() = classifyReturnType(FI.getReturnType()); + for (CGFunctionInfo::arg_iterator it = FI.arg_begin(), ie = FI.arg_end(); + it != ie; ++it) + it->info = classifyArgumentType(it->type); + } }; class EmscriptenTargetCodeGenInfo : public TargetCodeGenInfo { @@ -433,15 +442,12 @@ class EmscriptenTargetCodeGenInfo : public TargetCodeGenInfo { /// \brief Classify argument of given type \p Ty. ABIArgInfo EmscriptenABIInfo::classifyArgumentType(QualType Ty) const { if (isAggregateTypeForABI(Ty)) { + unsigned TypeAlign = getContext().getTypeAlignInChars(Ty).getQuantity(); if (CGCXXABI::RecordArgABI RAA = getRecordArgABI(Ty, CGT)) - return ABIArgInfo::getIndirect(0, RAA == CGCXXABI::RAA_DirectInMemory); - return ABIArgInfo::getIndirect(0); + return ABIArgInfo::getIndirect(TypeAlign, RAA == CGCXXABI::RAA_DirectInMemory); + return ABIArgInfo::getIndirect(TypeAlign); } - // We can handle floating-point values directly. - if (Ty->isFloatingType()) - return ABIArgInfo::getDirect(); - // Otherwise just do the default thing. return DefaultABIInfo::classifyArgumentType(Ty); } @@ -454,10 +460,6 @@ ABIArgInfo EmscriptenABIInfo::classifyReturnType(QualType RetTy) const { return ABIArgInfo::getDirect(CGT.ConvertType(QualType(SeltTy, 0))); } - // We can handle floating-point values directly. - if (RetTy->isFloatingType()) - return ABIArgInfo::getDirect(); - // Otherwise just do the default thing. return DefaultABIInfo::classifyReturnType(RetTy); } -- cgit v1.2.3-18-g5258 From d159899bf2ebd04f7b6620206223d4025cd34c5a Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Mon, 3 Mar 2014 14:09:52 -0800 Subject: Set the natural stack alignment for asm.js to 16 bytes. --- lib/Basic/Targets.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/Basic/Targets.cpp b/lib/Basic/Targets.cpp index 43a21f2734..45d313b2ed 100644 --- a/lib/Basic/Targets.cpp +++ b/lib/Basic/Targets.cpp @@ -5102,8 +5102,11 @@ public: // the direction suggested here: // https://bugzilla.mozilla.org/show_bug.cgi?id=904913#c21 // We can still set the preferred alignment to 16 bytes though. + // + // Set the natural stack alignment to 16 bytes to accomodate 128-bit + // aligned vectors. DescriptionString = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-" - "f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32"; + "f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"; } void getDefaultFeatures(llvm::StringMap &Features) const { -- cgit v1.2.3-18-g5258 From dce6d586ba26c2359504898cebf668991547ef85 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Mon, 10 Mar 2014 12:09:52 -0700 Subject: 1.13.1 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index bf2b5ccfef..87684ab837 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.13.0 +1.13.1 -- cgit v1.2.3-18-g5258 From d894121b609b86d174c50a77315532d95145f7fd Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Fri, 14 Mar 2014 15:20:06 -0700 Subject: 1.13.2 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index 87684ab837..2e46fa6fa3 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.13.1 +1.13.2 -- cgit v1.2.3-18-g5258 From 44793a27bcff2ad2d80ec3eaf9d521a9dd193c80 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Mon, 24 Mar 2014 15:15:09 -0700 Subject: 1.14.0 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index 2e46fa6fa3..29b950e780 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.13.2 +1.14.0 -- cgit v1.2.3-18-g5258 From 4f4b57609417ddbc90417b8eeeefb35ba7dc9387 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Mon, 7 Apr 2014 18:10:00 -0700 Subject: 1.14.1 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index 29b950e780..3166fbaa77 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.14.0 +1.14.1 -- cgit v1.2.3-18-g5258 From f1e7a40a73073cf492a7411acc049af0c729fe8a Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Wed, 9 Apr 2014 17:19:03 -0700 Subject: set the emscripten backend's atomic widths to 32 --- lib/Basic/Targets.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/Basic/Targets.cpp b/lib/Basic/Targets.cpp index 45d313b2ed..b56b42c798 100644 --- a/lib/Basic/Targets.cpp +++ b/lib/Basic/Targets.cpp @@ -269,6 +269,7 @@ public: // handled outside of clang. TODO: Handling this within clang may be // beneficial. this->UserLabelPrefix = ""; + this->MaxAtomicPromoteWidth = this->MaxAtomicInlineWidth = 32; } }; -- cgit v1.2.3-18-g5258 From 88198a1fe0d27db3ba0e1773c5f11ef074ba782d Mon Sep 17 00:00:00 2001 From: Jukka Jylanki Date: Thu, 10 Apr 2014 11:46:42 +0300 Subject: Allow setting CLANG_INCLUDE_TESTS=OFF to avoid having to build long-running tests with cmake. This change is already in upstream LLVM 3.4 repository. --- CMakeLists.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 5d05a4cdb5..bcd5c52578 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -290,10 +290,10 @@ option(CLANG_INCLUDE_TESTS "Generate build targets for the Clang unit tests." ${LLVM_INCLUDE_TESTS}) -# TODO: docs. -add_subdirectory(test) - if( CLANG_INCLUDE_TESTS ) + # TODO: docs. + add_subdirectory(test) # XXX Emscripten: Backport fix from upstream LLVM 3.4 to actually skip tests if CLANG_INCLUDE_TESTS = OFF + add_subdirectory(unittests) endif() -- cgit v1.2.3-18-g5258 From 541e58e9579af77a9c7bc6e3d39708caf0ba67d6 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Thu, 10 Apr 2014 15:55:05 -0700 Subject: 1.15.0 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index 3166fbaa77..226e95b7c3 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.14.1 +1.15.0 -- cgit v1.2.3-18-g5258 From 18854cc2fd77a9b3ae02f5f2324edcead681996c Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Mon, 14 Apr 2014 15:37:15 -0700 Subject: 1.15.1 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index 226e95b7c3..db39b14cd0 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.15.0 +1.15.1 -- cgit v1.2.3-18-g5258 From 926efa5d923dfd9555270a2bbb156bc30ce35fc9 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Tue, 15 Apr 2014 17:46:10 -0700 Subject: 1.16.0 --- emscripten-version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emscripten-version.txt b/emscripten-version.txt index db39b14cd0..f488f67e2a 100644 --- a/emscripten-version.txt +++ b/emscripten-version.txt @@ -1,2 +1,2 @@ -1.15.1 +1.16.0 -- cgit v1.2.3-18-g5258