/opengles/src/codegen/todo.txt

http://ftk.googlecode.com/ · Plain Text · 44 lines · 31 code · 13 blank · 0 comment · 0 complexity · fefc68ff073d1aa7293e542491c6f42c MD5 · raw file

  1. Ideas on how to improve JIT:
  2. ----------------------------
  3. - Register targeting:
  4. Mainly for function calls: If next use of a register is for
  5. a function call, calcualte value directly into target register.
  6. Issue: Can this lead to premature and unnecessary stores?
  7. - Increase cache performance:
  8. Allocate actual storage offsets for registers only after we
  9. have identified, which different values actually need to be persisted.
  10. - Read only parameters are copy onto stack:
  11. Alternatives: Move all parameters onto stack, so we can use
  12. direct frame pointer access
  13. Or: Convert function to a method, and have a second pointer
  14. (this->ptr) available for
  15. direct adressing of parameter values.
  16. Or: Implement reference variables (could lead to cascaded
  17. load instructions in inner loops)
  18. - Remove stalls in execution pipeline:
  19. Register loads: Have cg_codegen_emit_simple_inst look for
  20. register values that need to/could be
  21. preloaded for following instruction. If those exist, and
  22. registers are available, emit
  23. pre-load instruction before actual instruction to be
  24. scheduled at this point. This will
  25. ensure that data will be available (given it resides in
  26. on-chip cache).
  27. Multiplications: Rewrite fixed point multiplies as
  28. instructions that can be scheduled individually
  29. Have general instruction scheduling on intermediate code:
  30. Assuming all data is available, just take instuction
  31. execution cycles and next use into consideration.