I got reply from Mr. Fugate, used test262 commad-line runner for lv5, got some bugs in engine (JSON quote process and RegExp escape had a bug. now fixed). Thanks for this great test suite!
Now, some test262 test cases are failed, but these failures have reasons. First I found test262 bugs. So I heard from Mr. Fugate that bugs can be reported at http://bugs.ecmascript.org, then reported them. https://bugs.ecmascript.org/show_bug.cgi?id=215 // misspelling "grammar", sorry... https://bugs.ecmascript.org/show_bug.cgi?id=216 https://bugs.ecmascript.org/show_bug.cgi?id=217 https://bugs.ecmascript.org/show_bug.cgi?id=218 And, I tried to implement RegExp.prototype.compile, but ES5 and ES3 not defined its standard behavior and I thought compile method is changing RegExp#source / #global / #ignoreCase / #multiline which writable attribute are false and breaking ES5 PropertyDescriptor system, so I created template, but not implemented it. https://github.com/Constellation/iv/commit/7cbc22474ada389a3ac8ab5d3ad5df38bed8a583 And some test cases (about 20 cases?) expect the enumeration order of Object properties. (not reported yet) For example, chapter15/15.2/15.2.3/15.2.3.14/15.2.3.14-2-8 expects Object.keys Array order. But I didn't implement ordered properties because ES5 didn't specify it. So some tests are sometimes failed (if order happened to be expected, test cases are passed...) And S15.10.2.13_A1_T16 is failed. But backreference in ClassEscape is not accepted, and my engine recognize [¥12-¥14] as the range that is from 12 to 14. Do you think about it? I passively think that this regexp raises SyntaxError in ES5 scope. ES5 allows engine to extend RegExp syntax, but extended behavior is not ensured by ES5. http://es5.github.com/#x15.10.2.19 But other tes262 test cases are passed! result is this (python tools/packaging/test262.py --command ~/dev/iv/obj/lv5/lv5 --full-summary > result) https://gist.github.com/1303151 If you try to run it, you can build lv5 https://github.com/Constellation/iv/wiki/lv5 and run test cases http://wiki.ecmascript.org/doku.php?id=test262:command If you find bugs, I would appreciate it if you would report it. Thanks. On Fri, Oct 21, 2011 at 3:54 AM, Juriy Zaytsev <[email protected]> wrote: > How does it fair on test262? http://test262.ecmascript.org/ > -- > kangax > > On Wed, Oct 19, 2011 at 6:26 AM, Yusuke Suzuki <[email protected]> > wrote: >> >> Hello. >> >> I wrote new ECMA262 5.1 full support engine "iv / lv5" in C++. >> This is highly inspired from JSC, V8 and SpiderMonkey. (especially JSC) >> >> https://github.com/Constellation/iv >> >> This aims at most precise engine to ECMA262 5.1 specification. (like >> the great engine,) >> >> I read ECMA262 and wanted precise engine to understand this spec, so I >> created. >> >> features, >> >> all ECMA262 5.1th features >> (strict mode, direct call / indirect call to eval, >> PropertyDescriptor, early errors, Object.prototype.toString.call(null >> / undefined), Object extras, Array extras, etc.) >> BESEN // for example, directive prologure including octal value and >> strict directive is rejected. >> function test() { "¥02"; "use strict"; } >> stack VM >> JSC like bytecode based PIC >> ES5 oriented structures in C++ (PropertyDescriptor, >> Attributes(Enumerable, Writable, Configurable)) >> optimized JSArray (using vector and hash map) >> but this array implements full features of ECMA262 5.1th. for example, >> >> var ary = [0, 1]; >> Object.defineProperty(ary, 'length', { writable : false }); >> ary.length = 4; // of cource, in strict mode, this raises error. >> print(ary.length); // 2 >> try { >> ary.push(2); // throw TypeError, because [DefineOwnProperty] >> with throw = true is called. >> } catch (e) { >> print(e); >> } >> ary[3] = 2; // of cource ... >> print(ary.length); // 2; >> >> minimum source code >> 2 engines, VM and AST Interpreter. we can switch it by command line >> option. >> bytecode based backtrack RegExp (read re1 report and source code to >> study VM based RegExp runtime, and implemented it) >> ES5 oriented optimization >> for example, >> if I get "eval" keyword in strict mode, don't make variable >> dynamic (hold on heap variable with offset access) >> because direct call to eval in strict mode cannot create new >> variable in upper local call site environment. >> >> At first, I created AST Interpreter (named "teleporter") which >> algorithm is just the same to ECMA262 specification. >> And after it is done, I created optimized bytecode VM (named "railgun"). >> These 2 engines are abstracted, so we can switch it at runtime. >> ('--interp option') >> AST Interpreter is very slow, but this source code is exactly the same >> to ECMA262 specification algorithm, so this may be interesting for >> spec readers. >> >> And, SunSpider is available for this engine, so, you can bench it. >> (sorry, probably slow, because of no JIT...) >> >> I'm planning to create own GC (now using BoehmGC library), and create >> JIT module. >> >> Finally, I'm respecting JSC, V8, SpiderMonkey, BESEN implementors great >> works. >> >> Thanks. >> _______________________________________________ >> es-discuss mailing list >> [email protected] >> https://mail.mozilla.org/listinfo/es-discuss > > _______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

