if(CLR_CMAKE_PLATFORM_DARWIN)
add_definitions(-DFEATURE_WRITEBARRIER_COPY)
endif(CLR_CMAKE_PLATFORM_DARWIN)
+
+if(TIZEN_AGGRESSIVE_INLINING_GENERIC)
+ add_definitions(-DTIZEN_AGGRESSIVE_INLINING_GENERIC)
+endif(TIZEN_AGGRESSIVE_INLINING_GENERIC)
# Build native only.
export NUGET_PACKAGES=%{_builddir}/%{name}-%{version}/.packages/
export LD_LIBRARY_PATH=%{_builddir}/%{name}-%{version}/libicu-57.1/
-./build.sh -portablebuild=false -%{_barch} -%{_buildtype} -numproc %{_numproc} -skipmscorlib -skipgenerateversion -skipnuget -msbuildonunsupportedplatform cmakeargs "-DFEATURE_PREJIT=true -DFEATURE_ENABLE_NO_ADDRESS_SPACE_RANDOMIZATION=true -DCLR_ADDITIONAL_LINKER_FLAGS=-Wl,-z,relro" %{_ngen_relocs_opts} %{_pgo_flags}
+./build.sh -portablebuild=false -%{_barch} -%{_buildtype} -numproc %{_numproc} -skipmscorlib -skipgenerateversion -skipnuget -msbuildonunsupportedplatform cmakeargs "-DFEATURE_PREJIT=true -DFEATURE_ENABLE_NO_ADDRESS_SPACE_RANDOMIZATION=true -DTIZEN_AGGRESSIVE_INLINING_GENERIC=true -DCLR_ADDITIONAL_LINKER_FLAGS=-Wl,-z,relro" %{_ngen_relocs_opts} %{_pgo_flags}
%endif
%else
%if 0%{skipnative}
# Build native and mscorlib.
export NUGET_PACKAGES=%{_builddir}/%{name}-%{version}/.packages/
export LD_LIBRARY_PATH=%{_builddir}/%{name}-%{version}/libicu-57.1/
-./build.sh -portablebuild=false -%{_barch} -%{_buildtype} -numproc %{_numproc} -skipgenerateversion -skiprestore -skiprestoreoptdata -skipnuget -skipcrossgen -msbuildonunsupportedplatform cmakeargs "-DFEATURE_IBCLOGGER=true -DFEATURE_PREJIT=true -DFEATURE_ENABLE_NO_ADDRESS_SPACE_RANDOMIZATION=true -DCLR_ADDITIONAL_LINKER_FLAGS=-Wl,-z,relro" %{_ngen_relocs_opts} %{_pgo_flags}
+./build.sh -portablebuild=false -%{_barch} -%{_buildtype} -numproc %{_numproc} -skipgenerateversion -skiprestore -skiprestoreoptdata -skipnuget -skipcrossgen -msbuildonunsupportedplatform cmakeargs "-DFEATURE_IBCLOGGER=true -DFEATURE_PREJIT=true -DFEATURE_ENABLE_NO_ADDRESS_SPACE_RANDOMIZATION=true -DTIZEN_AGGRESSIVE_INLINING_GENERIC=true -DCLR_ADDITIONAL_LINKER_FLAGS=-Wl,-z,relro" %{_ngen_relocs_opts} %{_pgo_flags}
%endif
%endif
}
#endif
+#if defined(FEATURE_PREJIT) && defined(CROSSGEN_COMPILE)
+#ifdef TIZEN_AGGRESSIVE_INLINING_GENERIC
+ if (!IsReadyToRunCompilation() && pMD->IsIL() && (result & CORINFO_FLG_FORCEINLINE) == 0 &&
+ !pMD->IsTypicalMethodDefinition() && !pMD->IsGenericMethodDefinition() &&
+ Module::GetPreferredZapModuleForMethodDesc(pMD) != pMD->GetLoaderModule())
+ {
+ result |= CORINFO_FLG_FORCEINLINE;
+ }
+#endif
+#endif
+
return result;
}