context: 
  #if CSHotFix
  using System;
  using System.Collections.Generic;
  using System.Reflection;
  using System.Runtime.InteropServices;
  
  using CSHotFix.CLR.TypeSystem;
  using CSHotFix.CLR.Method;
  using CSHotFix.Runtime.Enviorment;
  using CSHotFix.Runtime.Intepreter;
  using CSHotFix.Runtime.Stack;
  using CSHotFix.Reflection;
  using CSHotFix.CLR.Utils;
  using System.Linq;
  namespace CSHotFix.Runtime.Generated
  {
      unsafe class Unity_Jobs_JobHandle_Binding
      {
          public static void Register(CSHotFix.Runtime.Enviorment.AppDomain app)
          {
              BindingFlags flag = BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static | BindingFlags.DeclaredOnly;
              MethodBase method;
              Type[] args;
              Type type = typeof(Unity.Jobs.JobHandle);
              args = new Type[]{};
              method = type.GetMethod("Complete", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, Complete_0);
              args = new Type[]{typeof(Unity.Jobs.JobHandle).MakeByRefType(), typeof(Unity.Jobs.JobHandle).MakeByRefType()};
              method = type.GetMethod("CompleteAll", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, CompleteAll_1);
              args = new Type[]{typeof(Unity.Jobs.JobHandle).MakeByRefType(), typeof(Unity.Jobs.JobHandle).MakeByRefType(), typeof(Unity.Jobs.JobHandle).MakeByRefType()};
              method = type.GetMethod("CompleteAll", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, CompleteAll_2);
              args = new Type[]{typeof(Unity.Collections.NativeArray<Unity.Jobs.JobHandle>)};
              method = type.GetMethod("CompleteAll", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, CompleteAll_3);
              args = new Type[]{};
              method = type.GetMethod("get_IsCompleted", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, get_IsCompleted_4);
              args = new Type[]{};
              method = type.GetMethod("ScheduleBatchedJobs", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, ScheduleBatchedJobs_5);
              args = new Type[]{typeof(Unity.Jobs.JobHandle), typeof(Unity.Jobs.JobHandle)};
              method = type.GetMethod("CombineDependencies", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, CombineDependencies_6);
              args = new Type[]{typeof(Unity.Jobs.JobHandle), typeof(Unity.Jobs.JobHandle), typeof(Unity.Jobs.JobHandle)};
              method = type.GetMethod("CombineDependencies", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, CombineDependencies_7);
              args = new Type[]{typeof(Unity.Collections.NativeArray<Unity.Jobs.JobHandle>)};
              method = type.GetMethod("CombineDependencies", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, CombineDependencies_8);
              args = new Type[]{typeof(Unity.Collections.NativeSlice<Unity.Jobs.JobHandle>)};
              method = type.GetMethod("CombineDependencies", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, CombineDependencies_9);
              args = new Type[]{typeof(Unity.Jobs.JobHandle), typeof(Unity.Jobs.JobHandle)};
              method = type.GetMethod("CheckFenceIsDependencyOrDidSyncFence", flag, null, args, null);
              app.RegisterCLRMethodRedirection(method, CheckFenceIsDependencyOrDidSyncFence_10);
  
  
              app.RegisterCLRMemberwiseClone(type, PerformMemberwiseClone);
  
              app.RegisterCLRCreateDefaultInstance(type, () => new Unity.Jobs.JobHandle());
              app.RegisterCLRCreateArrayInstance(type, s => new Unity.Jobs.JobHandle[s]);
  
  
          }
  
          static void WriteBackInstance(CSHotFix.Runtime.Enviorment.AppDomain __domain, StackObject* ptr_of_this_method, IList<object> __mStack, ref Unity.Jobs.JobHandle instance_of_this_method)
          {
              ptr_of_this_method = ILIntepreter.GetObjectAndResolveReference(ptr_of_this_method);
              switch(ptr_of_this_method->ObjectType)
              {
                  case ObjectTypes.Object:
                      {
                          __mStack[ptr_of_this_method->Value] = instance_of_this_method;
                      }
                      break;
                  case ObjectTypes.FieldReference:
                      {
                          var ___obj = __mStack[ptr_of_this_method->Value];
                          if(___obj is ILTypeInstance)
                          {
                              ((ILTypeInstance)___obj)[ptr_of_this_method->ValueLow] = instance_of_this_method;
                          }
                          else
                          {
                              var t = __domain.GetType(___obj.GetType()) as CLRType;
                              t.SetFieldValue(ptr_of_this_method->ValueLow, ref ___obj, instance_of_this_method);
                          }
                      }
                      break;
                  case ObjectTypes.StaticFieldReference:
                      {
                          var t = __domain.GetType(ptr_of_this_method->Value);
                          if(t is ILType)
                          {
                              ((ILType)t).StaticInstance[ptr_of_this_method->ValueLow] = instance_of_this_method;
                          }
                          else
                          {
                              ((CLRType)t).SetStaticFieldValue(ptr_of_this_method->ValueLow, instance_of_this_method);
                          }
                      }
                      break;
                   case ObjectTypes.ArrayReference:
                      {
                          var instance_of_arrayReference = __mStack[ptr_of_this_method->Value] as Unity.Jobs.JobHandle[];
                          instance_of_arrayReference[ptr_of_this_method->ValueLow] = instance_of_this_method;
                      }
                      break;
              }
          }
  
          static StackObject* Complete_0(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
          {
              CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
              StackObject* ptr_of_this_method;
              StackObject* __ret = ILIntepreter.Minus(__esp, 1);
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
              ptr_of_this_method = ILIntepreter.GetObjectAndResolveReference(ptr_of_this_method);
              Unity.Jobs.JobHandle instance_of_this_method = (Unity.Jobs.JobHandle)typeof(Unity.Jobs.JobHandle).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
  
              instance_of_this_method.Complete();
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
              WriteBackInstance(__domain, ptr_of_this_method, __mStack, ref instance_of_this_method);
  
              __intp.Free(ptr_of_this_method);
              return __ret;
          }
  
          static StackObject* CompleteAll_1(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
          {
              CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
              StackObject* ptr_of_this_method;
              StackObject* __ret = ILIntepreter.Minus(__esp, 2);
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
              Unity.Jobs.JobHandle @job1 = (Unity.Jobs.JobHandle)typeof(Unity.Jobs.JobHandle).CheckCLRTypes(__intp.RetriveObject(ptr_of_this_method, __mStack));
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
              Unity.Jobs.JobHandle @job0 = (Unity.Jobs.JobHandle)typeof(Unity.Jobs.JobHandle).CheckCLRTypes(__intp.RetriveObject(ptr_of_this_method, __mStack));
  
  
              Unity.Jobs.JobHandle.CompleteAll(ref @job0, ref @job1);
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
              switch(ptr_of_this_method->ObjectType)
              {
                  case ObjectTypes.StackObjectReference:
                      {
                          var ___dst = *(StackObject**)&ptr_of_this_method->Value;
                          object ___obj = @job1;
                          if (___dst->ObjectType >= ObjectTypes.Object)
                          {
                              if (___obj is CrossBindingAdaptorType)
                                  ___obj = ((CrossBindingAdaptorType)___obj).ILInstance;
                              __mStack[___dst->Value] = ___obj;
                          }
                          else
                          {
                              ILIntepreter.UnboxObject(___dst, ___obj, __mStack, __domain);
                          }
                      }
                      break;
                  case ObjectTypes.FieldReference:
                      {
                          var ___obj = __mStack[ptr_of_this_method->Value];
                          if(___obj is ILTypeInstance)
                          {
                              ((ILTypeInstance)___obj)[ptr_of_this_method->ValueLow] = @job1;
                          }
                          else
                          {
                              var ___type = __domain.GetType(___obj.GetType()) as CLRType;
                              ___type.SetFieldValue(ptr_of_this_method->ValueLow, ref ___obj, @job1);
                          }
                      }
                      break;
                  case ObjectTypes.StaticFieldReference:
                      {
                          var ___type = __domain.GetType(ptr_of_this_method->Value);
                          if(___type is ILType)
                          {
                              ((ILType)___type).StaticInstance[ptr_of_this_method->ValueLow] = @job1;
                          }
                          else
                          {
                              ((CLRType)___type).SetStaticFieldValue(ptr_of_this_method->ValueLow, @job1);
                          }
                      }
                      break;
                   case ObjectTypes.ArrayReference:
                      {
                          var instance_of_arrayReference = __mStack[ptr_of_this_method->Value] as Unity.Jobs.JobHandle[];
                          instance_of_arrayReference[ptr_of_this_method->ValueLow] = @job1;
                      }
                      break;
              }
  
              __intp.Free(ptr_of_this_method);
              ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
              switch(ptr_of_this_method->ObjectType)
              {
                  case ObjectTypes.StackObjectReference:
                      {
                          var ___dst = *(StackObject**)&ptr_of_this_method->Value;
                          object ___obj = @job0;
                          if (___dst->ObjectType >= ObjectTypes.Object)
                          {
                              if (___obj is CrossBindingAdaptorType)
                                  ___obj = ((CrossBindingAdaptorType)___obj).ILInstance;
                              __mStack[___dst->Value] = ___obj;
                          }
                          else
                          {
                              ILIntepreter.UnboxObject(___dst, ___obj, __mStack, __domain);
                          }
                      }
                      break;
                  case ObjectTypes.FieldReference:
                      {
                          var ___obj = __mStack[ptr_of_this_method->Value];
                          if(___obj is ILTypeInstance)
                          {
                              ((ILTypeInstance)___obj)[ptr_of_this_method->ValueLow] = @job0;
                          }
                          else
                          {
                              var ___type = __domain.GetType(___obj.GetType()) as CLRType;
                              ___type.SetFieldValue(ptr_of_this_method->ValueLow, ref ___obj, @job0);
                          }
                      }
                      break;
                  case ObjectTypes.StaticFieldReference:
                      {
                          var ___type = __domain.GetType(ptr_of_this_method->Value);
                          if(___type is ILType)
                          {
                              ((ILType)___type).StaticInstance[ptr_of_this_method->ValueLow] = @job0;
                          }
                          else
                          {
                              ((CLRType)___type).SetStaticFieldValue(ptr_of_this_method->ValueLow, @job0);
                          }
                      }
                      break;
                   case ObjectTypes.ArrayReference:
                      {
                          var instance_of_arrayReference = __mStack[ptr_of_this_method->Value] as Unity.Jobs.JobHandle[];
                          instance_of_arrayReference[ptr_of_this_method->ValueLow] = @job0;
                      }
                      break;
              }
  
              __intp.Free(ptr_of_this_method);
              return __ret;
          }
  
          static StackObject* CompleteAll_2(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
          {
              CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
              StackObject* ptr_of_this_method;
              StackObject* __ret = ILIntepreter.Minus(__esp, 3);
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
              Unity.Jobs.JobHandle @job2 = (Unity.Jobs.JobHandle)typeof(Unity.Jobs.JobHandle).CheckCLRTypes(__intp.RetriveObject(ptr_of_this_method, __mStack));
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
              Unity.Jobs.JobHandle @job1 = (Unity.Jobs.JobHandle)typeof(Unity.Jobs.JobHandle).CheckCLRTypes(__intp.RetriveObject(ptr_of_this_method, __mStack));
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 3);
              Unity.Jobs.JobHandle @job0 = (Unity.Jobs.JobHandle)typeof(Unity.Jobs.JobHandle).CheckCLRTypes(__intp.RetriveObject(ptr_of_this_method, __mStack));
  
  
              Unity.Jobs.JobHandle.CompleteAll(ref @job0, ref @job1, ref @job2);
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
              switch(ptr_of_this_method->ObjectType)
              {
                  case ObjectTypes.StackObjectReference:
                      {
                          var ___dst = *(StackObject**)&ptr_of_this_method->Value;
                          object ___obj = @job2;
                          if (___dst->ObjectType >= ObjectTypes.Object)
                          {
                              if (___obj is CrossBindingAdaptorType)
                                  ___obj = ((CrossBindingAdaptorType)___obj).ILInstance;
                              __mStack[___dst->Value] = ___obj;
                          }
                          else
                          {
                              ILIntepreter.UnboxObject(___dst, ___obj, __mStack, __domain);
                          }
                      }
                      break;
                  case ObjectTypes.FieldReference:
                      {
                          var ___obj = __mStack[ptr_of_this_method->Value];
                          if(___obj is ILTypeInstance)
                          {
                              ((ILTypeInstance)___obj)[ptr_of_this_method->ValueLow] = @job2;
                          }
                          else
                          {
                              var ___type = __domain.GetType(___obj.GetType()) as CLRType;
                              ___type.SetFieldValue(ptr_of_this_method->ValueLow, ref ___obj, @job2);
                          }
                      }
                      break;
                  case ObjectTypes.StaticFieldReference:
                      {
                          var ___type = __domain.GetType(ptr_of_this_method->Value);
                          if(___type is ILType)
                          {
                              ((ILType)___type).StaticInstance[ptr_of_this_method->ValueLow] = @job2;
                          }
                          else
                          {
                              ((CLRType)___type).SetStaticFieldValue(ptr_of_this_method->ValueLow, @job2);
                          }
                      }
                      break;
                   case ObjectTypes.ArrayReference:
                      {
                          var instance_of_arrayReference = __mStack[ptr_of_this_method->Value] as Unity.Jobs.JobHandle[];
                          instance_of_arrayReference[ptr_of_this_method->ValueLow] = @job2;
                      }
                      break;
              }
  
              __intp.Free(ptr_of_this_method);
              ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
              switch(ptr_of_this_method->ObjectType)
              {
                  case ObjectTypes.StackObjectReference:
                      {
                          var ___dst = *(StackObject**)&ptr_of_this_method->Value;
                          object ___obj = @job1;
                          if (___dst->ObjectType >= ObjectTypes.Object)
                          {
                              if (___obj is CrossBindingAdaptorType)
                                  ___obj = ((CrossBindingAdaptorType)___obj).ILInstance;
                              __mStack[___dst->Value] = ___obj;
                          }
                          else
                          {
                              ILIntepreter.UnboxObject(___dst, ___obj, __mStack, __domain);
                          }
                      }
                      break;
                  case ObjectTypes.FieldReference:
                      {
                          var ___obj = __mStack[ptr_of_this_method->Value];
                          if(___obj is ILTypeInstance)
                          {
                              ((ILTypeInstance)___obj)[ptr_of_this_method->ValueLow] = @job1;
                          }
                          else
                          {
                              var ___type = __domain.GetType(___obj.GetType()) as CLRType;
                              ___type.SetFieldValue(ptr_of_this_method->ValueLow, ref ___obj, @job1);
                          }
                      }
                      break;
                  case ObjectTypes.StaticFieldReference:
                      {
                          var ___type = __domain.GetType(ptr_of_this_method->Value);
                          if(___type is ILType)
                          {
                              ((ILType)___type).StaticInstance[ptr_of_this_method->ValueLow] = @job1;
                          }
                          else
                          {
                              ((CLRType)___type).SetStaticFieldValue(ptr_of_this_method->ValueLow, @job1);
                          }
                      }
                      break;
                   case ObjectTypes.ArrayReference:
                      {
                          var instance_of_arrayReference = __mStack[ptr_of_this_method->Value] as Unity.Jobs.JobHandle[];
                          instance_of_arrayReference[ptr_of_this_method->ValueLow] = @job1;
                      }
                      break;
              }
  
              __intp.Free(ptr_of_this_method);
              ptr_of_this_method = ILIntepreter.Minus(__esp, 3);
              switch(ptr_of_this_method->ObjectType)
              {
                  case ObjectTypes.StackObjectReference:
                      {
                          var ___dst = *(StackObject**)&ptr_of_this_method->Value;
                          object ___obj = @job0;
                          if (___dst->ObjectType >= ObjectTypes.Object)
                          {
                              if (___obj is CrossBindingAdaptorType)
                                  ___obj = ((CrossBindingAdaptorType)___obj).ILInstance;
                              __mStack[___dst->Value] = ___obj;
                          }
                          else
                          {
                              ILIntepreter.UnboxObject(___dst, ___obj, __mStack, __domain);
                          }
                      }
                      break;
                  case ObjectTypes.FieldReference:
                      {
                          var ___obj = __mStack[ptr_of_this_method->Value];
                          if(___obj is ILTypeInstance)
                          {
                              ((ILTypeInstance)___obj)[ptr_of_this_method->ValueLow] = @job0;
                          }
                          else
                          {
                              var ___type = __domain.GetType(___obj.GetType()) as CLRType;
                              ___type.SetFieldValue(ptr_of_this_method->ValueLow, ref ___obj, @job0);
                          }
                      }
                      break;
                  case ObjectTypes.StaticFieldReference:
                      {
                          var ___type = __domain.GetType(ptr_of_this_method->Value);
                          if(___type is ILType)
                          {
                              ((ILType)___type).StaticInstance[ptr_of_this_method->ValueLow] = @job0;
                          }
                          else
                          {
                              ((CLRType)___type).SetStaticFieldValue(ptr_of_this_method->ValueLow, @job0);
                          }
                      }
                      break;
                   case ObjectTypes.ArrayReference:
                      {
                          var instance_of_arrayReference = __mStack[ptr_of_this_method->Value] as Unity.Jobs.JobHandle[];
                          instance_of_arrayReference[ptr_of_this_method->ValueLow] = @job0;
                      }
                      break;
              }
  
              __intp.Free(ptr_of_this_method);
              return __ret;
          }
  
          static StackObject* CompleteAll_3(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
          {
              CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
              StackObject* ptr_of_this_method;
              StackObject* __ret = ILIntepreter.Minus(__esp, 1);
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
              Unity.Collections.NativeArray<Unity.Jobs.JobHandle> @jobs = (Unity.Collections.NativeArray<Unity.Jobs.JobHandle>)typeof(Unity.Collections.NativeArray<Unity.Jobs.JobHandle>).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
              __intp.Free(ptr_of_this_method);
  
  
              Unity.Jobs.JobHandle.CompleteAll(@jobs);
  
              return __ret;
          }
  
          static StackObject* get_IsCompleted_4(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
          {
              CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
              StackObject* ptr_of_this_method;
              StackObject* __ret = ILIntepreter.Minus(__esp, 1);
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
              ptr_of_this_method = ILIntepreter.GetObjectAndResolveReference(ptr_of_this_method);
              Unity.Jobs.JobHandle instance_of_this_method = (Unity.Jobs.JobHandle)typeof(Unity.Jobs.JobHandle).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
  
              var result_of_this_method = instance_of_this_method.IsCompleted;
  
              ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
              WriteBackInstance(__domain, ptr_of_this_method, __mStack, ref instance_of_this_method);
  
              __intp.Free(ptr_of_this_method);
              __ret->ObjectType = ObjectTypes.Integer;
              __ret->Value = result_of_this_method ? 1 : 0;
              return __ret + 1;
          }
  
          static StackObject* ScheduleBatchedJobs_5(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
          {
              CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
              StackObject* __ret = ILIntepreter.Minus(__esp, 0);
  
  
              Unity.Jobs.JobHandle.ScheduleBatchedJobs();
  
              return __ret;
          }
  
          static StackObject* CombineDependencies_6(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
          {
              CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
              StackObject* ptr_of_this_method;
              StackObject* __ret = ILIntepreter.Minus(__esp, 2);
  
  
gt:             ptr_of_this_method = ILIntepreter.Minus(__esp, 1);