Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJay Krell <jay.krell@cornell.edu>2018-09-24 06:18:23 +0300
committerGitHub <noreply@github.com>2018-09-24 06:18:23 +0300
commit06d6c4c3b3b5f71adfdba791e6bbcdc7f00e6997 (patch)
treeda2a29d539348e6eb2d813a0b83e7cb9acd02082 /sdks/builds/runtime.mk
parent3f63bad14e26e5252b7aa25182e91ed1cd4433cb (diff)
[ci][cxx][sdks] C++ support for SDKs. (#10701)
* [ci][cxx][sdks] C++ support for SDKs. * Remove cplusplus support, only cxx. * [cxx][sdks] Provide isinf and isnan. https://jenkins.mono-project.com/job/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/1/parsed_console/log.html /Users/builder/jenkins/workspace/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/mono/mini/jit-icalls.c:994:14: error: 'isinf' was not declared in this scope if (isinf (v) || isnan (v)) /Users/builder/jenkins/workspace/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/mono/mini/jit-icalls.c:994:27: error: 'isnan' was not declared in this scope if (isinf (v) || isnan (v)) * Change target card mask from gpointer to mgreg_t. Consider in future target_gsize instead, though if registers are larger than pointers (x32, arm64_32), ok. Change inst_imm from mgreg_t to target_mgreg_t. https://jenkins.mono-project.com/job/test-mono-pull-request-wasm-cxx/1/parsed_console/log.html /mnt/jenkins/workspace/test-mono-pull-request-wasm-cxx/mono/mini/mini-runtime.c:3657:24: error: cast from 'gpointer {aka void*}' to 'mgreg_t {aka int}' loses precision [-fpermissive] g_assert ((((mgreg_t)arg) & 1) == 0); ^ ^~~~ /mnt/jenkins/workspace/test-mono-pull-request-wasm-cxx/mono/mini/mini-runtime.c:3658:30: error: cast from 'gpointer {aka void*}' to 'mgreg_t {aka int}' loses precision [-fpermissive] arg = (gpointer)(((mgreg_t)arg) | 1); In file included from /mnt/jenkins/workspace/test-mono-pull-request-wasm-cxx/mono/mini/method-to-ir.c:75:0: /mnt/jenkins/workspace/test-mono-pull-request-wasm-cxx/mono/mini/method-to-ir.c: In function 'void mini_emit_write_barrier(MonoCompile*, MonoInst*, MonoInst*)': /mnt/jenkins/workspace/test-mono-pull-request-wasm-cxx/mono/mini/ir-emit.h:703:39: error: cast from 'gpointer {aka void*}' to 'mgreg_t {aka int}' loses precision [-fpermissive] inst->inst_imm = (mgreg_t)(imm); \ ^ /mnt/jenkins/workspace/test-mono-pull-request-wasm-cxx/mono/mini/method-to-ir.c:2989:4: note: in expansion of macro 'MONO_EMIT_NEW_BIALU_IMM' MONO_EMIT_NEW_BIALU_IMM (cfg, OP_PAND_IMM, offset_reg, offset_reg, card_table_mask); ^~~~~~~~~~~~~~~~~~~~~~~ * [cxx][sdks] Move include out of extern "C" where it never belongs. https://jenkins.mono-project.com/job/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/4/parsed_console/log.html template<typename _Tp, typename _Up, typename _Vp, ^ /Users/builder/android-toolchain/mxe-b9cbb53/lib/gcc/x86_64-w64-mingw32.static/5.4.0/include/c++/ext/type_traits.h:205:3: error: template with C linkage template<typename _Tp, typename _Up, typename _Vp, typename _Wp, ^ In file included from /Users/builder/jenkins/workspace/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/mono/utils/mono-compiler.h:31:0, from /Users/builder/jenkins/workspace/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/mono/utils/dlmalloc.h:33, from /Users/builder/jenkins/workspace/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/mono/utils/dlmalloc.c:27: /Users/builder/android-toolchain/mxe-b9cbb53/lib/gcc/x86_64-w64-mingw32.static/5.4.0/include/c++/cmath: In function 'constexpr float std::abs(float)': /Users/builder/android-toolchain/mxe-b9cbb53/lib/gcc/x86_64-w64-mingw32.static/5.4.0/include/c++/cmath:87:16: error: conflicting declaration of C function 'constexpr float std::abs(float)' abs(float __x) * Expand cmath to wasm. https://jenkins.mono-project.com/job/test-mono-pull-request-wasm-cxx/5/parsed_console/log.html /mnt/jenkins/workspace/test-mono-pull-request-wasm-cxx/mono/mini/mini-llvm.c:4189:6: error: 'isnan' was not declared in this scope if (isnan (val)) ^~~~~ * Provide cmath std::isnan for WebAssembly C++. * Provide cmath std::isfinite for Android C++. * Add cmath std::isunordered for Android /Users/builder/jenkins/workspace/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/mono/mini/interp/interp.c:3282:14: error: use of undeclared identifier 'isunordered'; did you mean 'std::isunordered'? CONDBR_S(!isunordered (sp [0].data.f, sp [1].data.f) && sp[0].data.f <= sp[1].data.f) ^~~~~~~~~~~ std::isunordered * Add cmath std::isinf for Android. https://jenkins.mono-project.com/job/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/10/parsed_console/log.html /Users/builder/jenkins/workspace/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/mono/mini/interp/interp.c:3751:8: error: use of undeclared identifier 'isinf' if (isinf (sp [-1].data.f)) * "using std::isinf" sometimes breaks on Android, sometimes fixes Android, because Android sometimes has global isinf. /Users/builder/jenkins/workspace/test-mono-pull-request-amd64-osx-products-sdks-android-cxx/mono/mini/interp/interp.c:92:12: error: target of using declaration conflicts with declaration already in scope using std::isinf; ^ /Users/builder/android-toolchain/toolchains/arm64-v8a-clang/bin/../lib/gcc/aarch64-linux-android/4.9.x/../../../../include/c++/4.9.x/cmath:604:3: note: target of using declaration isinf(double __x) ^ /Users/builder/android-toolchain/toolchains/arm64-v8a-clang/bin/../sysroot/usr/include/math.h:234:6: note: conflicting declaration int (isinf)(double) __pure2; There are still some errors in new lanes (WebAssembly works, Android does not, iOS not sure), to be addressed shortly, possibly by redoing some of the cmath stuff.
Diffstat (limited to 'sdks/builds/runtime.mk')
-rw-r--r--sdks/builds/runtime.mk2
1 files changed, 2 insertions, 0 deletions
diff --git a/sdks/builds/runtime.mk b/sdks/builds/runtime.mk
index fa63d9cf002..73b67a94d10 100644
--- a/sdks/builds/runtime.mk
+++ b/sdks/builds/runtime.mk
@@ -64,6 +64,7 @@ _runtime_$(1)_CONFIGURE_ENVIRONMENT = \
$$($(1)_CONFIGURE_ENVIRONMENT)
_runtime_$(1)_CONFIGURE_FLAGS= \
+ $(if $(ENABLE_CXX),--enable-cxx) \
$$(if $(2),--host=$(2)) \
--cache-file=$$(TOP)/sdks/builds/$(1)-$$(CONFIGURATION).config.cache \
--prefix=$$(TOP)/sdks/out/$(1)-$$(CONFIGURATION) \
@@ -143,6 +144,7 @@ $(TOP)/tools/offsets-tool/MonoAotOffsetsDumper.exe: $(wildcard $(TOP)/tools/offs
define CrossRuntimeTemplate
_cross-runtime_$(1)_CONFIGURE_FLAGS= \
+ $(if $(ENABLE_CXX),--enable-cxx) \
--target=$(3) \
--with-cross-offsets=$(3).h \
--with-llvm=$$(TOP)/sdks/out/$(5)