Calvin Rose
ead0ed5d41
Merge branch 'master' into compile-opt
2025-09-21 20:02:31 -05:00
Calvin Rose
4894a4673a
Fix abstract unix sockets for issue #1618 - address #1618
2025-08-02 19:00:47 -05:00
Michael Camilleri
8d2a9c1148
Allow :dependencies value in info.jdn to contain dictionaries for complex dependency coordinates
2025-07-06 05:45:41 +09:00
Calvin Rose
0066a5a304
Start removing NASM dependence.
...
Start setting up a test suite for sysir and work towards emitting jitted
x86 machine code.
2025-05-04 20:20:11 -05:00
Calvin Rose
862b4e9688
Add sysir test suite stub
2025-04-13 07:47:52 -05:00
Calvin Rose
11e6a5a315
More work on compile-opt.
2025-03-31 21:48:46 -05:00
Calvin Rose
871f8ebf4e
More work on moving to machine code emission.
2025-03-30 13:38:33 -05:00
Calvin Rose
c677c72a73
Add tool that lets us more easily compare compilation paths.
...
Compare:
IR -> C -> x64
vs.
IR -> x64
2025-03-29 20:37:51 -05:00
Calvin Rose
9a1cd6fdd9
Add janet_sysir_scalarize
...
Makes it easier to add simpler backends without needing to completely
handle vectorization.
2025-02-24 19:12:17 -06:00
Calvin Rose
768c9b23e1
Update drawing 2.
2025-02-19 08:21:20 -06:00
Calvin Rose
4396f01297
More work on drawing example and frontend changes.
2024-12-01 08:43:54 -06:00
Calvin Rose
046d299d77
More work on x86 backend.
2024-11-26 11:18:46 -06:00
Calvin Rose
9fa9286fca
Add more drawing examples.
2024-11-25 09:42:00 -06:00
Calvin Rose
c13ef02ea2
Add drawing2.janet so we can keep the working drawing example.
2024-11-25 08:51:40 -06:00
Calvin Rose
52cedbc4b4
More work on drawing example.
2024-11-25 07:33:31 -06:00
Calvin Rose
d345e551f1
Correct pointer arith type checking.
2024-11-24 20:06:16 -06:00
Calvin Rose
a6ea38a23b
More working on pointer arithmetic.
2024-11-24 18:44:26 -06:00
Calvin Rose
bc79489068
Begin working on drawing example.
2024-11-24 15:53:20 -06:00
Calvin Rose
bed80bf1d3
Merge branch 'master' into compile-opt
2024-10-12 07:58:43 -05:00
Calvin Rose
3d93028088
Test bundle
2024-10-05 12:37:23 -05:00
Calvin Rose
80ed6538d0
Add constant checking in sysir middle end.
2024-10-05 12:05:04 -05:00
Calvin Rose
6577a18cef
Better printing for complex constants.
...
Also added stub for checking if constants are valid in IR, but it is
not currently used.
2024-09-30 08:14:01 -05:00
Calvin Rose
ea332ff81e
More work on making the temporary frontend a little nicer.
...
We need to create abstractions around more of the backend
to properly test and experiment with things, even if the frontend
is not final.
2024-09-29 15:55:10 -05:00
Calvin Rose
e96dd512f3
Work on some local type inference.
...
Right to left type inference in expressions for binary operators.
2024-09-29 11:37:04 -05:00
Calvin Rose
a588f1f242
More small tweaks to compile-opt.
2024-09-29 07:13:27 -05:00
Calvin Rose
3618b72f4d
Merge branch 'master' into compile-opt
2024-09-08 12:28:51 -05:00
Calvin Rose
e4f4a42751
Add regression test for chat server issues. Address #1496
2024-09-06 08:05:56 -05:00
Calvin Rose
f553c5da47
Update ev.c with workaround for failing chat server.
...
2 issues:
- With poll backend, we were polling for writes even after we finished
writing. Presents as wasting a lot of CPU.
- Fixes strange closing behavior of chat server.
2024-09-06 00:00:09 -05:00
Calvin Rose
5f70a85f7e
Add chat server example.
2024-09-05 23:09:02 -05:00
Calvin Rose
85028967d8
Add aliases for bundle/module - issue #1486
...
info.jdn -> bundle/info.jdn
bundle.janet -> bundle/init.janet
2024-08-17 09:58:40 -05:00
Calvin Rose
342a29c7be
Fix formatting.
2024-07-12 15:22:46 -05:00
Valentin Anger
4af187d0ca
Add support for the AAPCS64 calling convention
2024-06-23 18:22:25 +02:00
Calvin Rose
3510e235ee
More work on compile-opt
2024-06-21 17:16:56 -05:00
Calvin Rose
b6fb7ae69c
x64 allow dynamically switching between windows and sysv target.
2024-06-17 23:02:05 -05:00
Calvin Rose
e5765b26d4
Working examples on windows.
...
Add some support for windows x64 ABI.
2024-06-17 07:07:20 -07:00
Calvin Rose
cdb3baaca3
Work on windows.
2024-06-16 13:37:25 -07:00
Calvin Rose
c413bc2b4e
Don't assign variables positions on the stack that clobber import info.
...
(return address, previous basepoint, etc.)
2024-06-16 10:06:22 -05:00
Calvin Rose
dfdf734fc7
Merge branch 'master' into compile-opt
2024-06-16 09:31:11 -05:00
Calvin Rose
314e684097
More work on x64 backend.
2024-06-14 16:57:32 -05:00
Calvin Rose
232a8faa35
More work compile-opt.
2024-06-13 07:27:48 -05:00
Calvin Rose
c31d8b52ff
Add typed constants and lots more.
2024-06-12 13:57:33 -05:00
Calvin Rose
f0395763b7
More work on x86 target.
...
Also remove all (limited) type inference from the sysir. Type
inference is better done in frontend, limited inference in backend
just covers compilers issues.
Simple hello world with nasm working.
2024-06-10 20:16:04 -05:00
Calvin Rose
5b3c5a5969
Lots of work on calling conventions and x86 backend.
...
We need the ability to represent multiple calling conventions in IR.
All backends need to support a :default CC, but can also support more
for interop with system libraries, code from other compilers, syscalls, etc.
Also allow void returns.
2024-06-10 08:47:27 -05:00
Calvin Rose
af10c1d4b5
More work on x64 backend, especially branching.
...
Needs changes to IR to allow encoding immediates in all
instructions where possible. This makes the IR denser, means
we don't need `constant` and `callk`, and allows certain optimizations
like comparing to zero, using `inc` and `dec`, etc which are
specializations of more general instructions with constants.
2024-06-08 13:20:34 -05:00
Calvin Rose
25b7c74089
More work on register allocation and spilling.
...
Setup frontend.janet to show the basics of what is going on. Currently
emitting "fake" instructions just to hash out the idea.
One apparent issue is how we handle register spilling during variable
argument IR instructions (function calls). Arguments should come
_before_ the function call not after.
2024-06-05 17:50:11 -05:00
Calvin Rose
7ea118f248
Begin work on simple x64 backend.
...
Introduce register allocation, spilling, etc. First implementation
will likely emit textual assembly and use a very bad register allocation
algorithm.
2024-06-03 08:35:08 -05:00
Calvin Rose
480c5b5e9d
Change how labels are recorded.
...
Disallow jumping to arbitrary instructions - instead, only allow jumps
to label ids. This will make various transformations and validations
easier since adding or remove instructions does not break jumps.
2024-06-02 09:43:33 -05:00
Calvin Rose
600e822933
Change interface for bundle/install
...
Name argument should be inferred in most cases. Also use :name
instead of :bundle-name in most places to be terser and simpler.
2024-05-26 16:26:08 -05:00
Calvin Rose
2260a593bd
Add some test usage for the sample bundle.
2024-05-25 12:57:09 -05:00
Calvin Rose
7d8af2f99a
Add some testing to the bundle/ module.
2024-05-25 12:44:49 -05:00