void ICompilationSchedulerStage.ScheduleMethodForCompilation(RuntimeMethod method) { if (method == null) throw new ArgumentNullException(@"method"); if (!method.IsGeneric) { Trace(CompilerEvent.SchedulingMethod, method.ToString()); methodQueue.Enqueue(method); } }
private void CompileMethod(RuntimeMethod method) { Trace(CompilerEvent.CompilingMethod, method.ToString()); using (IMethodCompiler mc = compiler.CreateMethodCompiler(this, method.DeclaringType, method)) { mc.Compile(); //try //{ // mc.Compile(); //} //catch (Exception e) //{ // HandleCompilationException(e); // throw; //} } }
/// <summary> /// Creates a symbol operand for the given method. /// </summary> /// <param name="method">The method to create a symbol operand for.</param> /// <returns>The created symbol operand.</returns> public static SymbolOperand FromMethod(RuntimeMethod method) { string symbolName = method.ToString(); return new SymbolOperand(BuiltInSigType.IntPtr, symbolName); }
private void Patch(RuntimeMethod targetMethod, RuntimeMethod method) { Trace(InternalTrace.CompilerEvent.Plug, targetMethod.ToString() + " with " + method.ToString()); plugMethods.Add(targetMethod, method); }