Update TODO.md

This commit is contained in:
Ben Vanik 2013-01-22 10:50:20 -08:00
parent 0aaaac2a7a
commit 9dfcbee090
1 changed files with 27 additions and 1 deletions

28
TODO.md
View File

@ -1,4 +1,3 @@
## Instructions
```
@ -36,11 +35,38 @@ twi
## Codegen
### Tracing
Tracing modes:
- off (0)
- syscalls (1)
- fn calls (2)
- all instructions (3)
Inject extern functions into module:
- XeTraceKernelCall(caller_ia, cia, name, state)
- XeTraceUserCall(caller_ia, cia, name, state)
- XeTraceInstruction(cia, name, state)
### Calling convention
Experiment with fastcc? May need typedef fn ptrs to call into the JITted code.
### Indirect branches (ctr/lr)
emit_control.cc XeEmitBranchTo
Need to take the value in LR/CTR and do something with it.
Return path:
- In SDB see if the function follows the 'return' semantic:
- mfspr LR / mtspr LR/CTR / bcctr -- at end?
- In codegen add a BB that is just return.
- If a block 'returns', branch to the return BB.
Tail calls:
- If in a call BB check next BB.
- If next is a return, optimize to a tail call.
Fast path:
- Every time LR would be stashed, add the value of LR (some NIA) to a lookup
table.