[igt-dev] Prospective igt shell (javascript interface)

Chris Wilson chris at chris-wilson.co.uk
Mon Aug 20 13:12:31 UTC 2018


Quoting Chris Wilson (2018-08-20 14:01:43)
> Just to put it into perspective how easy I found it working with Duktape
> to create a working script interpreter that can execute our tests faster
> than ld can even load our binaries.
> 
> The import of duktape is probably too large for the list, but there is
> nothing more there than load-file and eval, with some hooks to allow the
> later drivers to install themselves into the initial environment.
> (Automatic installation to avoid having to add require('foo') to every
> script. In theory any ECMAScript (i.e from npm) can be loaded it just
> requires hooking up the path finder.)

For the record, N-API (Node.js) doesn't look horrible to integrate
either; certainly better than how unfriendly embedding V8 directly
looks.

The benefits would be that we get V8 (latest ECMAScript and jit), but we
lose the charm of being able to ship with very own script interpreter
sources (I'm thinking of my poor i915gm that ran out of disk space ages
ago. ;)
-Chris


More information about the igt-dev mailing list