2
0
Fork 0
mirror of https://github.com/ii64/sonic.git synced 2026-06-21 00:46:43 +08:00
Commit graph

33 commits

Author SHA1 Message Date
liu
1443eb3bcf
fix: move large-size local array to _Stack (#162)
* fix: move large-size local array to _Stack

* fix: adjust jsonstate and add alwaysinline

* fix: initialize types.JsonState's dbuf at prologue

* fix: replace `always_inline` with `inline`

* fix: remove unused types

* feat: update asm2asm

* fix: check stack size befor call JIT function

Co-authored-by: liuqiang <liuqiang.06@bytedance.com>
Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-12-30 14:51:23 +08:00
Yi Duan
8203bbac35
fix: remove stack writeBarrier for encoder (#159)
Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-12-20 17:26:19 +08:00
Yi Duan
22229eefc3
fix: relocate stack pointers (#156)
* fix: relocate stack pointer _VAR_sv to keep it alive

* fix: add stack pointer _VAR_vk to defend `encoding.TextUnmarshaler`

* fix: align faker func's stack with JIT func's

* fix: clear _Stack memory when err returned

* fix: clear stack pointer before return

* fix: relimit stack-overflow check at `_ValueDecoder`

Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-12-20 16:19:12 +08:00
Yi Duan
d2711a6af0
fix: use global var _KeepAlive to notice GC in shadow funcs (#145)
Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-12-02 11:08:40 +08:00
Yi Duan
49df11ef83
feat: adjust ABI for supporting go1.17 (#116)
* feat: adjust encoder ABI for supporting go1.17

* binding

* generic

* opt: exchange R10/R11 with BX/BP when call c func

* fmt

Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-11-30 18:47:17 +08:00
liu
49fc705341
feat: Pretouch recursively for large/deep struct (#137) 2021-11-26 14:12:51 +08:00
Yi Duan
5b38f56cec
fix: go1.15 CANNOT support gcWriteBarrier due to linkname bug (#134)
* fix: go1.15 CANNOT add gcWriteBarrier due to linkname bug

* add go1.15 push-check

Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-11-18 11:15:14 +08:00
Yi Duan
43e4a00e90
fix: add gc_write_barrier checks (#131)
* fix: add gcWriteBarrier for decode

* add gcWriteBarrier for encoder


Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-11-17 11:21:20 +08:00
Yi Duan
0f66ab7211
fix: add stack memory at _VAR_vp to pass the address of vp while recursing (#129)
Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-11-09 12:47:05 +08:00
Yi Duan
442ce696fb
fix: use stackmap of shadow func as jit func's (#127)
* fix: use stackmap of shadow func as jit func's

* fix: use LoadWithFaker in decoder

* fix: LoadWithFaker support go115

* add 'runtime.' prefix on jit funcname to prevent preempt

* add parallel GC tests

* remove no_stack_pointer()

Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
Co-authored-by: liuqiang <liuqiang.06@bytedance.com>
2021-11-09 11:50:40 +08:00
Yi Duan
3eade82a01
fix: add gcGuard to prevent GC during Marshal()/Unmarshal() (#122)
Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-10-28 17:02:37 +08:00
liu
0a710eeb9d
fix: make it sorted when marshalling integer key map (#117) 2021-10-18 19:31:33 +08:00
liu
3eca433cb9
fix: marshal struct field with omitempty tag as encoding/json (#114) 2021-10-12 15:14:39 +08:00
Yi Duan
a577eafc25
refactor: make it more readable (#104)
Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-09-18 11:31:25 +08:00
chenzhuoyu
8ccd57d4e0 fix: defer single-element maps checking 2021-09-14 18:41:45 +08:00
chenzhuoyu
514208a4d5 fix: potential ProgramCache OOM under high-load 2021-09-09 14:35:01 +08:00
chenzhuoyu
d2e150948a fix: unmarshalers are always addressable 2021-09-06 16:53:51 +08:00
chenzhuoyu
712d6195df fix: support AVX2 auto-detection for base64x 2021-08-23 14:33:48 +08:00
chenzhuoyu
ade38b26c4 fix: check flags for indirection 2021-08-18 13:36:28 +08:00
chenzhuoyu
8383178c89 feat: supports map key-sorting via encoder options 2021-08-16 18:31:41 +08:00
chenzhuoyu
c2ea100389 fix: fix nil pointer on value receiver (#58) 2021-07-28 17:12:36 +08:00
chenzhuoyu
4937f48f3c fix: support dynamic interface indirection 2021-07-06 21:51:27 +08:00
chenzhuoyu
bcca8c2052 fix: fix addressing past valid memory for empty string 2021-07-02 18:25:50 +08:00
chenzhuoyu
5cb6f17944 feat: performance optimizations 2021-07-02 14:38:12 +08:00
Masaaki Goshima
4e02b5b2fe
Update benchmark (#34)
* chore: update version of goccy/go-json to v0.7.2

* chore: use unordered map option at encoding for go-json's benchmark
2021-06-26 10:43:10 +08:00
chenzhuoyu
53efb129d8 feat: reduce allocs for mapiterinit 2021-06-23 16:37:33 +08:00
chenzhuoyu
944f2b58cc chore: sort imports 2021-06-22 16:47:57 +08:00
Yi Duan
936cee0d3f
test: benchmark with github.com/goccy/go-json (#23)
chore: add benchmark result with go-json

Co-authored-by: duanyi.aster <duanyi.aster@bytedance.com>
2021-06-22 16:30:04 +08:00
chenzhuoyu
b2fbad7b4c feat: rewrite generic decoder in Go, using Finite State Machine 2021-06-16 23:05:21 +08:00
chenzhuoyu
34fa8d64a8 feat: CPU feature detection support 2021-06-10 17:14:25 +08:00
chenzhuoyu
e44e686d90 fix: clears rest of the array if the JSON is not long enough. This fixes #7. 2021-06-06 16:25:34 +08:00
chenzhuoyu
565aeffad4 fix: adjust inline limits to finish compile in a reasonable time 2021-06-04 18:17:54 +08:00
chenzhuoyu
fbe0828190 chore: make it open-source 2021-05-28 23:58:58 +08:00