[runtime] Refactor and unify tls access
[mono.git] / mono / mini / Makefile.am.in
index 1ef97c57a00d3b35dc44476dfdb09cb4d051b8db..eab2cd3db4918d0cde243abe0f55d69b0980897d 100755 (executable)
@@ -48,7 +48,6 @@ RUNTIME_EXECUTABLE = $(if $(BOEHM),$(top_builddir)/mono/mini/mono-boehm,$(top_bu
 MINI_RUNTIME = MONO_PATH=$(CLASS) $(RUNTIME_EXECUTABLE)
 RUNTIME_AOTCHECK = MONO_PATH="$(CLASS)$(PLATFORM_PATH_SEPARATOR)." $(RUNTIME_EXECUTABLE)
 
-CSC = $(mcs_topdir)/class/lib/build/mcs.exe
 MCS = CSC_SDK_PATH_DISABLED= $(MINI_RUNTIME) $(CSC) -unsafe -nowarn:0162 -nologo -noconfig -r:$(CLASS)/mscorlib.dll -r:$(CLASS)/System.dll -r:$(CLASS)/System.Core.dll
 ILASM = $(MINI_RUNTIME) $(CLASS)/ilasm.exe
 
@@ -326,9 +325,7 @@ ppc_sources = \
 
 arm_sources = \
        mini-arm.c              \
-       mini-arm-tls.S          \
        mini-arm.h              \
-       mini-arm-tls.h          \
        exceptions-arm.c        \
        tramp-arm.c     \
        mini-arm-gsharedvt.c    \
@@ -373,6 +370,7 @@ darwin_sources = \
 
 windows_sources = \
        mini-windows.c \
+       mini-windows.h \
        mini-windows-dllmain.c
 
 posix_sources = \
@@ -465,7 +463,8 @@ common_sources = \
        alias-analysis.c        \
        mini-cross-helpers.c \
        arch-stubs.c            \
-       llvm-runtime.h
+       llvm-runtime.h  \
+       type-checking.c
 
 test_sources =                         \
        basic-calls.cs          \
@@ -483,14 +482,15 @@ test_sources =                    \
        generics.cs             \
        generics-variant-types.il\
        basic-simd.cs \
+       basic-vectors.cs \
        aot-tests.cs \
        gc-test.cs \
        gshared.cs
 
 
-regtests_UNIVERSAL=basic.exe basic-float.exe basic-long.exe basic-calls.exe objects.exe arrays.exe basic-math.exe exceptions.exe iltests.exe devirtualization.exe generics.exe basic-simd.exe
+regtests_UNIVERSAL=basic.exe basic-float.exe basic-long.exe basic-calls.exe objects.exe arrays.exe basic-math.exe exceptions.exe iltests.exe devirtualization.exe generics.exe basic-simd.exe basic-vectors.exe
 
-if INSTALL_MOBILE_STATIC
+if INSTALL_AOT_ONLY
 regtests= \
        $(regtests_UNIVERSAL)
 
@@ -502,7 +502,7 @@ endif
 else
 regtests= \
        $(regtests_UNIVERSAL) \
-       $(regtests_MOBILE_STATIC_BLACKLIST)
+       $(regtests_AOT_ONLY_BLACKLIST)
 endif
 
 if X86
@@ -621,6 +621,9 @@ CSFLAGS = -unsafe -nowarn:0219,0169,0414,0649
 basic-simd.exe: basic-simd.cs TestDriver.dll
        $(MCS) -out:$@ $(CSFLAGS) $< -r:TestDriver.dll -r:$(CLASS)/Mono.Simd.dll
 
+basic-vectors.exe: basic-vectors.cs TestDriver.dll
+       $(MCS) -out:$@ $(CSFLAGS) $< -r:TestDriver.dll -r:$(CLASS)/System.Numerics.dll
+
 nacl.exe: nacl.cs TestDriver.dll
        $(MCS) -out:$@ $(CSFLAGS) $< -r:TestDriver.dll -r:$(CLASS)/Mono.Simd.dll
 
@@ -697,8 +700,16 @@ checktests: $(regtests)
        for i in $(regtests); do $(MINI_RUNTIME) $$i; done
 
 rcheck-nunit: mono $(regtests)
-       -($(MINI_RUNTIME) --regression $(regtests); echo $$? > regressionexitcode.out) | $(srcdir)/emitnunit.pl
-       exit $$(cat regressionexitcode.out)
+       $(MINI_RUNTIME) --regression $(regtests) > regressiontests.out 2>&1; cat regressiontests.out; \
+       if grep -q "100% pass" regressiontests.out; then successbool=True; failurescount=0; else successbool=False; failurescount=1; fi; \
+       echo "<?xml version='1.0' encoding='utf-8'?>\
+               <test-results failures='$$failurescount' total='1' not-run='0' name='regression-tests.dummy' date='$$(date +%F)' time='$$(date +%T)'>\
+                       <test-suite name='regression-tests.dummy' success='$$successbool' time='0'>\
+                               <results><test-case name='MonoTests.regressions.100percentsuccess' executed='True' success='$$successbool' time='0'>" > TestResult-regression.xml; \
+                                       if [ "$$successbool" = "False" ]; then echo "<failure><message><![CDATA[$$(cat regressiontests.out)]]></message><stack-trace></stack-trace></failure>" >> TestResult-regression.xml; fi; \
+                               echo "</test-case></results>\
+                       </test-suite>\
+               </test-results>" >> TestResult-regression.xml; exit $$failurescount
 
 rcheck: mono $(regtests)
        $(MINI_RUNTIME) --regression $(regtests)
@@ -734,9 +745,9 @@ gsharedvtcheck:
 fullaot_regtests = $(regtests) aot-tests.exe $(if $(GSHAREDVT),gshared.exe)
 
 # Skip aoting the tests that aren't compiled 
-# on the mobile_static profile because they're skipped
+# on the aot_only profile because they're skipped
 # on mobile profiles
-FULLAOT_LIBS_MOBILE_STATIC_BLACKLIST = \
+FULLAOT_LIBS_AOT_ONLY_BLACKLIST = \
        Mono.Posix.dll \
        System.Configuration.dll
 
@@ -749,14 +760,14 @@ FULLAOT_LIBS_UNIVERSAL = \
        Mono.Simd.dll \
        Mono.Security.dll
 
-if INSTALL_MOBILE_STATIC
+if INSTALL_AOT_ONLY
 FULLAOT_LIBS= \
        Mono.Dynamic.Interpreter.dll \
        $(FULLAOT_LIBS_UNIVERSAL)
 else
 FULLAOT_LIBS= \
        $(FULLAOT_LIBS_UNIVERSAL) \
-       $(FULLAOT_LIBS_MOBILE_STATIC_BLACKLIST)
+       $(FULLAOT_LIBS_AOT_ONLY_BLACKLIST)
 endif
 
 FULLAOT_TMP_DIR=$(top_builddir)/mono/mini/fullaot-tmp
@@ -834,7 +845,6 @@ CLEANFILES= $(BUILT_SOURCES) *.exe *.dll
 EXTRA_DIST = TestDriver.cs \
        TestHelpers.cs \
        genmdesc.pl                             \
-       emitnunit.pl                    \
        $(test_sources)                         \
        $(x86_sources) cpu-x86.md               \
        $(amd64_sources) cpu-amd64.md           \