Commit Graph

611 Commits

Author SHA1 Message Date
pjh123 687c933891 feat: 拆分 stress benchmark 到细粒度单热点测试并修复 bench 采样逻辑 2026-08-13 14:27:20 +08:00
爱特每羊队 f8a4bacfec fix: accessor getter 调用异常经 raise_call_error 走 unwind(JS try/catch 可捕获,此前逃逸) 2026-08-12 17:55:58 +08:00
爱特每羊队 4303462d19 feat: compiler/test262 runner 接线 + 模块顶层 this 绑定
- Compiler::compile_module:Emitter::emit_program_module → 统一 IR 管线(DCE/regalloc/lower/flatten)
- CompiledModule.is_es_module:VM run 时模块顶层 this=undefined(脚本仍为全局对象)
- 全局注册 __moduleLinkGet
- test262 runner:Test262ModuleLoader(相对路径解析 + import attributes 判定 json/text/bytes),is_module 走 compile_module
2026-08-12 17:37:33 +08:00
爱特每羊队 6da248872b feat: emit 模块编译(快照式链接:依赖子模块闭包 + import/export 域)
- emit_program_module:模块顶层编译(is_global_scope=false,顶层 this undefined 由 VM 按标志绑定)
- emit_module_into_ctx:预声明/闭包分析识别 export 包裹声明与 import 绑定
- 依赖收集:import/re-export/star 的 source 去重、循环检测、json/text 数据模块
- 导入绑定初始化:__moduleLinkGet 链接期检查;self-import 别名语义(export 处回写)
- export 域:声明/重导出/export */export default 就地注册命名空间
- re-export 链接检查移至 prelude(先于 body 求值)
- emit_module_call 参数打包连续寄存器(CALL_NATIVE 契约)
- CompileCtx 增 module_ns_reg/module_dep_ns_regs/self-import 映射
- 拆分 declaration helper(export 声明复用);function/class 表达式 emitter 提升可见性
2026-08-12 17:37:33 +08:00
爱特每羊队 3f45f38f51 feat: module natives(命名空间对象/导出读写/star 合并/seal/eval/data + 链接检查)
- __moduleObject:null 原型命名空间,带 @@toStringTag=Module(w/e/c=false)
- __moduleSet:定义不可写/可枚举/不可配置导出属性
- __moduleGet:模块命名空间 exotic Get(缺失导出抛 TypeError)
- __moduleLinkGet:import 绑定链接期检查(缺失导出抛 SyntaxError)
- __moduleStar:export * 合并,冲突名跳过(dst 已有属性省略)
- __moduleSeal:封冻命名空间
- __moduleEval:同步执行依赖模块并返回命名空间
- __moduleData:json/text 数据模块命名空间
2026-08-12 17:37:33 +08:00
爱特每羊队 86a20fa1fe fix: class 类名绑定经 dedicated cell 捕获(C===Cv 恒等)+ upvalue 写入 const guard(getter 赋值抛 TypeError) 2026-08-12 17:30:28 +08:00
爱特每羊队 1323a0564b feat: Duration.total 支持字符串/原始值 relativeTo 语义(无效与越界字符串 RangeError、数字/null 等 TypeError、days 日历路径),total 子集 41/29 2026-08-12 16:58:57 +08:00
爱特每羊队 5e38623fee feat: Temporal.Duration.prototype.round(无日历单位路径:选项校验+24h 天舍入+按最大单位平衡,绑定注册) 2026-08-12 16:16:22 +08:00
爱特每羊队 4818465234 fix: class 类名绑定 TDZ 与 const 语义(extends 引用类名抛 ReferenceError,类构建后初始化绑定) 2026-08-12 15:37:58 +08:00
爱特每羊队 d1b5c533fc feat: parser 支持 ES module(parse_module)+ test262 放行 module 用例
- oxide_parser 新增 parse_module(SourceType::mjs),parse 重构为 parse_with_source_type
- oxide_test262 不再跳过 flags:[module]/features:module,module 用例走 parse_module
- 首轮实测:language/import 12 pass/35 fail(原全跳过,10/10 负向 parse 全过),
  language/module-code 248 pass/274 fail(parse-err 103/0,early-* 26/0)
- 顺带修复 oxide_test262 两个 clippy lint(single-match、unnecessary unwrap)
2026-08-12 15:15:27 +08:00
爱特每羊队 ad547d5cd8 feat: Temporal.Duration.prototype.add(分量精确求和+按最大单位平衡+范围校验,绑定注册);add 子集 32/0 2026-08-12 14:50:13 +08:00
爱特每羊队 fe79eff172 fix: Temporal 构造器补 length 自有属性(Instant/ZonedDateTime/PlainDate/PlainTime/Duration 按规范 arity) 2026-08-12 14:37:31 +08:00
爱特每羊队 f16e39dd98 fix: Instant 参数转换按规范——非字符串原始值直接抛 TypeError(from/compare/equals/since/until) 2026-08-12 14:33:16 +08:00
爱特每羊队 0cd98084da feat: Temporal.PlainDateTime.prototype.equals(实例/字符串/对象/ZDT 统一比较,绑定注册) 2026-08-12 14:27:25 +08:00
爱特每羊队 d5b45d5b24 fix: Temporal PlainDate/PlainDateTime.from 表示范围边界、leap second、constrain 下限与实例转换 2026-08-12 14:17:28 +08:00
爱特每羊队 1a4663dcab fix: class 方法/访问器/constructor/prototype 属性描述符(非枚举/只读),新增 DEFINE_PROP_ATTRS/DEFINE_ACCESSOR_ATTRS
- opcode.rs/inst.rs/contract.rs/vm.rs/vm_dispatch_ctrl.rs:新增两个带 attrs 扩展字的 define 指令
  (attrs bit0=writable, bit1=enumerable, bit2=configurable,与 PropAttributes 一致)
- class/method.rs:方法与非计算访问器改按规范非枚举安装(DefineMethod 语义)
- class/prototype.rs:proto.constructor 非枚举;ctor.prototype 三标志全 false(MakeConstructor)
- 效果:language/statements/class 1782 pass/948 fail -> 1910 pass/716 fail(+128/-232)
2026-08-12 14:11:02 +08:00
爱特每羊队 5726d4126b feat: Temporal PlainDate 字符串走 ParseTemporalDateString(注解/UTC/小数位/分数分钟校验),property bag 支持 monthCode 与日历标识符解析 2026-08-12 13:49:58 +08:00
爱特每羊队 20486cd615 fix: PlainDate/PlainDateTime until/since 月分解 days 计算(current 保持真实钳制日期,锚定日只用于越界比较) 2026-08-12 13:31:15 +08:00
爱特每羊队 9a0ab79711 feat: PlainDate/PlainDateTime until/since 舍入选项(roundingMode/roundingIncrement/smallestUnit,GetDifferenceSettings 对齐) 2026-08-12 13:26:10 +08:00
爱特每羊队 cc78e6b28f fix: ArraySetLength 收缩遇不可配置元素静默失败、ToPrimitive 异常透传与既有属性描述符缺省回填
- arr.length 收缩时若 [newLen, oldLen) 内存在不可配置元素,整个收缩失败且不做任何修改(sloppy 赋值静默 no-op),不再抛错或截断
- length 赋值 ToPrimitive(valueOf/toString)抛错时按主 dispatch 约定直接返回,避免二次抛 RangeError 覆盖原异常(S15.4.5.1_A1.3_T2)
- Object.defineProperty/defineProperties/create 对已有属性省略描述符字段时保持现有属性值(无显式 meta 按 DEFAULT_DATA 回填),修复 toReversed/toSorted/toSpliced/with length-decreased-while-iterating
2026-08-12 13:07:32 +08:00
爱特每羊队 dc023b2637 fix: 数组 length 赋值 ArraySetLength 语义与超长逻辑长度(a.length 读取/收缩校验/空洞同步) 2026-08-12 12:52:02 +08:00
爱特每羊队 3e8cf3eb23 fix: Array 方法 array-like receiver/Get 异常传播、species 构造、slice/toSpliced/toSorted 规范化,数组字面量空洞语义 2026-08-12 12:51:28 +08:00
爱特每羊队 3e61b573db feat: 新增 Symbol.species well-known symbol 绑定(Symbol.species 解析/键槽/内建对象) 2026-08-12 12:50:53 +08:00
爱特每羊队 291250f3e6 feat: BigInt bitwise operators with ToNumeric semantics 2026-08-12 11:27:50 +08:00
爱特每羊队 ee9a9e12b8 fix: object-to-primitive conversion errors propagate through native builtins 2026-08-12 11:27:40 +08:00
爱特每羊队 c9b05ecc45 feat: PlainDate equals/compare 字符串参数经 date_like_ymd 转换并做 ISO 范围校验 2026-08-12 10:47:43 +08:00
爱特每羊队 bf3a0ff0da fix: PlainDate until/since 全范围 ISO 日期,civil 日计数 + 范围校验,修复全量运行崩溃 2026-08-12 10:47:32 +08:00
爱特每羊队 c4fda0f883 engine: ToPropertyKey via ToPrimitive, Symbol keys/description, catchable conversion errors 2026-08-12 09:59:56 +08:00
爱特每羊队 18eb6ef8ab feat: add Array entries/keys/findLastIndex/toSorted/toReversed/toSpliced/with 2026-08-12 03:42:42 +08:00
爱特每羊队 998327aa7e feat: BigInt.prototype[Symbol.toStringTag] = "BigInt"
Adds the well-known @@toStringTag data property (writable:false,
enumerable:false, configurable:true) so Object.prototype.toString and
property descriptors match the spec. Remaining built-ins/BigInt failure
(Symbol.toStringTag.js verifyProperty) is blocked on String(Symbol)
support in the Symbol track.
2026-08-12 03:41:22 +08:00
爱特每羊队 b844505ec7 fix: BigInt SUB/MUL with 0n no longer raise Division by zero
binary_arith! applied an unconditional is_zero() guard, so x - 0n and
x * 0n (and wrapped-object variants) incorrectly threw RangeError.
Only DIV/MOD legitimately reject BigInt zero divisors; SUB/MUL must
compute normally. test262 language/expressions/subtraction:
29/6 -> 30/5 (bigint-arithmetic now passes).
2026-08-12 03:30:03 +08:00
爱特每羊队 f3c37911f7 feat: arbitrary-precision BigInt via num-bigint (literals, arithmetic, toString, asIntN/asUintN) 2026-08-12 03:15:18 +08:00
爱特每羊队 ca293a57e9 fix: Object.prototype.toString tags for Math/JSON/Arguments 2026-08-12 02:29:40 +08:00
爱特每羊队 28477a3e47 feat: BigInt constructor ToPrimitive semantics, toString(radix), asIntN/asUintN; ctor [[Prototype]]=Function.prototype 2026-08-12 02:23:27 +08:00
爱特每羊队 ff9958d78b test262: unskip BigInt feature tests now that minimal BigInt exists 2026-08-12 01:40:18 +08:00
爱特每羊队 6afeaafb54 feat: implement PlainDateTime until/since with spec rounding semantics 2026-08-12 01:18:34 +08:00
爱特每羊队 ed8c76c60f feat: implement PlainDateTime add/subtract arithmetic 2026-08-11 23:14:42 +08:00
爱特每羊队 d1d85ffe4f feat: implement PlainDateTime toString options and ISO range parsing 2026-08-11 23:07:41 +08:00
爱特每羊队 ed90ebd4e4 feat: implement Temporal PlainDateTime conversion and serialization 2026-08-11 22:29:00 +08:00
爱特每羊队 e6627b02f1 feat: implement Temporal PlainDateTime foundation 2026-08-11 21:32:15 +08:00
爱特每羊队 5ec0dc2b7d feat: implement Temporal Instant zoned conversion 2026-08-11 20:54:25 +08:00
爱特每羊队 a9e194f2c6 feat: implement Temporal Instant serialization 2026-08-11 19:14:24 +08:00
爱特每羊队 6b00eaaf06 feat: implement Temporal Instant differences 2026-08-11 18:22:21 +08:00
爱特每羊队 d443808d96 fix: synchronize nested builtin register mappings 2026-08-11 18:06:42 +08:00
爱特每羊队 67c6d3a53a fix: preserve high template expression registers 2026-08-11 17:17:30 +08:00
爱特每羊队 e049a8df5d feat: implement Temporal Instant round 2026-08-11 16:57:53 +08:00
爱特每羊队 3839e18c0f fix: capture destructured function parameters 2026-08-11 16:57:13 +08:00
爱特每羊队 756d6b8e1b feat: implement precise Temporal Instant arithmetic 2026-08-11 15:55:05 +08:00
爱特每羊队 4c42112c51 feat: implement precise Temporal Instant factories 2026-08-11 15:21:28 +08:00
爱特每羊队 ec2efa7b6b fix: capture object keys and scope loop bindings 2026-08-11 14:17:45 +08:00