public static LLVMTypeRef WakerType(this ContextWrapper context) => context.StructType( new LLVMTypeRef[] { // task function pointer LLVMTypeRef.PointerType(context.ScheduledTaskFunctionType(), 0u), // task state context.VoidPointerType() });
private static LLVMTypeRef MethodPollFunctionType(this ContextWrapper context) => LLVMTypeRef.FunctionType( context.VoidType, new LLVMTypeRef[] { context.VoidPointerType(), LLVMTypeRef.PointerType(context.ScheduledTaskFunctionType(), 0u), context.VoidPointerType() }, false);
public static LLVMTypeRef PollFunctionType(ContextWrapper context) => LLVMTypeRef.FunctionType( context.VoidType, new LLVMTypeRef[] { context.VoidPointerType(), LLVMTypeRef.PointerType(context.ScheduledTaskFunctionType(), 0u), context.VoidPointerType() }, false);
public static LLVMTypeRef GetScheduledTaskType(this ContextWrapper context) { return(context.GetCachedStructType("scheduled_task", () => new[] { // task function pointer LLVMTypeRef.PointerType(context.ScheduledTaskFunctionType(), 0u), // task state context.VoidPointerType() })); }