mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-06 07:38:48 +00:00
Cleanup root directory
This commit is contained in:
+2
-4
@@ -252,7 +252,5 @@ paket-files/
|
|||||||
|
|
||||||
# Project Specific
|
# Project Specific
|
||||||
*.sln
|
*.sln
|
||||||
!misc/llvm-bim/lli.exe
|
builds/
|
||||||
!misc/llvm-bim/opt.exe
|
bin/
|
||||||
builds
|
|
||||||
bin
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<img src="logo-slim.png" alt="Odin logo" height="74">
|
<img src="misc/logo-slim.png" alt="Odin logo" height="74">
|
||||||
|
|
||||||
# The Odin Programming Language
|
# The Odin Programming Language
|
||||||
|
|
||||||
|
|||||||
@@ -1,55 +0,0 @@
|
|||||||
# Compile Time Execution Problems (Metaprogramming)
|
|
||||||
2016-11-02
|
|
||||||
|
|
||||||
## Memory and Types
|
|
||||||
|
|
||||||
Compile time execution (CTE) is a stage of the compiler which runs any Odin code the
|
|
||||||
user requests before the creation of the executable. The data modified and generated
|
|
||||||
by this stage will be used as the initialization data for the _compiled_ code.
|
|
||||||
|
|
||||||
The CTE stage is an interpreter running the generated _single static assignment_ (SSA)
|
|
||||||
tree for the requested code. When using the memory generated by the interpreter for the
|
|
||||||
compiled code, there are a few problems. The main problem being: pointers will point
|
|
||||||
to invalid memory addresses. This is becaused the memory space of the interpreter is
|
|
||||||
completely different to the memory space of the executable (compiled code).
|
|
||||||
|
|
||||||
The table below presents which data types are safe for transferal and which are not.
|
|
||||||
|
|
||||||
Key:
|
|
||||||
|
|
||||||
* Y - Yes
|
|
||||||
* N - No
|
|
||||||
* D - Dependent on elements
|
|
||||||
* ? - Highly depends on a lot of factors (most likely no)
|
|
||||||
|
|
||||||
| Type | Safe? |
|
|
||||||
|-----------|------------------------------------------------------------------------|
|
|
||||||
| boolean | Y |
|
|
||||||
| integer | Y |
|
|
||||||
| float | Y |
|
|
||||||
| pointer | N - Maybe safe if never changed |
|
|
||||||
| string | Y - Even though (ptr+int) interally, still safe to convert to constant |
|
|
||||||
| any | N - (ptr+ptr) |
|
|
||||||
| array | D |
|
|
||||||
| vector | Y - Elements can only be boolean, integer, or float (thus safe) |
|
|
||||||
| slice | N - Internally (ptr+int+int) |
|
|
||||||
| maybe | D |
|
|
||||||
| struct | D |
|
|
||||||
| enum | Y |
|
|
||||||
| union | N - (blob+int) |
|
|
||||||
| raw_union | N - ^^^ |
|
|
||||||
| tuple | D |
|
|
||||||
| proc | ? - Need to solve the next problem |
|
|
||||||
|
|
||||||
|
|
||||||
## Calling procedures (external and internal)
|
|
||||||
|
|
||||||
If all the procedures are only from within the code itself, i.e. not a loaded pointer,
|
|
||||||
then it is "safe". However, calling external procedures and passing procedures from the
|
|
||||||
interpreter to external programs _will_ cause problems as many of the procedures are not
|
|
||||||
stored in _real_ memory. This causes numerous problems.
|
|
||||||
|
|
||||||
**TODO:**
|
|
||||||
|
|
||||||
* Look at how other languages solve this problem (e.g. LUA)
|
|
||||||
* ???
|
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
LLVMX86Disassembler.lib ^
|
|
||||||
LLVMX86AsmParser.lib ^
|
|
||||||
LLVMX86CodeGen.lib ^
|
|
||||||
LLVMSelectionDAG.lib ^
|
|
||||||
LLVMAsmPrinter.lib ^
|
|
||||||
LLVMCodeGen.lib ^
|
|
||||||
LLVMTarget.lib ^
|
|
||||||
LLVMScalarOpts.lib ^
|
|
||||||
LLVMInstCombine.lib ^
|
|
||||||
LLVMInstrumentation.lib ^
|
|
||||||
LLVMProfileData.lib ^
|
|
||||||
LLVMTransformUtils.lib ^
|
|
||||||
LLVMBitWriter.lib ^
|
|
||||||
LLVMAnalysis.lib ^
|
|
||||||
LLVMX86Desc.lib ^
|
|
||||||
LLVMObject.lib ^
|
|
||||||
LLVMMCParser.lib ^
|
|
||||||
LLVMBitReader.lib ^
|
|
||||||
LLVMMCDisassembler.lib ^
|
|
||||||
LLVMX86Info.lib ^
|
|
||||||
LLVMX86AsmPrinter.lib ^
|
|
||||||
LLVMMC.lib ^
|
|
||||||
LLVMX86Utils.lib ^
|
|
||||||
LLVMCore.lib ^
|
|
||||||
LLVMSupport.lib ^
|
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 246 KiB |
-21
@@ -1,21 +0,0 @@
|
|||||||
# Odin Roadmap
|
|
||||||
|
|
||||||
Not in any particular order
|
|
||||||
|
|
||||||
* Custom backend to replace LLVM
|
|
||||||
- Improve SSA design to accommodate for lowering to a "bytecode"
|
|
||||||
- SSA optimizations
|
|
||||||
- COFF generation
|
|
||||||
- linker
|
|
||||||
* Type safe "macros"
|
|
||||||
* Documentation generator for "Entities"
|
|
||||||
* Multiple architecture support
|
|
||||||
* Inline assembly
|
|
||||||
* Linking options
|
|
||||||
- Executable
|
|
||||||
- Static/Dynamic Library
|
|
||||||
* Debug information
|
|
||||||
- pdb format too
|
|
||||||
* Command line tooling
|
|
||||||
* Compiler internals:
|
|
||||||
- Big numbers library
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
@echo off
|
|
||||||
|
|
||||||
|
|
||||||
rem call clang -c -emit-llvm -DGB_IMPLEMENTATION -DGB_DEF=GB_DLL_EXPORT ..\src\gb\gb.h
|
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
# Todo
|
|
||||||
|
|
||||||
## Checker
|
|
||||||
* Cyclic Type Checking
|
|
||||||
- type A: struct { b: B; }; type B: struct { a: A; };
|
|
||||||
- ^ Should be illegal as it's a cyclic definition
|
|
||||||
* Big numbers library
|
|
||||||
- integer
|
|
||||||
- rational
|
|
||||||
- real
|
|
||||||
|
|
||||||
## Codegen
|
|
||||||
* Debug info
|
|
||||||
|
|
||||||
## Command Line Tool
|
|
||||||
* Begin!!!
|
|
||||||
* Choose/determine architecture
|
|
||||||
|
|
||||||
Reference in New Issue
Block a user