private OpenCLKernelProfileRecord(NativeOpenCLKernelProfileRecord instance) { Name = instance.Name; Count = instance.Count; MaximumDuration = instance.MaximumDuration; MinimumDuration = instance.MinimumDuration; TotalDuration = instance.TotalDuration; }
internal static OpenCLKernelProfileRecord CreateInstance(IntPtr instance) { if (instance == IntPtr.Zero) return null; NativeOpenCLKernelProfileRecord nativeInstance = new NativeOpenCLKernelProfileRecord(); nativeInstance.Instance = instance; return new OpenCLKernelProfileRecord(nativeInstance); }
internal static OpenCLKernelProfileRecord?CreateInstance(IntPtr instance) { if (instance == IntPtr.Zero) { return(null); } NativeOpenCLKernelProfileRecord nativeInstance = new NativeOpenCLKernelProfileRecord(); nativeInstance.Instance = instance; return(new OpenCLKernelProfileRecord(nativeInstance)); }