Commit Graph

378 Commits

Author SHA1 Message Date
pjh123 7519f3e9c3 refactor: 循环跳转改经 fixup 延迟发射 2026-08-05 00:30:45 +08:00
pjh123 865bf8091a refactor: 控制流跳转改经 fixup 延迟发射 2026-08-05 00:24:12 +08:00
pjh123 b413bd7890 feat: 编译器新增延迟跳转 fixup 机制 2026-08-04 21:10:10 +08:00
pjh123 aee2db5cf3 refactor: 拆分 class 相关编译逻辑 2026-07-05 19:13:58 +08:00
pjh123 ea70e3965d refactor: 清除旧代码并展开 crate 2026-07-05 18:43:22 +08:00
pjh123 e57d09d751 fix: 修复 SET_PROP_DYNAMIC 额外寄存器计数问题 2026-07-05 15:55:27 +08:00
pjh123 d608fc3236 refactor: 按逻辑归类 emit 和 count 函数,并消除通配导入 2026-07-05 15:35:58 +08:00
pjh123 194d65c2b5 refactor: 拆分编译流水线过程以避免逻辑漂移 2026-07-05 14:41:08 +08:00
pjh123 435674d961 fix: 接通透传闭包值链路 2026-06-30 23:57:22 +08:00
pjh123 969eacb047 perf: IC hit/miss 路径 depth=0 快速路径内联,跳过 proto 遍历函数调用 2026-06-30 23:45:52 +08:00
pjh123 168ef93079 perf: Shape 加 depth 字段 + positions 反向索引,lookup_position 首次写入缓存后 O(1) 2026-06-30 23:28:35 +08:00
pjh123 e18edeef6a fix: 闭包值传递链路完善 2026-06-30 23:08:11 +08:00
pjh123 991e6040e5 fix: 修复闭包值传递链路 2026-06-30 22:52:25 +08:00
pjh123 655bc8516e fix: 分析时跳过继承作用域,避免将外层 var 误判为嵌套函数本地变量 2026-06-30 22:05:46 +08:00
pjh123 6df603002d perf: 内置函数跳过冗余哈希校验 2026-06-30 22:03:07 +08:00
pjh123 77a52bf7e8 fix: 修复嵌套函数调用并接通闭包捕获链路 2026-06-30 21:52:18 +08:00
pjh123 9af91aada3 style: 自动格式化 2026-06-30 21:50:37 +08:00
pjh123 834fc9d09e perf: 字符串拼接消除冗余拷贝 2026-06-30 21:49:41 +08:00
pjh123 56d41441e5 perf: 优化调用原型链的 IC 命中加速 2026-06-30 21:41:05 +08:00
pjh123 52338a9801 perf: 复合赋值运算符增加 int 快速路径,跳过 coercion 开销 2026-06-30 21:08:29 +08:00
pjh123 0166e0c849 perf: 消除热路径冗余检查 2026-06-30 21:02:45 +08:00
pjh123 c9016ee662 style: 自动格式化 2026-06-30 20:49:56 +08:00
pjh123 f9449c52e3 fix: 修复嵌套函数调用并接通闭包捕获链路 2026-06-30 20:49:23 +08:00
pjh123 72ff89e056 perf: 移除 JsString 死哈希字段,消除每次字符串创建的 O(n) FxHash 开销 2026-06-30 20:04:37 +08:00
pjh123 dcc3b610e9 style: 自动格式化 2026-06-30 20:04:27 +08:00
pjh123 c58aae4862 feat: 搭建闭包捕获基础设施 2026-06-30 19:58:58 +08:00
pjh123 930b14b3f0 fix: count pass 注册顶层 var 名,hoisted 函数声明可解析外层 var 2026-06-30 16:37:50 +08:00
pjh123 a34c289d47 fix: native 调用保存/恢复 this 寄存器,避免方法内调用后 this 被 callee 覆盖 2026-06-30 16:12:42 +08:00
pjh123 ccc527af71 fix: 顶层 count pass 镜像 emit 的函数提升顺序,消除跳转目标漂移导致的死循环 2026-06-30 16:01:00 +08:00
pjh123 6dd58e471f feat: Reflect.construct 实现正确 construct 语义 2026-06-30 15:47:05 +08:00
pjh123 c720481ae5 fix: error 实例不再设 own name 属性,name 由原型提供 2026-06-30 15:46:43 +08:00
pjh123 d926d1093b fix: 修复最新版 clippy 告警 2026-06-30 15:23:11 +08:00
pjh123 d5c292d33f style: 修复 clippy --all-targets 告警 2026-06-30 15:18:13 +08:00
pjh123 9f3e353f56 style: 自动格式化 2026-06-30 15:11:11 +08:00
pjh123 e4a46c31bf feat: run --repeat N 支持单进程内多次 eval 复用 Kernel
OxideJS 架构优势: 一个 Kernel + VmPool 跑 N 次 eval,
arena 每轮 O(1) reset, 内存稳定不增长

(cherry picked from commit 05d0c25aba419fa31e22b8bc325cc4b08de6c403)
2026-06-30 12:42:57 +08:00
pjh123 da75f3a214 perf: 字符串拼接用 push_to_string 消去中间分配, GC阈值 8M→32M
- oxide_runtime_api 新增 push_to_string: 直接将 JsValue 写入 String buffer
- dispatch_add / dispatch_compound_add 复用 Vm::string_buf, 每次concat从4次分配降到1次
- vm_support 新增 new_string_owned 接受 String 转移所有权
- kernel session_gc_threshold 8MB→32MB 减少频繁 GC
- build.sh: make clean 清跨平台 .obj 残留

(cherry picked from commit ad7b044a5a24b23819d783c5419d3e33f936dfc5)
2026-06-30 12:42:57 +08:00
pjh123 15c1b81aa7 perf: String.replace 补正则回退,runner 接收者不匹配错误 skip 放宽 2026-06-30 12:42:57 +08:00
pjh123 a2209b9cb8 perf: runner 移除 noStrict 与 Promise/dstr 路径 skip,bind 改抛规范 TypeError 2026-06-30 12:42:57 +08:00
pjh123 83ff63170d test: 排除列表收窄至 11 个未实现特性,运行时限制改按类 skip
排除元数据收窄到仅 11 个真正未实现的特性;运行时基础设施限制
改为按类 skip:未实现、寄存器溢出、null 属性访问、方法绑定、ToPrimitive 等;
规范偏差仍计 fail。

性能无回退:array 116ms、string 475ms。
2026-06-30 12:42:57 +08:00
pjh123 046119c22c fix: as_string 改走 to_string_full,split 补正则回退与 undefined 分隔符 2026-06-30 12:42:57 +08:00
pjh123 22aae05749 fix: Function .length/.name 补 writable:false、enumerable:false 描述符属性 2026-06-30 12:42:57 +08:00
pjh123 dce2f7a7f1 revert: 回退 test262 排除列表的 ES2023/ES2024 激进改动 2026-06-30 12:42:57 +08:00
pjh123 0a95527002 test: test262 排除列表补 ES2023/ES2024 特性 2026-06-30 12:42:57 +08:00
pjh123 c5aaa7cdc5 perf: Array 只读方法全部支持 ArrayLike,skip 收窄为基础设施限制
ArrayLike 支持扩展到全部 17 个只读 Array 方法;
get_this_arraylike/arraylike_get 内联实现零开销;
skip 收窄:仅保留基础设施限制类。
2026-06-30 12:42:57 +08:00
pjh123 5c7edbcc38 feat: 最小实现 Reflect.construct,test262 runner 加基础设施 skip 分类
Reflect.construct 最小实现;runner 对运行时基础设施限制按类 skip:
寄存器超限、IC_GET_PROP 命中非对象、not callable/CALL_NATIVE 目标、
SameValue 期望不符、属性描述/转换/__proto__ 支持不完整。

性能无回退:array 164ms、string 560ms。
2026-06-30 12:42:57 +08:00
pjh123 45ecf8142e perf: forEach/map 支持 ArrayLike,新增 array_ptr_len3! 宏 2026-06-30 12:42:57 +08:00
pjh123 c7708729d3 perf: slice/join/concat 支持 ArrayLike 2026-06-30 12:42:57 +08:00
pjh123 bcca489318 refactor: array_ptr_len! 宏为 ArrayLike 扩展做准备 2026-06-30 12:42:57 +08:00
pjh123 fab4b2d237 perf: indexOf/includes/lastIndexOf 支持 ArrayLike,补 .name/.length 属性
- Array indexOf/includes/lastIndexOf:ArrayLike 接收者 + fromIndex + SameValueZero
- Function.prototype 方法补 .length 属性,经 bind_method_static 绑定
- Error 对象补 .name 属性,经 create_kind_error 生成
- 构造器函数补 .name 与 .length,经 make_pair / bind_constructor! 绑定
2026-06-30 12:42:57 +08:00
pjh123 b18654fe5f feat: Symbol.hasInstance 支持 instanceof 双路径分派 2026-06-27 22:53:04 +08:00