ChakraCoreWindows.h 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. //-------------------------------------------------------------------------------------------------------
  2. // Copyright (C) Microsoft. All rights reserved.
  3. // Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
  4. //-------------------------------------------------------------------------------------------------------
  5. #ifdef _MSC_VER
  6. #pragma once
  7. #endif // _MSC_VER
  8. #ifndef _CHAKRACOREWINDOWS_H_
  9. #define _CHAKRACOREWINDOWS_H_
  10. #include <rpc.h>
  11. /// <summary>
  12. /// Globally enables out-of-process JIT.
  13. /// </summary>
  14. /// <remarks>
  15. /// Should be called before JS code is executed.
  16. /// Code in all runtimes will run in interpreter until JsConnectJITProcess is called.
  17. /// </remarks>
  18. /// <returns>
  19. /// The code <c>JsNoError</c> if the operation succeeded, a failure code otherwise.
  20. /// </returns>
  21. CHAKRA_API
  22. JsEnableOOPJIT();
  23. /// <summary>
  24. /// Globally enables out-of-process JIT and connects to a Chakra JIT process that was initialized
  25. /// by calling JsInitializeJITServer
  26. /// </summary>
  27. /// <remarks>
  28. /// Out-of-process JIT should be enabled before JS code is executed.
  29. /// </remarks>
  30. /// <param name="processHandle">Handle to the JIT process</param>
  31. /// <param name="serverSecurityDescriptor">Optional pointer to an RPC SECURITY_DESCRIPTOR structure</param>
  32. /// <param name="connectionId">Same UUID that was passed to JsInitializeJITServer</param>
  33. /// <returns>
  34. /// The code <c>JsNoError</c> if the operation succeeded, a failure code otherwise.
  35. /// </returns>
  36. CHAKRA_API
  37. JsConnectJITProcess(_In_ HANDLE processHandle, _In_opt_ void* serverSecurityDescriptor, _In_ UUID connectionId);
  38. #endif // _CHAKRACOREWINDOWS_H_