From: Yi Zhang (CLR) Date: Tue, 1 Aug 2017 17:15:26 +0000 (-0700) Subject: Use Live built ILAsm for building tests (#13148) X-Git-Tag: accepted/tizen/base/20180629.140029~315^2~4^2~20 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=65d13c3c043d893f507862a828c79766b2de3b9f;p=platform%2Fupstream%2Fcoreclr.git Use Live built ILAsm for building tests (#13148) * Update dependencies and use live/packaged ilasm * Fix ilasm excessive stack usage when deleting lots of generic parameters --- diff --git a/dependencies.props b/dependencies.props index 1549831..d95d692 100644 --- a/dependencies.props +++ b/dependencies.props @@ -13,19 +13,19 @@ - 8c5e29c80651aff43c981375d9ae935d96f9d637 - 8c5e29c80651aff43c981375d9ae935d96f9d637 + a97bcb7231471554cf5cf9b685e60ccbaf505d1f + a97bcb7231471554cf5cf9b685e60ccbaf505d1f - 4.5.0-preview2-25518-02 + 4.5.0-preview2-25526-52 2.1.0-preview1-25324-02 - 2.1.0-preview2-25518-01 + 2.1.0-dev-di-25528-01 2.2.0-beta2-build3300 1.0.2-prerelease-00177 1.0.0-beta-build0007 @@ -36,7 +36,7 @@ build-info/dotnet/ - master + dev/defaultintf $(MSBuildThisFileFullPath) diff --git a/src/ilasm/typar.hpp b/src/ilasm/typar.hpp index 143a4a2..146128e 100644 --- a/src/ilasm/typar.hpp +++ b/src/ilasm/typar.hpp @@ -51,17 +51,27 @@ private: class TyParList { public: - TyParList(DWORD a, BinStr* b, LPCUTF8 n, TyParList* nx = NULL) + TyParList(DWORD a, BinStr* b, LPCUTF8 n, TyParList* nx = NULL) { bound = (b == NULL) ? new BinStr() : b; bound->appendInt32(0); // zero terminator - attrs = a; name = n; next = nx; - }; - ~TyParList() - { - if(bound) delete bound; - if (next) delete next; - }; + attrs = a; name = n; next = nx; + }; + ~TyParList() + { + if( bound) delete bound; + + // To avoid excessive stack usage (especially in debug builds), we break the next chain + // and delete as we traverse the link list + TyParList *pCur = next; + while (pCur != NULL) + { + TyParList *pTmp = pCur->next; + pCur->next = NULL; + delete pCur; + pCur = pTmp; + } + }; int Count() { TyParList* tp = this; @@ -154,7 +164,7 @@ public: TyParList* Next() { return next; }; BinStr* Bound() { return bound; }; private: - BinStr* bound; + BinStr* bound; LPCUTF8 name; TyParList* next; DWORD attrs; diff --git a/tests/src/IL.targets b/tests/src/IL.targets index 88bb44e..11a82c5 100644 --- a/tests/src/IL.targets +++ b/tests/src/IL.targets @@ -13,8 +13,7 @@ <_ShellKeyMarker Condition="'$(RunningOnUnix)' == 'true'">- <_ShellKeyMarker Condition="'$(RunningOnUnix)' != 'true'">/ - <_ilasm>ilasm - <_ilasm Condition="'$(RunningOnUnix)' == 'true'">$(CoreCLRBinDir)ilasm + <_ilasm>$(CoreCLRBinDir)ilasm <_OutputTypeArgument Condition="'$(OutputType)' == 'Library'">$(_ShellKeyMarker)DLL <_OutputTypeArgument Condition="'$(OutputType)' == 'Exe'">$(_ShellKeyMarker)EXE <_IlasmSwitches>-QUIET -NOLOGO @@ -24,12 +23,9 @@ <_IlasmSwitches Condition="'$(DebugType)' == 'Impl'">$(_IlasmSwitches) -DEBUG=IMPL <_IlasmSwitches Condition="'$(DebugType)' == 'PdbOnly'">$(_IlasmSwitches) -DEBUG=OPT <_IlasmSwitches Condition="'$(Optimize)' == 'True'">$(_IlasmSwitches) -OPTIMIZE - ilasm - - $(__BinDir)\$(ILAsmExe) - +