Public Tasks

Matthijs

Kudzu To Do

scanner issue: http://groups.yahoo.com/group/Cosmos-Dev/message/4789
debugstub.SkipMethod
SkipClass
speedup debug stub on no trigger
compiler dynamic load
unsafe arrays but controllled

Matthijs - Next Release

Trivalik - Next Release

 Next Release + 1

Even later

Further Down

Notes

Assembly Plug Example

Old way

(3 classes, often 3 source files as well)

public class CPUBus {
	// Plugged
	public static void Write8(UInt16 aPort, byte aData) { }
...

[Plug(Target = typeof(Cosmos.Kernel.CPUBus))]
class CPUBus { 
	[PlugMethod(Assembler = typeof(Assemblers.IOWrite8))]
	public static void Write8(UInt16 aPort, byte aData) { }
...

public sealed class IOWrite8: AssemblerMethod { 
	public override void AssembleNew(object aAssembler, object aMethodInfo) { 
		//TODO: This is a lot of work to write to a single port. We need to have some kind of inline ASM option that can emit a single out instruction 
		new CPUx86.Move { DestinationReg = CPUx86.Registers.EDX, SourceReg = CPUx86.Registers.EBP, SourceDisplacement = 0xC, SourceIsIndirect = true };
		new CPUx86.Move { DestinationReg = CPUx86.Registers.EAX, SourceReg = CPUx86.Registers.EBP, SourceDisplacement = 0x8, SourceIsIndirect = true };
		new CPUx86.Out { DestinationReg = CPUx86.Registers.AL }; 
	}
} 

New way

See how much neater and self contained this is? :)

public class CPUBus {
   
    [AsmBody(Assembler = typeof(IOWrite8))]
    public static void Write8(UInt16 aPort, byte aData) { }
    // Nested class even... :) Keeps it all in one unit!
    public class IOWrite8 : CodeBlock {
        public override void Assemble() {
            EDX = EBP + 0x0C;
            EAX = EBP + 0x08;
            Port[DX] = AL;
        }
    }

}