-
Notifications
You must be signed in to change notification settings - Fork 0
/
Todo
30 lines (30 loc) · 2.39 KB
/
Todo
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
- add arg passing in MethodInvoke where the first four args are also placed on the stack (find if this is required first)
- add methodinvoke for non win64 systems
- change some reinterpret casts in stdlib to normal casts
- add runtime member reordering for runtime inheritance once dynamic type generation is allowed (field reordering)
- dynamic generic type generation
- generic-in-generic type generation/support
- for this, have the compiler create a list of static generic-in-generics before LLIR in generic IR string
- have each nested generic assigned a type ident (which the compiler should have already used in its LLIR) and any appearances of `sizeof_TypeIdent` should be replaced with the size of the nested generic by the runtime
- prebuilt generic type loading
- array type deps loading from metadata - WILL NOT IMPL - array types can be created from InitAssembly
- have loader support all valid modifiers for different attributes
- add static ctor support - WILL NOT IMPL - decided that compilers should manage static ctors themselves
- remove switch case blocks in Loader that are always true or false
- Check MethodInfo::Invoke() on a method with more than 4 args
- If stack space needs to be alloced for the call, execute `sub rsp, 32+((nargs-4)*8)`
- add bytes back to rsp following the call
- Probably shouldn't need stack space, just check if it works
- Also check with large value type
- Update ConstructorInfo::Invoke() accordingly
- Finish JIT
- Fix GC to work with JIT assemblies (can you CONTEXT to get register values to also log as locals (or have JIT assemblies create a list of registers that are used for locals to log less))
- Add call capabilites to JIT
- Have ULD support reading JIT allocations & JIT interactions
- Add jmp instrs
- Attach vtable calls to method names somehow for jit compilation (e.g. create a mapping between name and number)
- TODO: pad all valuetypes to 8 bytes upon loading
- TODO: have JIT auto-create `this` as first arg for instance methods
- TODO: have JIT cache the postfill buffers so redundant ones are not allocated
- Another memory opt -- since we have to allocate full pages anyway, maybe try to fit multiple functions on one page
- NOTE: MethodInfo::Invoke and JIT are not compatible with return values case 2 [here](https://learn.microsoft.com/en-us/cpp/build/x64-calling-convention?view=msvc-170#example-of-return-value-2---128-bit-result) (probably won't fix)