Edoardo Vacchi
f385873239
compiler(arm64): generate trap exit code once ( #1516 )
...
Signed-off-by: Edoardo Vacchi <evacchi@users.noreply.github.com >
2023-06-15 08:35:51 +10:00
Achille
2b50c85e20
compiler: allow inlining of internal/asm package functions ( #1484 )
...
Signed-off-by: Achille Roussel <achille.roussel@gmail.com >
2023-05-20 05:48:08 +02:00
Achille
9780f0f4a0
compiler: zero-copy code assembly ( #1481 )
...
Signed-off-by: Achille Roussel <achille.roussel@gmail.com >
Co-authored-by: Crypt Keeper <64215+codefromthecrypt@users.noreply.github.com >
2023-05-19 07:06:30 +02:00
Achille
2f31894f61
compiler: optimize struct layout to reduce memory footprint ( #1469 )
...
Signed-off-by: Achille Roussel <achille.roussel@gmail.com >
2023-05-15 11:16:37 -07:00
Achille
9090f31713
asm: optimize node allocation ( #1463 )
...
Signed-off-by: Achille Roussel <achille.roussel@gmail.com >
2023-05-13 23:45:22 -07:00
Takeshi Yoneda
a7e1e693b9
asm/amd64: removes enablePadding flag ( #1395 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-24 10:07:27 +09:00
Takeshi Yoneda
62074dc601
asm/amd64: removes nodeImpl.forwardJumpTarget ( #1394 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-24 09:55:24 +09:00
Takeshi Yoneda
c6c46114ef
asm/amd64: optimizes initializeNodesForEncoding ( #1393 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-24 08:22:37 +09:00
Takeshi Yoneda
010f0a93a2
asm/amd64: optimizes maybeNOPPadding if conds ( #1389 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-21 15:11:37 +09:00
Takeshi Yoneda
f3deb47d69
asm/amd64: uses enum for operand types ( #1388 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-21 11:30:14 +09:00
Takeshi Yoneda
ae6a43b367
asm/amd64: removes map access in encoding ( #1387 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-21 10:50:35 +09:00
Takeshi Yoneda
a9cf51234c
asm/amd64: optimizes register3bits via array ( #1386 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-21 09:19:04 +09:00
Takeshi Yoneda
b1fec9fb0a
asm/amd64: avoids allocations in static const offset resolution ( #1384 )
2023-04-20 03:56:11 -07:00
Takeshi Yoneda
70c5e03836
compiler(amd64): reuses static consts properly ( #1382 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-19 16:18:01 +09:00
Takeshi Yoneda
2a2e07a91f
asm/arm64: uses enum for operand types ( #1378 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-18 15:20:25 +09:00
Takeshi Yoneda
27b405f17b
asm/arm64: removes unneeded 16 bytes alignment ( #1367 )
...
signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-17 15:16:40 +09:00
Takeshi Yoneda
3aeeb0b01d
asm/arm64: avoids using unnecessary map access ( #1355 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-04-11 15:40:33 +09:00
Takeshi Yoneda
cee1e50ad2
compiler: avoids allocation in label resolution ( #1326 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-03-30 22:26:18 -07:00
Takeshi Yoneda
bbae781978
compiler: avoid allocation in SetJumpTargetOnNext ( #1325 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-03-31 13:03:26 +09:00
Takeshi Yoneda
a0a6331011
asm/amd64: avoids allocation in getting memory location ( #1322 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-03-31 08:52:01 +09:00
Takeshi Yoneda
448c990ab6
asm/amd64: avoids allocations on forward jump resolution ( #1315 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-03-30 17:46:09 +09:00
Takeshi Yoneda
76815dbd75
asm/amd64: avoids map allocation per node ( #1307 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-03-29 16:27:54 +09:00
Takeshi Yoneda
15e393c7e9
asm: reuse StaticConstPool ( #1304 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-03-29 13:30:16 +09:00
Takeshi Yoneda
376292fe53
asm: reuses the slice on SetBranchTargetOnNextNodes ( #1303 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2023-03-29 12:20:50 +09:00
Takeshi Yoneda
a1706eb05c
asm(arm64): fixes stack pointer add/sub for large consts ( #962 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-12-26 16:26:23 +09:00
Takeshi Yoneda
69688468f8
asm(arm64): adds UDF instruction ( #961 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-12-26 15:58:35 +09:00
Takeshi Yoneda
3d70c85032
asm(arm64): adds support for stack pointer manipulation ( #960 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-12-26 10:07:13 +09:00
Crypt Keeper
796fca4689
cli: adds compile command and -cachedir option ( #945 )
...
This adds a `compile` command and a `-cachedir` option to expose our
compilation cache to end users. This allows substantial speedup
especially for large wasm.
Signed-off-by: Adrian Cole <adrian@tetrate.io >
Co-authored-by: Anuraag Agrawal <anuraaga@gmail.com >
2022-12-20 13:56:29 +08:00
Takeshi Yoneda
d63c747d53
asm,compiler: reduce allocations during compilation ( #936 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-12-20 12:49:47 +09:00
Takeshi Yoneda
76ed3047cf
arm64: adds support for large in-block jumps with ADR ( #851 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-11-10 05:46:46 +01:00
Crypt Keeper
7e3cda8680
Adds more context for ADR offset overrun ( #850 )
...
See #847
Signed-off-by: Adrian Cole <adrian@tetrate.io >
2022-11-09 08:27:10 +01:00
Crypt Keeper
329ccca6b1
Switches from gofmt to gofumpt ( #848 )
...
This switches to gofumpt and applies changes, as I've noticed working
in dapr (who uses this) that it finds some things that are annoying,
such as inconsistent block formatting in test tables.
Signed-off-by: Adrian Cole <adrian@tetrate.io >
2022-11-09 05:48:24 +01:00
Takeshi Yoneda
087ab9d9fc
amd64: do not load/store higher bits of 32-bit int/float ( #742 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-08-12 12:08:20 +08:00
Vladislav
ec1f595225
Optimize memory bulk operations: fill on x86 ( #735 )
...
Signed-off-by: Vladislav Oleshko <vladislav.oleshko@gmail.com >
2022-08-11 12:06:26 +08:00
Takeshi Yoneda
c5daf5a218
interpreter,compiler(arm64): clears higher bits in i32.load_8/16_s ( #725 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-07-28 15:45:07 +09:00
Vladislav
63e438aa66
Optimize memory bulk operations: copy on x86 ( #700 )
...
Signed-off-by: Vladislav Oleshko <vladislav.oleshko@gmail.com >
Co-authored-by: Takeshi Yoneda <t.y.mathetake@gmail.com >
2022-07-26 18:22:47 +09:00
Takeshi Yoneda
97e3216eb2
asm(arm64): fixes the source register of CMEQ(vector,zero) ( #719 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-07-26 15:59:45 +09:00
Takeshi Yoneda
37d2c6d803
asm(arm64): fixes unaligned vector stores ( #718 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-07-26 12:10:26 +09:00
Crypt Keeper
939403c10b
Makes it possible to implement FunctionListener and Factory ( #716 )
...
This simplifies FunctionListener definition by making it possible to
implement both interfaces without intermediate state. Passing the
function definition to the before/after callbacks is the key.
This also continues efforts towards Go 1.19 doc formatting.
Signed-off-by: Adrian Cole <adrian@tetrate.io >
2022-07-25 12:53:41 +08:00
Anuraag Agrawal
66d43a2a52
Fix computation of offset in arm64 compiler ( #677 )
...
* Fix computation of offset in arm64 compiler
Signed-off-by: Anuraag Agrawal <anuraaga@gmail.com >
2022-07-07 16:13:00 +09:00
Takeshi Yoneda
c5f1d84914
asm: backfills unit tests and fixes node formatting ( #669 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-06-30 11:07:35 +09:00
Takeshi Yoneda
cbe6170473
compiler: always allocate register to save conditional values ( #666 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-06-29 09:26:50 +09:00
Takeshi Yoneda
2fa67b83bf
asm(amd64): resolve NOP padding TODO after golang-asm removal ( #663 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-06-28 09:39:19 +09:00
Takeshi Yoneda
b8c94fd0b9
asm: remove integration tests with golang-asm ( #659 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-06-28 09:19:21 +09:00
Takeshi Yoneda
fd318d4be9
asm: unexport arm64 pkg implementations ( #657 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-06-26 20:26:22 +09:00
Takeshi Yoneda
1489a9f19f
arm64: remove golang-asm integeration test ( #655 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-06-24 14:49:50 +09:00
Takeshi Yoneda
70a69c24d0
arm64: remove CompileJumpToMemory ( #654 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-06-24 12:14:56 +09:00
Takeshi Yoneda
c983e2c972
Delete debug assembler ( #652 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-06-23 16:22:58 +09:00
Takeshi Yoneda
3b4544ee48
compiler: remove embedding of pointers of jump tables ( #650 )
...
This removes the embedding of pointers of jump tables (uintptr of []byte)
used by BrTable operations. That is the last usage of unsafe.Pointer in
compiler implementations.
Alternatively, we treat jump tables as asm.StaticConst and emit them
into the constPool already implemented and used by various places.
Notably, now the native code compiled by compilers can be reusable
across multiple processes, meaning that they are independent of
any runtime pointers.
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-06-23 13:42:46 +09:00
Takeshi Yoneda
4136a360ac
amd64: removes embeddings of pointers of bit masks for FP arithmetic ( #648 )
...
Signed-off-by: Takeshi Yoneda <takeshi@tetrate.io >
2022-06-22 13:31:26 +09:00