浏览代码

Remove ENABLE_PROJECTION

rhuanjl 5 年之前
父节点
当前提交
befa2b30b8
共有 34 个文件被更改,包括 20 次插入880 次删除
  1. 0 2
      bin/ch/Helpers.cpp
  2. 0 2
      lib/Common/CommonDefines.h
  3. 1 37
      lib/Common/ConfigFlagsList.h
  4. 0 11
      lib/Common/Core/ConfigFlagsTable.h
  5. 0 16
      lib/Common/Core/ConfigParser.cpp
  6. 0 1
      lib/Common/Core/PerfCounter.h
  7. 1 44
      lib/Common/Memory/Recycler.cpp
  8. 0 22
      lib/Common/Memory/Recycler.h
  9. 1 3
      lib/Common/Memory/RecyclerSweep.cpp
  10. 0 2
      lib/Common/Memory/RecyclerWatsonTelemetry.h
  11. 0 14
      lib/Jsrt/Core/JsrtContextCore.h
  12. 0 3
      lib/Parser/ParserCommon.h
  13. 0 93
      lib/Runtime/Base/DelayLoadLibrary.cpp
  14. 0 124
      lib/Runtime/Base/DelayLoadLibrary.h
  15. 1 1
      lib/Runtime/Base/JnDirectFields.h
  16. 1 1
      lib/Runtime/Base/ScriptContext.cpp
  17. 0 64
      lib/Runtime/Base/ScriptContext.h
  18. 2 5
      lib/Runtime/Base/ThreadConfigFlagsList.h
  19. 0 122
      lib/Runtime/Base/ThreadContext.cpp
  20. 0 58
      lib/Runtime/Base/ThreadContext.h
  21. 0 21
      lib/Runtime/Library/DataView.cpp
  22. 2 2
      lib/Runtime/Library/EngineInterfaceObject.cpp
  23. 2 2
      lib/Runtime/Library/EngineInterfaceObject.h
  24. 0 17
      lib/Runtime/Library/GlobalObject.cpp
  25. 0 3
      lib/Runtime/Library/JavascriptBuiltInFunctionList.h
  26. 1 27
      lib/Runtime/Library/JavascriptError.cpp
  27. 0 6
      lib/Runtime/Library/JavascriptError.h
  28. 3 17
      lib/Runtime/Library/JavascriptLibrary.cpp
  29. 0 17
      lib/Runtime/Library/JavascriptLibrary.h
  30. 2 2
      lib/Runtime/Library/JavascriptLibraryBase.h
  31. 2 29
      lib/Runtime/Library/TypedArray.cpp
  32. 1 84
      test/Closures/copy-prop-stack-slot-test-framework.js
  33. 0 14
      test/es6/weakmap_functionality.js
  34. 0 14
      test/es6/weakset_functionality.js

+ 0 - 2
bin/ch/Helpers.cpp

@@ -388,8 +388,6 @@ LPCWSTR Helpers::JsErrorCodeToString(JsErrorCode jsErrorCode)
     case JsErrorAlreadyDebuggingContext:       return _u("JsErrorAlreadyDebuggingContext");
     case JsErrorAlreadyProfilingContext:       return _u("JsErrorAlreadyProfilingContext");
     case JsErrorIdleNotEnabled:                return _u("JsErrorIdleNotEnabled");
-    case JsCannotSetProjectionEnqueueCallback: return _u("JsCannotSetProjectionEnqueueCallback");
-    case JsErrorCannotStartProjection:         return _u("JsErrorCannotStartProjection");
     case JsErrorInObjectBeforeCollectCallback: return _u("JsErrorInObjectBeforeCollectCallback");
     case JsErrorObjectNotInspectable:          return _u("JsErrorObjectNotInspectable");
     case JsErrorPropertyNotSymbol:             return _u("JsErrorPropertyNotSymbol");

+ 0 - 2
lib/Common/CommonDefines.h

@@ -329,7 +329,6 @@
 #endif
 
 #ifdef NTBUILD
-#define ENABLE_PROJECTION
 #define ENABLE_FOUNDATION_OBJECT
 #define ENABLE_EXPERIMENTAL_FLAGS
 #define ENABLE_WININET_PROFILE_DATA_CACHE
@@ -591,7 +590,6 @@
 #define CHECK_MEMORY_LEAK
 #define LEAK_REPORT
 
-#define PROJECTION_METADATA_TRACE
 #define ERROR_TRACE
 #define DEBUGGER_TRACE
 

+ 1 - 37
lib/Common/ConfigFlagsList.h

@@ -375,7 +375,6 @@ PHASE(All)
         PHASE(CFG)
         PHASE(ExceptionStackTrace)
         PHASE(ExtendedExceptionInfoStackTrace)
-        PHASE(ProjectionMetadata)
         PHASE(TypeHandlerTransition)
         PHASE(Debugger)
             PHASE(ENC)
@@ -784,8 +783,6 @@ PHASE(All)
 #define DEFAULT_CONFIG_ForceJITCFGCheck (false)
 #define DEFAULT_CONFIG_UseJITTrampoline (true)
 
-#define DEFAULT_CONFIG_FailFastIfDisconnectedDelegate    (false)
-
 #define DEFAULT_CONFIG_IsolatePrototypes    (true)
 #define DEFAULT_CONFIG_ChangeTypeOnProto    (true)
 #define DEFAULT_CONFIG_FixPropsOnPathTypes    (true)
@@ -810,12 +807,6 @@ PHASE(All)
 #define DEFAULT_CONFIG_InjectPartiallyInitializedInterpreterFrameErrorType (0)
 
 #define DEFAULT_CONFIG_DeferLoadingAvailableSource  (false)
-#ifdef ENABLE_PROJECTION
-#define DEFAULT_CONFIG_NoWinRTFastSig       (false)
-#define DEFAULT_CONFIG_TargetWinRTVersion   (1)
-#define DEFAULT_CONFIG_WinRTDelegateInterfaces      (false)
-#define DEFAULT_CONFIG_WinRTAdaptiveApps            (true)
-#endif
 
 #define DEFAULT_CONFIG_RecyclerForceMarkInterior (false)
 
@@ -1186,14 +1177,7 @@ FLAGPR           (Boolean, ES6, ESObjectGetOwnPropertyDescriptors, "Enable Objec
 
 FLAGPR_REGOVR_EXP(Boolean, ES6, ESSharedArrayBuffer    , "Enable SharedArrayBuffer"                                 , DEFAULT_CONFIG_ESSharedArrayBuffer)
 
-// /ES6 (BLUE+1) features/flags
-
-
-
-#ifdef ENABLE_PROJECTION
-FLAGNR(Boolean, WinRTDelegateInterfaces , "Treat WinRT Delegates as Interfaces when determining their resolvability.", DEFAULT_CONFIG_WinRTDelegateInterfaces)
-FLAGR(Boolean, WinRTAdaptiveApps        , "Enable the adaptive apps feature, allowing for variable projection."      , DEFAULT_CONFIG_WinRTAdaptiveApps)
-#endif
+// Newer language feature flags
 
 // ES BigInt flag
 FLAGR(Boolean, ESBigInt, "Enable ESBigInt flag", DEFAULT_CONFIG_ESBigInt)
@@ -1416,9 +1400,6 @@ FLAGR (Boolean, NoNative              , "Disable native codegen", false)
 FLAGNR(Number,  NopFrequency          , "Frequency of NOPs inserted by NOP insertion phase.  A NOP is guaranteed to be inserted within a range of (1<<n) instrs (default=8)", DEFAULT_CONFIG_NopFrequency)
 FLAGNR(Boolean, NoStrictMode          , "Disable strict mode checks on all functions", false)
 FLAGNR(Boolean, NormalizeStats        , "When dumping stats, do some normalization (used with -instrument:linearscan)", false)
-#ifdef ENABLE_PROJECTION
-FLAGNR(Boolean, NoWinRTFastSig        , "Disable fast call for common WinRT function signatures", false)
-#endif
 FLAGNR(Phases,  Off                   , "Turn off specific phases or feature.(Might not work for all phases)", )
 FLAGNR(Phases,  OffProfiledByteCode   , "Turn off specific byte code for phases or feature.(Might not work for all phases)", )
 FLAGNR(Phases,  On                    , "Turn on specific phases or feature.(Might not work for all phases)", )
@@ -1553,11 +1534,6 @@ FLAGNR(Boolean, TraceWin8Allocations  , "Trace the win8 memory allocations", fal
 FLAGNR(Boolean, TraceWin8DeallocationsImmediate  , "Trace the win8 memory deallocations immediately", false)
 FLAGNR(Boolean, PrintWin8StatsDetailed  , "Print the detailed memory trace report", false)
 FLAGNR(Boolean, TraceProtectPages     , "Trace calls to protecting pages of custom heap allocated pages", false)
-//TraceProjection flag with optional levels:
-//    Level 1 = error
-//    Level 2 = warning
-//    Level 3 = informational
-FLAGNR(Number, TraceProjection       , "Trace projection related activities, [Levels 1-3, with 3 corresponding to most detailed]", 3)
 #endif
 FLAGNR(Boolean, TraceAsyncDebugCalls  , "Trace calls to async debugging API (default: false)", DEFAULT_CONFIG_TraceAsyncDebugCalls)
 #ifdef TRACK_DISPATCH
@@ -1567,13 +1543,7 @@ FLAGNR(Boolean, Verbose               , "Dump details", DEFAULT_CONFIG_Verbose)
 FLAGNR(Boolean, UseFullName           , "Enable fully qualified name", DEFAULT_CONFIG_UseFullName)
 FLAGNR(Boolean, Utf8                  , "Use UTF8 for file output", false)
 FLAGR (Number,  Version               , "Version in which to run the jscript engine. [one of 1,2,3,4,5,6]. Default is latest for jc/jshost, 1 for IE", 6 )
-#ifdef ENABLE_PROJECTION
-FLAGR (Number,  HostType              , "Host type in which to run the jscript engine. [one of 1,2]. Default is 1 = Browser.", 1)
-#endif
 FLAGR(Boolean, WERExceptionSupport    , "WER feature for extended exception support. Enabled when WinRT is enabled", false)
-#ifdef ENABLE_PROJECTION
-FLAGR (Boolean, WinRTConstructorAllowed, "Whether WinRT constructors is allowed in WebView host type. Constructor is always allowed in other host type ", false)
-#endif
 FLAGNR(Boolean, ExtendedErrorStackForTestHost, "Enable passing extended error stack string to test host.", DEFAULT_CONFIG_ExtendedErrorStackForTestHost)
 FLAGNR(Boolean, errorStackTrace       , "error.StackTrace feature. Remove when feature complete", DEFAULT_CONFIG_errorStackTrace)
 FLAGNR(Boolean, DoHeapEnumOnEngineShutdown, "Perform a heap enumeration whenever shut a script engine down", false)
@@ -1603,12 +1573,6 @@ FLAGNR(Boolean, EnableEvalMapCleanup, "Enable cleaning up the eval map", true)
 #ifdef PROFILE_MEM
 FLAGNR(Boolean, TraceObjectAllocation, "Enable cleaning up the eval map", false)
 #endif
-#ifdef ENABLE_PROJECTION
-FLAGNR(Boolean, EnableThirdPartyGCPressure, "Enable use of GCPressure attribute value on 3rd party WinRT objects (not in Windows namespace) (default: false)", false)
-FLAGNR(Number, TargetWinRTVersion, "Specifies WinRT version number to target. [one of 0,1,2,3,4]. Default is 1 = NTDDI_WIN8", DEFAULT_CONFIG_TargetWinRTVersion)
-FLAGNR(Boolean, EnableVersioningAllAssemblies, "Enable versioning behavior for all assemblies, regardless of host flag (default: false)", false)
-FLAGR(Boolean, FailFastIfDisconnectedDelegate, "When set fail fast if disconnected delegate is invoked", DEFAULT_CONFIG_FailFastIfDisconnectedDelegate)
-#endif
 FLAGNR(Number, Sse, "Virtually disables SSE-based optimizations above the specified SSE level in the Chakra JIT (does not affect CRT SSE usage)", DEFAULT_CONFIG_Sse)
 FLAGNR(Number,  DeletedPropertyReuseThreshold, "Start reusing deleted property indexes after this many properties are deleted. Zero to disable reuse.", DEFAULT_CONFIG_DeletedPropertyReuseThreshold)
 FLAGNR(Boolean, ForceStringKeyedSimpleDictionaryTypeHandler, "Force switch to string keyed version of SimpleDictionaryTypeHandler on first new property added to a SimpleDictionaryTypeHandler", DEFAULT_CONFIG_ForceStringKeyedSimpleDictionaryTypeHandler)

+ 0 - 11
lib/Common/Core/ConfigFlagsTable.h

@@ -30,17 +30,6 @@ namespace Js
         FlagNumberRange
     };
 
-    // Shadow of enum SCRIPTHOSTTYPE defined in activscp.idl.
-    enum HostType
-    {
-        HostTypeDefault = 0,        // Used to detect engines with uninitialized host type.
-        HostTypeBrowser = 1,        // Currently this implies enabled legacy language features, use it for IE.
-        HostTypeApplication = 2,    // Currently this implies legacy-free language features, use it for WWA.
-        HostTypeWebview = 3,        // Webview in a WWA/XAML app with WinRT access.
-        HostTypeMin = HostTypeBrowser,
-        HostTypeMax = HostTypeWebview
-    };
-
     ///----------------------------------------------------------------------------
     ///----------------------------------------------------------------------------
     ///

+ 0 - 16
lib/Common/Core/ConfigParser.cpp

@@ -238,22 +238,6 @@ void ConfigParser::ParseRegistryKey(HKEY hk, CmdLineArgsParser &parser)
         }
     }
 
-#ifdef ENABLE_PROJECTION
-    // FailFastIfDisconnectedDelegate
-    // This setting allows enabling fail fast if the delegate invoked is disconnected
-    //     0 - Default return the error RPC_E_DISCONNECTED if disconnected delegate is invoked
-    //     1 - Fail fast if disconnected delegate
-    dwValue = 0;
-    dwSize = sizeof(dwValue);
-    if (NOERROR == RegGetValueW(hk, nullptr, _u("FailFastIfDisconnectedDelegate"), RRF_RT_DWORD, nullptr, (LPBYTE)&dwValue, &dwSize))
-    {
-        if (dwValue == 1)
-        {
-            Js::Configuration::Global.flags.FailFastIfDisconnectedDelegate = true;
-        }
-    }
-#endif
-
     // ES6 feature control
     // This setting allows enabling\disabling es6 features
     //     0 - Enable ES6 flag - Also default behavior

+ 0 - 1
lib/Common/Core/PerfCounter.h

@@ -123,7 +123,6 @@ namespace PerfCounter
     MACRO(FrameDisplay); \
     MACRO(CompoundString); \
     MACRO(RecyclerWeakReferenceBase); \
-    MACRO(ProjectionObjectInstance); \
 
 #define RECYCLER_TRACKER_ARRAY_PERF_COUNTER_TYPE(MACRO) \
     MACRO(Var); \

+ 1 - 44
lib/Common/Memory/Recycler.cpp

@@ -52,18 +52,7 @@ DefaultRecyclerCollectionWrapper::IsCollectionDisabled(Recycler * recycler)
     if (collectionDisabled)
     {
         // disabled collection should only happen if we allowed allocation during heap enum
-        if (recycler->IsHeapEnumInProgress())
-        {
-            Assert(recycler->AllowAllocationDuringHeapEnum());
-        }
-        else
-        {
-#ifdef ENABLE_PROJECTION
-            Assert(recycler->IsInRefCountTrackingForProjection());
-#else
-            Assert(false);
-#endif
-        }
+        Assert(recycler->IsHeapEnumInProgress() && recycler->AllowAllocationDuringHeapEnum());
     }
 #endif
     return collectionDisabled;
@@ -310,7 +299,6 @@ Recycler::Recycler(AllocationPolicyManager * policyManager, IdleDecommitPageAllo
 #endif
 #if DBG || defined RECYCLER_TRACE
     this->collectionCount = 0;
-    this->inResolveExternalWeakReferences = false;
 #endif
 #if DBG || defined(RECYCLER_STATS)
     isForceSweeping = false;
@@ -327,9 +315,6 @@ Recycler::Recycler(AllocationPolicyManager * policyManager, IdleDecommitPageAllo
 #if DBG
     allowAllocationDuringRenentrance = false;
     allowAllocationDuringHeapEnum = false;
-#ifdef ENABLE_PROJECTION
-    isInRefCountTrackingForProjection = false;
-#endif
 #endif
     ScheduleNextCollection();
 #if defined(RECYCLER_DUMP_OBJECT_GRAPH) ||  defined(LEAK_REPORT) || defined(CHECK_MEMORY_LEAK)
@@ -1857,19 +1842,6 @@ Recycler::FindRoots()
 
     RECYCLER_PROFILE_EXEC_BEGIN(this, Js::FindRootPhase);
 
-#ifdef ENABLE_PROJECTION
-    {
-        AUTO_TIMESTAMP(externalWeakReferenceObjectResolve);
-        BEGIN_DUMP_OBJECT(this, _u("External Weak Referenced Roots"));
-        Assert(!this->IsInRefCountTrackingForProjection());
-#if DBG
-        AutoIsInRefCountTrackingForProjection autoIsInRefCountTrackingForProjection(this);
-#endif
-        collectionWrapper->MarkExternalWeakReferencedObjects(this->inPartialCollectMode);
-        END_DUMP_OBJECT(this);
-    }
-#endif
-
     // go through ITracker* stuff. Don't need to do it if we are doing a partial collection
     // as we keep track and mark all trackable objects.
     // Do this first because the host might unpin stuff in the process
@@ -3440,21 +3412,6 @@ Recycler::DisposeObjects()
     }
 #endif
 
-#ifdef ENABLE_PROJECTION
-    {
-        Assert(!this->inResolveExternalWeakReferences);
-        Assert(!this->allowDispose);
-#if DBG || defined RECYCLER_TRACE
-        AutoRestoreValue<bool> inResolveExternalWeakReferencedObjects(&this->inResolveExternalWeakReferences, true);
-#endif
-        AUTO_TIMESTAMP(externalWeakReferenceObjectResolve);
-
-        // This is where it is safe to resolve external weak references as they can lead to new script entry
-        collectionWrapper->ResolveExternalWeakReferencedObjects();
-    }
-#endif
-
-    Assert(!this->inResolveExternalWeakReferences);
     Assert(this->inDispose);
 
     this->inDispose = false;

+ 0 - 22
lib/Common/Memory/Recycler.h

@@ -337,10 +337,6 @@ public:
 #endif
     virtual void DisposeObjects(Recycler * recycler) = 0;
     virtual void PreDisposeObjectsCallBack() = 0;
-#ifdef ENABLE_PROJECTION
-    virtual void MarkExternalWeakReferencedObjects(bool inPartialCollect) = 0;
-    virtual void ResolveExternalWeakReferencedObjects() = 0;
-#endif
 #if DBG || defined(PROFILE_EXEC)
     virtual bool AsyncHostOperationStart(void *) = 0;
     virtual void AsyncHostOperationEnd(bool wasInAsync, void *) = 0;
@@ -440,11 +436,6 @@ public:
 #endif
     virtual void DisposeObjects(Recycler * recycler) override;
     virtual void PreDisposeObjectsCallBack() override {};
-
-#ifdef ENABLE_PROJECTION
-    virtual void MarkExternalWeakReferencedObjects(bool inPartialCollect) override {};
-    virtual void ResolveExternalWeakReferencedObjects() override {};
-#endif
 #if DBG || defined(PROFILE_EXEC)
     virtual bool AsyncHostOperationStart(void *) override { return false; };
     virtual void AsyncHostOperationEnd(bool wasInAsync, void *) override {};
@@ -963,7 +954,6 @@ private:
 
 #if DBG || defined RECYCLER_TRACE
     uint collectionCount;
-    bool inResolveExternalWeakReferences;
 #endif
 
     bool allowDispose;
@@ -1904,9 +1894,6 @@ private:
 #if DBG
     bool allowAllocationDuringHeapEnum;
     bool allowAllocationDuringRenentrance;
-#ifdef ENABLE_PROJECTION
-    bool isInRefCountTrackingForProjection;
-#endif
 #endif
     // There are two scenarios we allow limited allocation but disallow GC during those allocations:
     // in heapenum when we allocate PropertyRecord, and
@@ -2034,15 +2021,6 @@ public:
     public:
         AutoAllowAllocationDuringHeapEnum(Recycler * recycler) : AutoBooleanToggle(&recycler->allowAllocationDuringHeapEnum) {};
     };
-
-#ifdef ENABLE_PROJECTION
-    bool IsInRefCountTrackingForProjection() const { return isInRefCountTrackingForProjection;}
-    class AutoIsInRefCountTrackingForProjection : public AutoBooleanToggle
-    {
-    public:
-        AutoIsInRefCountTrackingForProjection(Recycler * recycler) : AutoBooleanToggle(&recycler->isInRefCountTrackingForProjection) {};
-    };
-#endif
 #endif
 
     class AutoAllowAllocationDuringReentrance : public AutoBooleanToggle

+ 1 - 3
lib/Common/Memory/RecyclerSweep.cpp

@@ -160,9 +160,7 @@ RecyclerSweep::FlushPendingTransferDisposedObjects()
 {
     if (this->heapInfo->hasPendingTransferDisposedObjects)
     {
-        // If recycler->inResolveExternalWeakReferences is true, the recycler isn't really disposing anymore
-        // so it's safe to call transferDisposedObjects
-        Assert(!recycler->inDispose || recycler->inResolveExternalWeakReferences);
+        Assert(!recycler->inDispose);
         Assert(!recycler->hasDisposableObject);
         heapInfo->TransferDisposedObjects();
     }

+ 0 - 2
lib/Common/Memory/RecyclerWatsonTelemetry.h

@@ -46,8 +46,6 @@ namespace Memory
         FILETIME concurrentMarkFinishTime;
         FILETIME disposeStartTime;
         FILETIME disposeEndTime;
-        FILETIME externalWeakReferenceObjectResolveStartTime;
-        FILETIME externalWeakReferenceObjectResolveEndTime;
         FILETIME currentCollectionEndTime;
         FILETIME lastCollectionEndTime;
         DWORD exhaustiveRepeatedCount;

+ 0 - 14
lib/Jsrt/Core/JsrtContextCore.h

@@ -222,20 +222,6 @@ public:
         return E_NOTIMPL;
     }
 
-    HRESULT ArrayBufferFromExternalObject(__in Js::RecyclableObject *obj,
-        __out Js::ArrayBuffer **ppArrayBuffer) override
-    {
-        // there is no IBuffer in chakracore.
-        *ppArrayBuffer = nullptr;
-        return S_FALSE;
-    }
-
-    Js::JavascriptError* CreateWinRTError(IErrorInfo* perrinfo, Js::RestrictedErrorStrings * proerrstr) override
-    {
-        AssertMsg(false, "no winrt support in chakracore");
-        return nullptr;
-    }
-
     HRESULT ThrowIfFailed(HRESULT hr) override
     {
         hr;

+ 0 - 3
lib/Parser/ParserCommon.h

@@ -29,9 +29,6 @@ enum ErrorTypeEnum
     kjstWebAssemblyRuntimeError,
     kjstWebAssemblyLinkError,
     kjstCustomError,
-#ifdef ENABLE_PROJECTION
-    kjstWinRTError,
-#endif
 };
 
 class ParseNode;

+ 0 - 93
lib/Runtime/Base/DelayLoadLibrary.cpp

@@ -156,26 +156,6 @@ namespace Js
         return E_NOTIMPL;
     }
 
-    HRESULT DelayLoadWinRtTypeResolution::RoParseTypeName(__in HSTRING typeName, __out DWORD *partsCount, __RPC__deref_out_ecount_full_opt(*partsCount) HSTRING **typeNameParts)
-    {
-        if (m_hModule)
-        {
-            if (m_pfnRoParseTypeName == nullptr)
-            {
-                m_pfnRoParseTypeName = (PFNCWRoParseTypeName)GetFunction("RoParseTypeName");
-                if (m_pfnRoParseTypeName == nullptr)
-                {
-                    return E_UNEXPECTED;
-                }
-            }
-
-            Assert(m_pfnRoParseTypeName != nullptr);
-            return m_pfnRoParseTypeName(typeName, partsCount, typeNameParts);
-        }
-
-        return E_NOTIMPL;
-    }
-
 #ifdef INTL_WINGLOB
     bool DelayLoadWindowsGlobalization::HasGlobalizationDllLoaded()
     {
@@ -228,35 +208,6 @@ namespace Js
         return E_NOTIMPL;
     }
 
-    HRESULT DelayLoadWinRtTypeResolution::RoResolveNamespace(
-        __in_opt const HSTRING namespaceName,
-        __in_opt const HSTRING windowsMetaDataPath,
-        __in const DWORD packageGraphPathsCount,
-        __in_opt const HSTRING *packageGraphPaths,
-        __out DWORD *metaDataFilePathsCount,
-        HSTRING **metaDataFilePaths,
-        __out DWORD *subNamespacesCount,
-        HSTRING **subNamespaces)
-    {
-        if (m_hModule)
-        {
-            if (m_pfnRoResolveNamespace == nullptr)
-            {
-                m_pfnRoResolveNamespace = (PFNCRoResolveNamespace)GetFunction("RoResolveNamespace");
-                if (m_pfnRoResolveNamespace == nullptr)
-                {
-                    return E_UNEXPECTED;
-                }
-            }
-
-            Assert(m_pfnRoResolveNamespace != nullptr);
-            return m_pfnRoResolveNamespace(namespaceName, windowsMetaDataPath, packageGraphPathsCount, packageGraphPaths,
-                metaDataFilePathsCount, metaDataFilePaths, subNamespacesCount, subNamespaces);
-        }
-
-        return E_NOTIMPL;
-    }
-
 #ifdef INTL_WINGLOB
     void DelayLoadWindowsGlobalization::Ensure(Js::DelayLoadWinRtString *winRTStringLibrary)
     {
@@ -349,50 +300,6 @@ namespace Js
     }
 #endif
 
-#ifdef ENABLE_PROJECTION
-    HRESULT DelayLoadWinRtError::RoClearError()
-    {
-        if (m_hModule)
-        {
-            if (m_pfnRoClearError == nullptr)
-            {
-                m_pfnRoClearError = (PFNCRoClearError)GetFunction("RoClearError");
-                if (m_pfnRoClearError == nullptr)
-                {
-                    return E_UNEXPECTED;
-                }
-            }
-
-            Assert(m_pfnRoClearError != nullptr);
-            m_pfnRoClearError();
-
-            return S_OK;
-        }
-
-        return E_NOTIMPL;
-    }
-
-    BOOL DelayLoadWinRtError::RoOriginateLanguageException(__in HRESULT error, __in_opt HSTRING message, __in IUnknown * languageException)
-    {
-        if (m_hModule)
-        {
-            if (m_pfnRoOriginateLanguageException == nullptr)
-            {
-                m_pfnRoOriginateLanguageException = (PFNCRoOriginateLanguageException)GetFunction("RoOriginateLanguageException");
-                if (m_pfnRoOriginateLanguageException == nullptr)
-                {
-                    return FALSE;
-                }
-            }
-
-            Assert(m_pfnRoOriginateLanguageException != nullptr);
-            return m_pfnRoOriginateLanguageException(error, message, languageException);
-        }
-
-        return FALSE;
-    }
-#endif
-
     BOOL DelayLoadWinCoreProcessThreads::GetProcessInformation(
         __in HANDLE hProcess,
         __in PROCESS_INFORMATION_CLASS ProcessInformationClass,

+ 0 - 124
lib/Runtime/Base/DelayLoadLibrary.h

@@ -8,14 +8,6 @@
 #include "activation.h"
 #include <winstring.h>
 
-#ifdef ENABLE_PROJECTION
-// cor.h includes corhdr.h which is not clean with warning 4091
-#pragma warning(push)
-#pragma warning(disable: 4091) /* warning C4091: 'typedef ': ignored on left of '' when no variable is declared */
-#include <cor.h>
-#pragma warning(pop)
-#endif
-
 #include "RoParameterizedIID.h"
 
 namespace Js
@@ -69,67 +61,6 @@ namespace Js
         virtual HRESULT WindowsDuplicateString(_In_opt_ HSTRING original, _Outptr_result_maybenull_ _Result_nullonfailure_ HSTRING * newString);
     };
 
-    class DelayLoadWinRtTypeResolution sealed : public DelayLoadLibrary
-    {
-    private:
-        // WinRtTypeResolution specific functions
-        typedef HRESULT FNCWRoParseTypeName(HSTRING, DWORD *, HSTRING **);
-        typedef FNCWRoParseTypeName* PFNCWRoParseTypeName;
-        PFNCWRoParseTypeName m_pfnRoParseTypeName;
-
-        typedef HRESULT FNCRoResolveNamespace(const HSTRING, const HSTRING, const DWORD, const HSTRING*, DWORD*, HSTRING**, DWORD*, HSTRING**);
-        typedef FNCRoResolveNamespace* PFNCRoResolveNamespace;
-        PFNCRoResolveNamespace m_pfnRoResolveNamespace;
-
-    public:
-        DelayLoadWinRtTypeResolution() : DelayLoadLibrary(),
-            m_pfnRoParseTypeName(nullptr) { }
-
-        virtual ~DelayLoadWinRtTypeResolution() { }
-
-        LPCTSTR GetLibraryName() const { return _u("api-ms-win-ro-typeresolution-l1-1-0.dll"); }
-
-        HRESULT RoParseTypeName(__in HSTRING typeName, __out DWORD *partsCount, __RPC__deref_out_ecount_full_opt(*partsCount) HSTRING **typeNameParts);
-
-        HRESULT RoResolveNamespace(
-            __in_opt const HSTRING namespaceName,
-            __in_opt const HSTRING windowsMetaDataPath,
-            __in const DWORD packageGraphPathsCount,
-            __in_opt const HSTRING *packageGraphPaths,
-            __out DWORD *metaDataFilePathsCount,
-            HSTRING **metaDataFilePaths,
-            __out DWORD *subNamespacesCount,
-            HSTRING **subNamespaces);
-
-    };
-
-#ifdef ENABLE_PROJECTION
-    class DelayLoadWinRtRoParameterizedIID sealed : public DelayLoadLibrary
-    {
-    private:
-        // WinRtRoParameterizedIID specific functions
-        typedef HRESULT FNCWRoGetParameterizedTypeInstanceIID(UINT32, PCWSTR*, const IRoMetaDataLocator&, GUID*, ROPARAMIIDHANDLE*);
-
-        typedef FNCWRoGetParameterizedTypeInstanceIID* PFNCWRoGetParameterizedTypeInstanceIID;
-        PFNCWRoGetParameterizedTypeInstanceIID m_pfnRoGetParameterizedTypeInstanceIID;
-
-    public:
-        DelayLoadWinRtRoParameterizedIID() : DelayLoadLibrary(),
-            m_pfnRoGetParameterizedTypeInstanceIID(nullptr) { }
-
-        virtual ~DelayLoadWinRtRoParameterizedIID() { }
-
-        LPCTSTR GetLibraryName() const { return _u("api-ms-win-core-winrt-roparameterizediid-l1-1-0.dll"); }
-
-        HRESULT RoGetParameterizedTypeInstanceIID(
-            __in UINT32 nameElementCount,
-            __in_ecount(nameElementCount) PCWSTR*   nameElements,
-            __in const IRoMetaDataLocator&          metaDataLocator,
-            __out GUID*                             iid,
-            __deref_opt_out ROPARAMIIDHANDLE*       pExtra = nullptr);
-    };
-#endif
-
 #ifdef INTL_WINGLOB
     class DelayLoadWindowsGlobalization sealed : public DelayLoadWinRtString
     {
@@ -198,33 +129,6 @@ namespace Js
             __out IActivationFactory** factory);
     };
 
-#ifdef ENABLE_PROJECTION
-    class DelayLoadWinRtError sealed : public DelayLoadLibrary
-    {
-    private:
-        // DelayLoadWinRtError specific functions
-        typedef void FNCRoClearError();
-        typedef FNCRoClearError* PFNCRoClearError;
-        PFNCRoClearError m_pfnRoClearError;
-
-        typedef BOOL FNCRoOriginateLanguageException(HRESULT, HSTRING, IUnknown *);
-        typedef FNCRoOriginateLanguageException* PFNCRoOriginateLanguageException;
-        PFNCRoOriginateLanguageException m_pfnRoOriginateLanguageException;
-
-    public:
-        DelayLoadWinRtError() : DelayLoadLibrary(),
-            m_pfnRoClearError(nullptr),
-            m_pfnRoOriginateLanguageException(nullptr) { }
-
-        virtual ~DelayLoadWinRtError() { }
-
-        LPCTSTR GetLibraryName() const { return _u("api-ms-win-core-winrt-error-l1-1-1.dll"); }
-
-        HRESULT RoClearError();
-        BOOL RoOriginateLanguageException(__in HRESULT error, __in_opt HSTRING message, __in IUnknown * languageException);
-    };
-#endif
-
     class DelayLoadWinCoreProcessThreads sealed : public DelayLoadLibrary
     {
     private:
@@ -250,32 +154,4 @@ namespace Js
             __in SIZE_T nLength
         );
     };
-
-#ifdef ENABLE_PROJECTION
-    // Implement this function inlined so that WinRT.lib can be used without the runtime.
-    inline HRESULT DelayLoadWinRtRoParameterizedIID::RoGetParameterizedTypeInstanceIID(
-            __in UINT32 nameElementCount,
-            __in_ecount(nameElementCount) PCWSTR*   nameElements,
-            __in const IRoMetaDataLocator&          metaDataLocator,
-            __out GUID*                             iid,
-            __deref_opt_out ROPARAMIIDHANDLE*       pExtra)
-    {
-        if (m_hModule)
-        {
-            if (m_pfnRoGetParameterizedTypeInstanceIID == NULL)
-            {
-                m_pfnRoGetParameterizedTypeInstanceIID = (PFNCWRoGetParameterizedTypeInstanceIID)GetFunction("RoGetParameterizedTypeInstanceIID");
-                if (m_pfnRoGetParameterizedTypeInstanceIID == NULL)
-                {
-                    return E_UNEXPECTED;
-                }
-            }
-
-            Assert(m_pfnRoGetParameterizedTypeInstanceIID != NULL);
-            return m_pfnRoGetParameterizedTypeInstanceIID(nameElementCount, nameElements, metaDataLocator, iid, pExtra);
-        }
-
-        return E_NOTIMPL;
-    }
-#endif
  }

+ 1 - 1
lib/Runtime/Base/JnDirectFields.h

@@ -416,7 +416,7 @@ ENTRY(valueOf)
 ENTRY(values)
 ENTRY(WeakMap)
 ENTRY(WeakSet)
-ENTRY(WinRTError)
+ENTRY(WinRTError) // remove this upon next bytecode regen
 ENTRY(write)
 ENTRY(writeln)
 ENTRY(setNonUserCodeExceptions)

+ 1 - 1
lib/Runtime/Base/ScriptContext.cpp

@@ -4905,7 +4905,7 @@ ExitTempAllocator:
             if (cachedFunctionId != functionPropertyId)
             {
                 // This is the scenario where we could be using same function for multiple builtin functions
-                // e.g. Error.toString, WinRTError.toString etc.
+                // e.g. Error.toString etc.
                 // We would ignore these extra entrypoints because while profiling, identifying which object's toString is too costly for its worth
                 return S_OK;
             }

+ 0 - 64
lib/Runtime/Base/ScriptContext.h

@@ -176,9 +176,6 @@ public:
 
     virtual HRESULT GetExternalJitData(ExternalJitData id, void *data) = 0;
     virtual HRESULT SetDispatchInvoke(Js::JavascriptMethod dispatchInvoke) = 0;
-    virtual HRESULT ArrayBufferFromExternalObject(__in Js::RecyclableObject *obj,
-        __out Js::ArrayBuffer **ppArrayBuffer) = 0;
-    virtual Js::JavascriptError* CreateWinRTError(IErrorInfo* perrinfo, Js::RestrictedErrorStrings * proerrstr) = 0;
     virtual HRESULT EnqueuePromiseTask(Js::Var varTask) = 0;
 
     virtual HRESULT FetchImportedModule(Js::ModuleRecordBase* referencingModule, LPCOLESTR specifier, Js::ModuleRecordBase** dependentModuleRecord) = 0;
@@ -275,33 +272,10 @@ namespace Js
     };
 #pragma pack(pop)
 
-#ifdef ENABLE_PROJECTION
-    class ProjectionConfiguration
-    {
-    public:
-        ProjectionConfiguration() : targetVersion(0)
-        {
-        }
-
-        DWORD GetTargetVersion() const { return this->targetVersion; }
-        void SetTargetVersion(DWORD version) { this->targetVersion = version; }
-
-        bool IsTargetWindows8() const           { return this->targetVersion == NTDDI_WIN8; }
-        bool IsTargetWindowsBlueOrLater() const { return this->targetVersion >= NTDDI_WINBLUE; }
-
-    private:
-        DWORD targetVersion;
-    };
-#endif // ENABLE_PROJECTION
-
     class ScriptConfiguration
     {
     public:
         ScriptConfiguration(const ThreadConfiguration * const threadConfig, const bool isOptimizedForManyInstances) :
-#ifdef ENABLE_PROJECTION
-            HostType(Configuration::Global.flags.HostType),
-            WinRTConstructorAllowed(Configuration::Global.flags.WinRTConstructorAllowed),
-#endif
             NoNative(Configuration::Global.flags.NoNative),
             NoDynamicThunks(false),
             isOptimizedForManyInstances(isOptimizedForManyInstances),
@@ -331,48 +305,15 @@ namespace Js
         {
             this->NoNative = other.NoNative;
             this->fCanOptimizeGlobalLookup = other.fCanOptimizeGlobalLookup;
-#ifdef ENABLE_PROJECTION
-            this->HostType = other.HostType;
-            this->WinRTConstructorAllowed = other.WinRTConstructorAllowed;
-            this->projectionConfiguration = other.projectionConfiguration;
-#endif
         }
 
-#ifdef ENABLE_PROJECTION
-        Number GetHostType() const    // Returns one of enum HostType values (see ConfigFlagsTable.h).
-        {
-            AssertMsg(this->HostType >= HostTypeMin && this->HostType <= HostTypeMax, "HostType value is out of valid range.");
-            return this->HostType;
-        }
-
-        ProjectionConfiguration const * GetProjectionConfig() const
-        {
-            return &projectionConfiguration;
-        }
-        void SetHostType(int32 hostType) { this->HostType = hostType; }
-        void SetWinRTConstructorAllowed(bool allowed) { this->WinRTConstructorAllowed = allowed; }
-        void SetProjectionTargetVersion(DWORD version)
-        {
-            projectionConfiguration.SetTargetVersion(version);
-        }
-        bool IsWinRTEnabled()           const { return (GetHostType() == Js::HostTypeApplication) || (GetHostType() == Js::HostTypeWebview); }
-
-        bool IsWinRTConstructorAllowed() const { return (GetHostType() != Js::HostTypeWebview) || this->WinRTConstructorAllowed; }
-#endif
     private:
-
         // Per script configurations
         bool NoNative;
         bool NoDynamicThunks;
         BOOL fCanOptimizeGlobalLookup;
         const bool isOptimizedForManyInstances;
         const ThreadConfiguration * const threadConfig;
-
-#ifdef ENABLE_PROJECTION
-        Number HostType;    // One of enum HostType values (see ConfigFlagsTable.h).
-        bool WinRTConstructorAllowed;  // whether allow constructor in webview host type. Also note that this is not a security feature.
-        ProjectionConfiguration projectionConfiguration;
-#endif
     };
 
     struct ScriptEntryExitRecord
@@ -1240,11 +1181,6 @@ private:
         void Initialize();
         bool Close(bool inDestructor);
         void MarkForClose();
-#ifdef ENABLE_PROJECTION
-        void SetHostType(int32 hostType) { config.SetHostType(hostType); }
-        void SetWinRTConstructorAllowed(bool allowed) { config.SetWinRTConstructorAllowed(allowed); }
-        void SetProjectionTargetVersion(DWORD version) { config.SetProjectionTargetVersion(version); }
-#endif
         void SetCanOptimizeGlobalLookupFlag(BOOL f){ config.SetCanOptimizeGlobalLookupFlag(f);}
         BOOL CanOptimizeGlobalLookup(){ return config.CanOptimizeGlobalLookup();}
 

+ 2 - 5
lib/Runtime/Base/ThreadConfigFlagsList.h

@@ -49,11 +49,8 @@ FLAG_RELEASE(IsESExportNsAsEnabled, ESExportNsAs)
 FLAG_RELEASE(IsESSymbolDescriptionEnabled, ESSymbolDescription)
 FLAG_RELEASE(IsESGlobalThisEnabled, ESGlobalThis)
 FLAG_RELEASE(IsES2018AsyncIterationEnabled, ES2018AsyncIteration)
+FLAG_RELEASE(IsESTopLevelAwaitEnabled, ESTopLevelAwait)
+
 #ifdef ENABLE_TEST_HOOKS
 FLAG_RELEASE(Force32BitByteCode, Force32BitByteCode)
 #endif
-FLAG_RELEASE(IsESTopLevelAwaitEnabled, ESTopLevelAwait)
-#ifdef ENABLE_PROJECTION
-FLAG(AreWinRTDelegatesInterfaces, WinRTDelegateInterfaces)
-FLAG_RELEASE(IsWinRTAdaptiveAppsEnabled, WinRTAdaptiveApps)
-#endif

+ 0 - 122
lib/Runtime/Base/ThreadContext.cpp

@@ -215,7 +215,6 @@ ThreadContext::ThreadContext(AllocationPolicyManager * allocationPolicyManager,
     , closedScriptContextCount(0)
     , visibilityState(VisibilityState::Undefined)
 {
-    pendingProjectionContextCloseList = JsUtil::List<IProjectionContext*, ArenaAllocator>::New(GetThreadAlloc());
     hostScriptContextStack = Anew(GetThreadAlloc(), JsUtil::Stack<HostScriptContext*>, GetThreadAlloc());
 
     functionCount = 0;
@@ -261,12 +260,6 @@ ThreadContext::ThreadContext(AllocationPolicyManager * allocationPolicyManager,
     pageAllocator.UpdateThreadContextHandle((ThreadContextId)this);
 #endif
 
-#ifdef ENABLE_PROJECTION
-#if DBG_DUMP
-    this->projectionMemoryInformation = nullptr;
-#endif
-#endif
-
 #if DBG
     arrayMutationSeed = (Js::Configuration::Global.flags.ArrayMutationTestSeed != 0) ? (uint)Js::Configuration::Global.flags.ArrayMutationTestSeed : (uint)time(NULL);
     srand(arrayMutationSeed);
@@ -554,10 +547,6 @@ ThreadContext::~ThreadContext()
     // Do not require all GC callbacks to be revoked, because Trident may not revoke if there
     // is a leak, and we don't want the leak to be masked by an assert
 
-#ifdef ENABLE_PROJECTION
-    externalWeakReferenceCacheList.Clear(&HeapAllocator::Instance);
-#endif
-
     this->collectCallBackList.Clear(&HeapAllocator::Instance);
     this->protoInlineCacheByPropId.Reset();
     this->storeFieldInlineCacheByPropId.Reset();
@@ -594,16 +583,6 @@ ThreadContext::~ThreadContext()
         this->dynamicProfileMutator->Delete();
     }
 #endif
-
-#ifdef ENABLE_PROJECTION
-#if DBG_DUMP
-    if (this->projectionMemoryInformation)
-    {
-        this->projectionMemoryInformation->Release();
-        this->projectionMemoryInformation = nullptr;
-    }
-#endif
-#endif
 }
 
 void
@@ -1506,7 +1485,6 @@ ThreadContext::EnterScriptEnd(Js::ScriptEntryExitRecord * record, bool doCleanup
         {
             poller->EndScript();
         }
-        ClosePendingProjectionContexts();
         ClosePendingScriptContexts();
         Assert(rootPendingClose == nullptr);
 
@@ -2459,30 +2437,6 @@ void ThreadContext::ClosePendingScriptContexts()
     rootPendingClose = nullptr;
 }
 
-void
-ThreadContext::AddToPendingProjectionContextCloseList(IProjectionContext *projectionContext)
-{
-    pendingProjectionContextCloseList->Add(projectionContext);
-}
-
-void
-ThreadContext::RemoveFromPendingClose(IProjectionContext* projectionContext)
-{
-    pendingProjectionContextCloseList->Remove(projectionContext);
-}
-
-void ThreadContext::ClosePendingProjectionContexts()
-{
-    IProjectionContext* projectionContext;
-    for (int i = 0 ; i < pendingProjectionContextCloseList->Count(); i++)
-    {
-        projectionContext = pendingProjectionContextCloseList->Item(i);
-        projectionContext->Close();
-    }
-    pendingProjectionContextCloseList->Clear();
-
-}
-
 void
 ThreadContext::RegisterScriptContext(Js::ScriptContext *scriptContext)
 {
@@ -4466,59 +4420,6 @@ void ThreadContext::EtwLogPropertyIdList()
 }
 #endif
 
-#ifdef ENABLE_PROJECTION
-void ThreadContext::AddExternalWeakReferenceCache(ExternalWeakReferenceCache *externalWeakReferenceCache)
-{
-    this->externalWeakReferenceCacheList.Prepend(&HeapAllocator::Instance, externalWeakReferenceCache);
-}
-
-void ThreadContext::RemoveExternalWeakReferenceCache(ExternalWeakReferenceCache *externalWeakReferenceCache)
-{
-    Assert(!externalWeakReferenceCacheList.Empty());
-    this->externalWeakReferenceCacheList.Remove(&HeapAllocator::Instance, externalWeakReferenceCache);
-}
-
-void ThreadContext::MarkExternalWeakReferencedObjects(bool inPartialCollect)
-{
-    SListBase<ExternalWeakReferenceCache *, HeapAllocator>::Iterator iteratorWeakRefCache(&this->externalWeakReferenceCacheList);
-    while (iteratorWeakRefCache.Next())
-    {
-        iteratorWeakRefCache.Data()->MarkNow(recycler, inPartialCollect);
-    }
-}
-
-void ThreadContext::ResolveExternalWeakReferencedObjects()
-{
-    SListBase<ExternalWeakReferenceCache *, HeapAllocator>::Iterator iteratorWeakRefCache(&this->externalWeakReferenceCacheList);
-    while (iteratorWeakRefCache.Next())
-    {
-        iteratorWeakRefCache.Data()->ResolveNow(recycler);
-    }
-}
-
-#if DBG_DUMP
-void ThreadContext::RegisterProjectionMemoryInformation(IProjectionContextMemoryInfo* projectionContextMemoryInfo)
-{
-    Assert(this->projectionMemoryInformation == nullptr || this->projectionMemoryInformation == projectionContextMemoryInfo);
-
-    this->projectionMemoryInformation = projectionContextMemoryInfo;
-}
-
-void ThreadContext::DumpProjectionContextMemoryStats(LPCWSTR headerMsg, bool forceDetailed)
-{
-    if (this->projectionMemoryInformation)
-    {
-        this->projectionMemoryInformation->DumpCurrentStats(headerMsg, forceDetailed);
-    }
-}
-
-IProjectionContextMemoryInfo* ThreadContext::GetProjectionContextMemoryInformation()
-{
-    return this->projectionMemoryInformation;
-}
-#endif
-#endif
-
 #ifdef ENABLE_DEBUG_CONFIG_OPTIONS
 Js::Var ThreadContext::GetMemoryStat(Js::ScriptContext* scriptContext)
 {
@@ -4684,29 +4585,6 @@ Js::DelayLoadWinRtString * ThreadContext::GetWinRTStringLibrary()
     return &delayLoadWinRtString;
 }
 
-#ifdef ENABLE_PROJECTION
-Js::DelayLoadWinRtError * ThreadContext::GetWinRTErrorLibrary()
-{
-    delayLoadWinRtError.EnsureFromSystemDirOnly();
-
-    return &delayLoadWinRtError;
-}
-
-Js::DelayLoadWinRtTypeResolution* ThreadContext::GetWinRTTypeResolutionLibrary()
-{
-    delayLoadWinRtTypeResolution.EnsureFromSystemDirOnly();
-
-    return &delayLoadWinRtTypeResolution;
-}
-
-Js::DelayLoadWinRtRoParameterizedIID* ThreadContext::GetWinRTRoParameterizedIIDLibrary()
-{
-    delayLoadWinRtRoParameterizedIID.EnsureFromSystemDirOnly();
-
-    return &delayLoadWinRtRoParameterizedIID;
-}
-#endif
-
 #if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_ES6_CHAR_CLASSIFIER)
 #ifdef INTL_WINGLOB
 Js::WindowsGlobalizationAdapter* ThreadContext::GetWindowsGlobalizationAdapter()

+ 0 - 58
lib/Runtime/Base/ThreadContext.h

@@ -50,12 +50,6 @@ enum ThreadContextFlags
 
 const int LS_MAX_STACK_SIZE_KB = 300;
 
-struct IProjectionContext
-{
-public:
-    virtual HRESULT Close() = 0;
-};
-
 class ThreadContext;
 
 class InterruptPoller
@@ -194,23 +188,6 @@ enum RecyclerCollectCallBackFlags
 };
 typedef void (__cdecl *RecyclerCollectCallBackFunction)(void * context, RecyclerCollectCallBackFlags flags);
 
-#ifdef ENABLE_PROJECTION
-class ExternalWeakReferenceCache
-{
-public:
-    virtual void MarkNow(Recycler *recycler, bool inPartialCollect) = 0;
-    virtual void ResolveNow(Recycler *recycler) = 0;
-};
-#if DBG_DUMP
-class IProjectionContextMemoryInfo abstract
-{
-public:
-    virtual void DumpCurrentStats(LPCWSTR headerMsg, bool forceDetailed) = 0;
-    virtual void Release() = 0;
-};
-#endif
-#endif
-
 #ifdef NTBUILD
 struct ThreadContextWatsonTelemetryBlock
 {
@@ -684,7 +661,6 @@ private:
     PropertyNoCaseSetType * caseInvariantPropertySet;
 
     Js::ScriptContext * rootPendingClose;
-    JsUtil::List<IProjectionContext *, ArenaAllocator>* pendingProjectionContextCloseList;
     Js::ScriptEntryExitRecord * entryExitRecord;
     Js::InterpreterStackFrame* leafInterpreterFrame;
     const Js::PropertyRecord * propertyNamesDirect[128];
@@ -712,13 +688,6 @@ private:
     Js::TypeId nextTypeId;
     uint32 polymorphicCacheState;
 
-#ifdef ENABLE_PROJECTION
-    SListBase<ExternalWeakReferenceCache *, HeapAllocator> externalWeakReferenceCacheList;
-#if DBG_DUMP
-    IProjectionContextMemoryInfo *projectionMemoryInformation;
-#endif
-#endif
-
 #if ENABLE_NATIVE_CODEGEN
     JsUtil::JobProcessor *jobProcessor;
     Js::Var * bailOutRegisterSaveSpace;
@@ -803,11 +772,6 @@ private:
 
 #ifdef ENABLE_GLOBALIZATION
     Js::DelayLoadWinRtString delayLoadWinRtString;
-#ifdef ENABLE_PROJECTION
-    Js::DelayLoadWinRtError delayLoadWinRtError;
-    Js::DelayLoadWinRtTypeResolution delayLoadWinRtTypeResolution;
-    Js::DelayLoadWinRtRoParameterizedIID delayLoadWinRtRoParameterizedIID;
-#endif
 #if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_ES6_CHAR_CLASSIFIER)
 #ifdef INTL_WINGLOB
     Js::DelayLoadWindowsGlobalization delayLoadWindowsGlobalizationLibrary;
@@ -921,11 +885,6 @@ public:
 
 #ifdef ENABLE_GLOBALIZATION
     Js::DelayLoadWinRtString *GetWinRTStringLibrary();
-#ifdef ENABLE_PROJECTION
-    Js::DelayLoadWinRtError *GetWinRTErrorLibrary();
-    Js::DelayLoadWinRtTypeResolution* GetWinRTTypeResolutionLibrary();
-    Js::DelayLoadWinRtRoParameterizedIID* GetWinRTRoParameterizedIIDLibrary();
-#endif
 #if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_ES6_CHAR_CLASSIFIER)
 #ifdef INTL_WINGLOB
     Js::DelayLoadWindowsGlobalization *GetWindowsGlobalizationLibrary();
@@ -1155,10 +1114,6 @@ public:
     ThreadContext::CollectCallBack * AddRecyclerCollectCallBack(RecyclerCollectCallBackFunction callback, void * context);
     void RemoveRecyclerCollectCallBack(ThreadContext::CollectCallBack * collectCallBack);
 
-    void AddToPendingProjectionContextCloseList(IProjectionContext *projectionContext);
-    void RemoveFromPendingClose(IProjectionContext *projectionContext);
-    void ClosePendingProjectionContexts();
-
     void AddToPendingScriptContextCloseList(Js::ScriptContext * scriptContext);
     void RemoveFromPendingClose(Js::ScriptContext * scriptContext);
     void ClosePendingScriptContexts();
@@ -1224,19 +1179,6 @@ public:
     void SetThreadServiceWrapper(ThreadServiceWrapper*);
     ThreadServiceWrapper* GetThreadServiceWrapper();
 
-#ifdef ENABLE_PROJECTION
-    void AddExternalWeakReferenceCache(ExternalWeakReferenceCache *externalWeakReferenceCache);
-    void RemoveExternalWeakReferenceCache(ExternalWeakReferenceCache *externalWeakReferenceCache);
-    virtual void MarkExternalWeakReferencedObjects(bool inPartialCollect) override;
-    virtual void ResolveExternalWeakReferencedObjects() override;
-
-#if DBG_DUMP
-    void RegisterProjectionMemoryInformation(IProjectionContextMemoryInfo* projectionContextMemoryInfo);
-    void DumpProjectionContextMemoryStats(LPCWSTR headerMsg, bool forceDetailed = false);
-    IProjectionContextMemoryInfo* GetProjectionContextMemoryInformation();
-#endif
-#endif
-
     uint NewFunctionNumber() { return ++functionCount; }
     uint PeekNewFunctionNumber() { return functionCount + 1; }
 

+ 0 - 21
lib/Runtime/Library/DataView.cpp

@@ -37,27 +37,6 @@ namespace Js
             JavascriptError::ThrowTypeError(scriptContext, JSERR_DataView_NeedArgument, _u("buffer"));
         }
 
-        // Currently the only reason we check for an external object is projection related, so it remains under conditional compilation.
-        RecyclableObject* jsArraySource = NULL;
-        if (JavascriptOperators::IsObject(args[1]) && JavascriptConversion::ToObject(args[1], scriptContext, &jsArraySource))
-        {
-            ArrayBuffer *ab = nullptr;
-            HRESULT hr = scriptContext->GetHostScriptContext()->ArrayBufferFromExternalObject(jsArraySource, &ab);
-            switch (hr)
-            {
-            case S_OK:
-            case S_FALSE:
-                arrayBuffer = ab;
-                // Both of these cases will be handled by the arrayBuffer null check.
-                break;
-
-            default:
-                // Any FAILURE HRESULT or unexpected HRESULT.
-                JavascriptError::ThrowTypeError(scriptContext, JSERR_DataView_InvalidArgument, _u("buffer"));
-                break;
-            }
-        }
-
         //2.    If Type(buffer) is not Object, throw a TypeError exception.
         //3.    If buffer does not have an [[ArrayBufferData]] internal slot, throw a TypeError exception.
         if (arrayBuffer == nullptr)

+ 2 - 2
lib/Runtime/Library/EngineInterfaceObject.cpp

@@ -4,7 +4,7 @@
 //-------------------------------------------------------------------------------------------------------
 #include "RuntimeLibraryPch.h"
 
-#if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_JS_BUILTINS) || defined(ENABLE_PROJECTION)
+#if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_JS_BUILTINS)
 
 #include "errstr.h"
 #include "Library/EngineInterfaceObject.h"
@@ -515,4 +515,4 @@ namespace Js
 #include "EngineInterfaceObjectBuiltIns.h"
 
 }
-#endif // ENABLE_INTL_OBJECT || ENABLE_JS_BUILTINS || ENABLE_PROJECTION
+#endif // ENABLE_INTL_OBJECT || ENABLE_JS_BUILTINS

+ 2 - 2
lib/Runtime/Library/EngineInterfaceObject.h

@@ -4,7 +4,7 @@
 //-------------------------------------------------------------------------------------------------------
 #pragma once
 
-#if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_JS_BUILTINS) || defined(ENABLE_PROJECTION)
+#if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_JS_BUILTINS)
 
 namespace Js
 {
@@ -111,4 +111,4 @@ namespace Js
     }
 }
 
-#endif // ENABLE_INTL_OBJECT || ENABLE_JS_BUILTINS || ENABLE_PROJECTION
+#endif // ENABLE_INTL_OBJECT || ENABLE_JS_BUILTINS

+ 0 - 17
lib/Runtime/Library/GlobalObject.cpp

@@ -1540,19 +1540,6 @@ LHexError:
         Assert(!(callInfo.Flags & CallFlags_New));
 
         ScriptContext* scriptContext = function->GetScriptContext();
-        if (!scriptContext->GetConfig()->IsCollectGarbageEnabled()
-#ifdef ENABLE_PROJECTION
-            && scriptContext->GetConfig()->GetHostType() != HostType::HostTypeApplication
-            && scriptContext->GetConfig()->GetHostType() != HostType::HostTypeWebview
-#endif
-            )
-        {
-            // We expose the CollectGarbage API with flag for compat reasons.
-            // If CollectGarbage key is not enabled, and if the HostType is neither
-            // HostType::HostTypeApplication nor HostType::HostTypeWebview,
-            // then we do not trigger collection.
-            return scriptContext->GetLibrary()->GetUndefined();
-        }
 
         Recycler* recycler = scriptContext->GetRecycler();
         if (recycler)
@@ -1572,10 +1559,6 @@ LHexError:
         }
 
 #if DBG_DUMP
-#ifdef ENABLE_PROJECTION
-        scriptContext->GetThreadContext()->DumpProjectionContextMemoryStats(_u("Stats after GlobalObject::EntryCollectGarbage call"));
-#endif
-
         if (Js::Configuration::Global.flags.TraceWin8Allocations)
         {
             Output::Print(_u("MemoryTrace: GlobalObject::EntryCollectGarbage Exit\n"));

+ 0 - 3
lib/Runtime/Library/JavascriptBuiltInFunctionList.h

@@ -138,9 +138,6 @@ BUILTIN(JavascriptError, NewURIErrorInstance, NewURIErrorInstance, FunctionInfo:
 BUILTIN(JavascriptError, NewWebAssemblyCompileErrorInstance, NewWebAssemblyCompileErrorInstance, FunctionInfo::None)
 BUILTIN(JavascriptError, NewWebAssemblyRuntimeErrorInstance, NewWebAssemblyRuntimeErrorInstance, FunctionInfo::None)
 BUILTIN(JavascriptError, NewWebAssemblyLinkErrorInstance, NewWebAssemblyLinkErrorInstance, FunctionInfo::None)
-#ifdef ENABLE_PROJECTION
-BUILTIN(JavascriptError, NewWinRTErrorInstance, NewWinRTErrorInstance, FunctionInfo::None)
-#endif
 BUILTIN(JavascriptError, ToString, EntryToString, FunctionInfo::ErrorOnNew | FunctionInfo::HasNoSideEffect)
 BUILTIN(JavascriptExternalFunction, ExternalFunctionThunk, ExternalFunctionThunk, FunctionInfo::None)
 BUILTIN(JavascriptExternalFunction, WrappedFunctionThunk, WrappedFunctionThunk, FunctionInfo::None)

+ 1 - 27
lib/Runtime/Library/JavascriptError.cpp

@@ -144,21 +144,6 @@ namespace Js
 
 #undef NEW_ERROR
 
-#ifdef ENABLE_PROJECTION
-    Var JavascriptError::NewWinRTErrorInstance(RecyclableObject* function, CallInfo callInfo, ...)
-    {
-        PROBE_STACK(function->GetScriptContext(), Js::Constants::MinStackDefault);
-
-        ARGUMENTS(args, callInfo);
-        ScriptContext* scriptContext = function->GetScriptContext();
-        JavascriptError* pError = scriptContext->GetHostScriptContext()->CreateWinRTError(nullptr, nullptr);
-
-        Var newTarget = args.GetNewTarget();
-        Var message = args.Info.Count > 1 ? args[1] : scriptContext->GetLibrary()->GetUndefined();
-        return JavascriptError::NewInstance(function, pError, callInfo, newTarget, message);
-    }
-#endif
-
     Var JavascriptError::EntryToString(RecyclableObject* function, CallInfo callInfo, ...)
     {
         PROBE_STACK(function->GetScriptContext(), Js::Constants::MinStackDefault);
@@ -766,18 +751,7 @@ namespace Js
             ? Js::JavascriptError::GetRuntimeError(Js::VarTo<Js::RecyclableObject>(errorObject), nullptr)
             : S_OK;
 
-        return JavascriptError::GetErrorNumberFromResourceID(JSERR_UndefVariable) != (int32)hr
-#ifdef ENABLE_PROJECTION
-            // WinRT projected objects can return TYPE_E_ELEMENTNOTFOUND for missing properties
-            // which is not the same code as JSERR_UndefVariable. However, the meaning of the
-            // two error codes is morally equivalent in typeof scenario. Special case this here
-            // because we do not want typeof to leak these exceptions.
-            && !(errorObject != nullptr
-                && Js::VarIs<Js::JavascriptError>(errorObject)
-                && Js::VarTo<Js::JavascriptError>(errorObject)->GetErrorType() == kjstWinRTError
-                && hr == TYPE_E_ELEMENTNOTFOUND)
-#endif
-            ;
+        return JavascriptError::GetErrorNumberFromResourceID(JSERR_UndefVariable) != (int32)hr;
     }
 
     // Gets the error number associated with the resource ID for an error message.

+ 0 - 6
lib/Runtime/Library/JavascriptError.h

@@ -55,9 +55,6 @@ namespace Js
             static FunctionInfo NewWebAssemblyCompileErrorInstance;
             static FunctionInfo NewWebAssemblyRuntimeErrorInstance;
             static FunctionInfo NewWebAssemblyLinkErrorInstance;
-#ifdef ENABLE_PROJECTION
-            static FunctionInfo NewWinRTErrorInstance;
-#endif
             static FunctionInfo ToString;
         };
 
@@ -71,9 +68,6 @@ namespace Js
         static Var NewWebAssemblyCompileErrorInstance(RecyclableObject* function, CallInfo callInfo, ...);
         static Var NewWebAssemblyRuntimeErrorInstance(RecyclableObject* function, CallInfo callInfo, ...);
         static Var NewWebAssemblyLinkErrorInstance(RecyclableObject* function, CallInfo callInfo, ...);
-#ifdef ENABLE_PROJECTION
-        static Var NewWinRTErrorInstance(RecyclableObject* function, CallInfo callInfo, ...);
-#endif
 
         static Var EntryToString(RecyclableObject* function, CallInfo callInfo, ...);
 

+ 3 - 17
lib/Runtime/Library/JavascriptLibrary.cpp

@@ -1477,15 +1477,7 @@ namespace Js
         AddFunctionToLibraryObject(globalObject, PropertyIds::escape, &GlobalObject::EntryInfo::Escape, 1);
         AddFunctionToLibraryObject(globalObject, PropertyIds::unescape, &GlobalObject::EntryInfo::UnEscape, 1);
 
-// for backward compat reasons in non-core builds add CollectGarbage function even if it would do nothing later
-#ifdef _CHAKRACOREBUILD
-        if (scriptContext->GetConfig()->IsCollectGarbageEnabled()
-#ifdef ENABLE_PROJECTION
-            || scriptContext->GetConfig()->GetHostType() == HostType::HostTypeApplication
-            || scriptContext->GetConfig()->GetHostType() == HostType::HostTypeWebview
-#endif
-            )
-#endif
+        if (scriptContext->GetConfig()->IsCollectGarbageEnabled())
         {
             AddFunctionToLibraryObject(globalObject, PropertyIds::CollectGarbage, &GlobalObject::EntryInfo::CollectGarbage, 0);
         }
@@ -1688,7 +1680,7 @@ namespace Js
         }
 #endif
 
-#if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_JS_BUILTINS) || defined(ENABLE_PROJECTION)
+#if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_JS_BUILTINS)
         engineInterfaceObject = EngineInterfaceObject::New(recycler,
             DynamicType::New(scriptContext, TypeIds_EngineInterfaceObject, nullValue, nullptr,
             DeferredTypeHandler<InitializeEngineInterfaceObject>::GetDefaultInstance()));
@@ -5033,7 +5025,7 @@ namespace Js
         return jsonStringifyFunction;
     }
 
-#if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_JS_BUILTINS) || defined(ENABLE_PROJECTION)
+#if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_JS_BUILTINS)
     bool JavascriptLibrary::InitializeEngineInterfaceObject(DynamicObject* engineInterface, DeferredTypeHandlerBase * typeHandler, DeferredInitializeMode mode)
     {
         typeHandler->Convert(engineInterface, mode, 3);
@@ -7462,12 +7454,6 @@ namespace Js
         REGISTER_ERROR_OBJECT(TypeError);
         REGISTER_ERROR_OBJECT(URIError);
 
-#ifdef ENABLE_PROJECTION
-        if (config.IsWinRTEnabled())
-        {
-            REGISTER_ERROR_OBJECT(WinRTError);
-        }
-#endif
         return hr;
     }
 

+ 0 - 17
lib/Runtime/Library/JavascriptLibrary.h

@@ -18,19 +18,10 @@ CompileAssert(MaxPreInitializedObjectTypeInlineSlotCount <= USHRT_MAX);
 
 class ScriptSite;
 class ActiveScriptExternalLibrary;
-class ProjectionExternalLibrary;
 class EditAndContinue;
 class ChakraHostScriptContext;
 class JsrtExternalType;
 
-#ifdef ENABLE_PROJECTION
-namespace Projection
-{
-    class ProjectionContext;
-    class WinRTPromiseEngineInterfaceExtensionObject;
-}
-#endif
-
 namespace Js
 {
     class RefCountedBuffer;
@@ -178,11 +169,6 @@ namespace Js
         friend class JsBuiltInEngineInterfaceExtensionObject;
 #endif
         friend class ChakraHostScriptContext;
-#ifdef ENABLE_PROJECTION
-        friend class ProjectionExternalLibrary;
-        friend class Projection::WinRTPromiseEngineInterfaceExtensionObject;
-        friend class Projection::ProjectionContext;
-#endif
         static const char16* domBuiltinPropertyNames[];
 
     public:
@@ -1301,9 +1287,6 @@ namespace Js
         static bool __cdecl InitializeIntlObject(DynamicObject* IntlEngineObject, DeferredTypeHandlerBase * typeHandler, DeferredInitializeMode mode);
 #endif
 
-#ifdef ENABLE_PROJECTION
-        void InitializeWinRTPromiseConstructor();
-#endif
         static bool __cdecl JavascriptLibrary::InitializeAsyncIteratorPrototype(DynamicObject* asyncIteratorPrototype, DeferredTypeHandlerBase * typeHandler, DeferredInitializeMode mode);
         static bool __cdecl InitializeIteratorPrototype(DynamicObject* iteratorPrototype, DeferredTypeHandlerBase * typeHandler, DeferredInitializeMode mode);
         static bool __cdecl InitializeArrayIteratorPrototype(DynamicObject* arrayIteratorPrototype, DeferredTypeHandlerBase * typeHandler, DeferredInitializeMode mode);

+ 2 - 2
lib/Runtime/Library/JavascriptLibraryBase.h

@@ -104,7 +104,7 @@ namespace Js
 #ifdef ENABLE_INTL_OBJECT
         DynamicObject* GetIntlObject() { return IntlObject; }
 #endif
-#if defined(ENABLE_INTL_OBJECT)  || defined(ENABLE_JS_BUILTINS) || defined(ENABLE_PROJECTION)
+#if defined(ENABLE_INTL_OBJECT)  || defined(ENABLE_JS_BUILTINS)
         EngineInterfaceObject* GetEngineInterfaceObject() { return engineInterfaceObject; }
 #endif
 
@@ -225,7 +225,7 @@ namespace Js
 #ifdef ENABLE_INTL_OBJECT
         Field(DynamicObject*) IntlObject;
 #endif
-#if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_JS_BUILTINS)  || defined(ENABLE_PROJECTION)
+#if defined(ENABLE_INTL_OBJECT) || defined(ENABLE_JS_BUILTINS)
         Field(EngineInterfaceObject*) engineInterfaceObject;
 #endif
         Field(DynamicObject*) reflectObject;

+ 2 - 29
lib/Runtime/Library/TypedArray.cpp

@@ -328,35 +328,8 @@ namespace Js
                         Js::Throw::FatalInternalError();
                     }
 
-                    ArrayBuffer *temp = nullptr;
-                    HRESULT hr = scriptContext->GetHostScriptContext()->ArrayBufferFromExternalObject(jsArraySource, &temp);
-                    arrayBuffer = static_cast<ArrayBufferBase *> (temp);
-                    switch (hr)
-                    {
-                    case S_OK:
-                        // We found an IBuffer
-                        fromExternalObject = true;
-                        OUTPUT_TRACE(TypedArrayPhase, _u("Projection ArrayBuffer query succeeded with HR=0x%08X\n"), hr);
-                        // We have an ArrayBuffer now, so we can skip all the object probing.
-                        break;
-
-                    case S_FALSE:
-                        // We didn't find an IBuffer - fall through
-                        OUTPUT_TRACE(TypedArrayPhase, _u("Projection ArrayBuffer query aborted safely with HR=0x%08X (non-handled type)\n"), hr);
-                        break;
-
-                    default:
-                        // Any FAILURE HRESULT or unexpected HRESULT
-                        OUTPUT_TRACE(TypedArrayPhase, _u("Projection ArrayBuffer query failed with HR=0x%08X\n"), hr);
-                        JavascriptError::ThrowTypeError(scriptContext, JSERR_InvalidTypedArray_Constructor);
-                        break;
-                    }
-
-                    if (!fromExternalObject)
-                    {
-                        Var lengthVar = JavascriptOperators::OP_GetLength(jsArraySource, scriptContext);
-                        elementCount = ArrayBuffer::ToIndex(lengthVar, JSERR_InvalidTypedArrayLength, scriptContext, ArrayBuffer::MaxArrayBufferLength / elementSize);
-                    }
+                    Var lengthVar = JavascriptOperators::OP_GetLength(jsArraySource, scriptContext);
+                    elementCount = ArrayBuffer::ToIndex(lengthVar, JSERR_InvalidTypedArrayLength, scriptContext, ArrayBuffer::MaxArrayBufferLength / elementSize);
                 }
             }
         }

+ 1 - 84
test/Closures/copy-prop-stack-slot-test-framework.js

@@ -177,17 +177,6 @@
             throw new Error("[runWow64] Failed to retrieve environment variable. " + e.Message);
         }
     }
-    
-    //Get the host of script engine
-    Utils.WWAHOST = "WWA";
-    Utils.IEHOST = "Internet Explorer";
-    Utils.getHOSTType = function () {
-        //navigator.appName will return the host name, e.g. "WWAHost/1.0" or "Microsoft Internet Explorer" 
-        if (typeof navigator != 'undefined' && navigator.appName.indexOf(this.WWAHOST) >= 0) {
-            return this.WWAHOST;
-        }
-        return this.IEHOST;
-    }
 
     //Get localized error message
     Utils.getLocalizedError = function (ID, _default, substitution) {
@@ -301,11 +290,6 @@
 
         this.end = function () {
             loggerObj.CloseLogDevice("", logHandle);
-            //If we're running WTTLogger in a IE environment, we are probably running tests in wwahost,
-            //so we should close the window after we finish in order to write logs and rollup. The timeout
-            //is to ensure the rest of glue shutdown happens
-            //if(typeof document !== "undefined" && Utils.getHOSTType() == Utils.WWAHOST)
-            //    setTimeout(function() { window.close(); }, wwahostTimeout);
         }
 
         this.comment = function (str) {
@@ -807,11 +791,6 @@
         var verifications = [];
         var verbose = false;
 
-        // Initialize the projection related stuff in JsHost
-        if (Utils.getHOSTType() == Utils.WWAHOST) {
-            WScript.InitializeProjection();
-        }
-
         this.start = function (filename, priority) {
             if (!verbose) { 
                 return;
@@ -2116,7 +2095,6 @@
     var CrossContextTest = function () {
         var cct = this;
         cct.testIframe = true;
-        cct.testWindow = (Utils.getHOSTType() == Utils.WWAHOST) ? false : true;
 
         var waitingForReady = false;
         var readyCallbacks = [];
@@ -2183,7 +2161,7 @@
         *   Append html, head, body and script content to iframe/popup window
         */
 
-        function AppendChildHtml(doc) {
+        function writeChildContent(doc) {
 
             function createChildTag(tagName, attributes) {
                 tag = doc.createElement(tagName);
@@ -2235,62 +2213,6 @@
             head.appendChild(script);
         }
 
-        /* 
-        * Writes html content to doc. Used for IE
-        * * parentWindow, that refers to either window.parent or window.opener, depending on if this is a
-        *   popup window or an iframe, 
-        */
-
-        function WriteChildHtml(doc) {
-            doc.open();
-            doc.write("<html>\n<head>\n");
-            doc.write("<meta http-equiv=\"X-UA-Compatible\" content=\"IE=" + document.documentMode + "\" />\n");
-            doc.write("<scri" + "pt type='text/javascript'>\n");
-            doc.write("var parentWindow = window.parent == window ? window.opener : window.parent;\n");
-
-            //// function waitForReady will sent to child, to determin if child is ready
-            function waitForReady() {
-                if (document.addEventListener) {
-                    document.addEventListener("DOMContentLoaded", whenDomReady, false);
-                } else {
-                    setTimeout(waitForDomReady, 1);
-                }
-                function waitForDomReady() {
-                    // Otherwise use the oft-used doScroll hack which, according to MSDN, will always thrown an
-                    // error unless the document is ready.
-                    try {
-                        document.documentElement.doScroll("left");
-                    }
-                    catch (e) {
-                        // We're not ready yet. Check again in a bit.
-                        setTimeout(waitForDomReady, 1);
-                        return;
-                    }
-                    whenDomReady();
-                }
-                function whenDomReady() {
-                    parentWindow.childReady.ready();
-                }
-            }
-            //////
-
-            doc.write(waitForReady.toString() + "\n");
-            doc.write("waitForReady();\n");
-
-            for (var i = 0; i < childFunctions.length; i++) {
-                doc.write(childFunctions[i].toString() + "\n");
-            }
-
-            doc.write("</scr" + "ipt>\n</head>\n<body>\n");
-
-            if (cct.childContent !== undefined) doc.write(cct.childContent)
-
-            doc.write("</body></html>");
-            doc.close();
-        }
-
-        var writeChildContent = (Utils.getHOSTType() == Utils.WWAHOST) ? AppendChildHtml : WriteChildHtml;
-
         // Set either of these to control the content of the child windows.
         this.childContent = undefined;
 
@@ -2411,11 +2333,6 @@
 
                 cct.callback = callback;
 
-                if (cct.testWindow) {
-                    // Test with window.open
-                    scheduler.prepend([preparePopWin, runPopWin, cleanupPopWin]);
-                }
-
                 if (cct.testIframe) {
                     // Test with iframe.    
                     scheduler.prepend([prepareIframe, runIframe, cleanupIframe]);

+ 0 - 14
test/es6/weakmap_functionality.js

@@ -439,20 +439,6 @@ var tests = [
             var n = new Number(1);
             var b = new Boolean(2);
             var s = new String("Hi");
-
-            /*
-               Fast DOM and HostDispatch objects are tested in the mshtml test weakmap_DOMkey.html
-               WinRT objects are still an open issue; they are CustomExternalObjects so they work,
-               but they are proxied and the proxies are not kept alive by the outside object, only
-               by internal JS references.  Further, allowing objects to be linked to the lifetime
-               of a WinJS object can cause cycles between JS GC objects and WinRT COM ref counted
-               objects, which are not deducible by the GC.  Therefore using WinRT objects with
-               WeakMap is prone to subtle easy to make memory leak bugs.
-            var fd = new FastDOM();
-            var hd = new HostDispatch();
-            var wrt = new WinRT();
-            */
-
             var ab = new ArrayBuffer(32);
 
             weakmap.set(n, 1);

+ 0 - 14
test/es6/weakset_functionality.js

@@ -400,20 +400,6 @@ var tests = [
             var n = new Number(1);
             var b = new Boolean(2);
             var s = new String("Hi");
-
-            /*
-               Fast DOM and HostDispatch objects are tested in the mshtml test weakset_DOMkey.html
-               WinRT objects are still an open issue; they are CustomExternalObjects so they work,
-               but they are proxied and the proxies are not kept alive by the outside object, only
-               by internal JS references.  Further, allowing objects to be linked to the lifetime
-               of a WinJS object can cause cycles between JS GC objects and WinRT COM ref counted
-               objects, which are not deducible by the GC.  Therefore using WinRT objects with
-               WeakSet is prone to subtle easy to make memory leak bugs.
-            var fd = new FastDOM();
-            var hd = new HostDispatch();
-            var wrt = new WinRT();
-            */
-
             var ab = new ArrayBuffer(32);
 
             weakset.add(n);