Phd Position F/m Compiling Dynamic Languages to - Sophia Antipolis, France - Inria

Inria
Inria
Entreprise vérifiée
Sophia Antipolis, France

il y a 1 jour

Sophie Dupont

Posté par:

Sophie Dupont

beBee Recruiter


Description
Le descriptif de l'offre ci-dessous est en Anglais_


Type de contrat :

CDD

Niveau de diplôme exigé :
Bac + 5 ou équivalent


Autre diplôme apprécié :
Master thesis


Fonction :
Doctorant


A propos du centre ou de la direction fonctionnelle:
The Inria centre at Université Côte d'Azur includes 37 research teams and 8 support services. The centre's staff (about 500 people) is made up of scientists of different nationalities, engineers, technicians and administrative staff.

The teams are mainly located on the university campuses of Sophia Antipolis and Nice as well as Montpellier, in close collaboration with research and higher education laboratories and establishments (Université Côte d'Azur, CNRS, INRAE, INSERM...), but also with the regiona economic players.

With a presence in the fields of computational neuroscience and biology, data science and modeling, software engineering and certification, as well as collaborative robotics, the Inria Centre at Université Côte d'Azur is a major player in terms of scientific excellence through its results and collaborations at both European and international levels.


Contexte et atouts du poste:

Research in the Inria Splits team.


Mission confiée:

As most dynamic languages, JavaScript is very difficult to implement
efficiently because most of its expressions have all sorts of
different meanings that involve all sorts of different executions. To
give a single prominent example, In JavaScript the expression
'' might denote five radically different operations. It might
fetch the property 'prop' from 'obj'. It might scan the linked list of
obj's prototype chain and access the property 'prop' of one of these
objects along the way. It might involve calling a user defined
function if 'prop' is an accessor. It might involve allocating an
object if 'obj' is a primitive value. At last, it might involve
jumping through another component of the standard runtime system if
'obj' is a proxy object. No syntactic element nor type information let
the execution engine discover in advance which evaluation schema to
use. Checking all the possible interpretations in sequence and then
execute literally, that is following the prescription of the language
specification, the proper one would deliver very slow
performances. All mainstream implementations use alternative
strategies. Amongst all the possible interpretations, they favor the
one that corresponds to the most frequent situation for which they
elaborate a faster execution plan, and, as importantly, for which they
elaborate a fast guard that let them decide as quickly as possible, if
the faster schema would preserve the original semantics or
not. Typically, that what ''inline caches'' and ''hidden classes''
achieve. Using a single test, the comparison of the object's hidden
class with the inline cache, the guard checks if the offset where to
read the property is known or not. If it is, the property is directly
fetched using a single indexed memory read. Otherwise, the slower
execution path checking all the possible situations, for instance, the
situation where the property is an accessor, is used.

The common intuition is that dynamic compilers (jit) are in a better
position to use dynamic heuristics-based strategies as they have the
program and the data at hand where they have to decide which code to
generate. We disagree with this intuition and we have shown in several
publications that compiling at runtime is not a significant advantage
because in most common situations simple guesses let static compilers,
nowadays called ahead-of-time compilers (AOT), infer the most
likely types and at the cost of larger codes, they can generate
several versions of the program and select the one to execute using
guards similar to those jit compilers would use. Based on this general
idea, we have build a full-fledged JavaScript AOT compiler. It is
called hopc. It is distributed as an open source software. It can be

WASM (WebAssembly) is a new popular execution platform that brings the
promise of safe, fast, and portable executions. Considering the
industrial effort invested in promoting WASM, it might be a central

In spite of its name, WASM is a general-purpose virtual machine, not
particularly tailored for the web, although most web browsers now
implement it. As of today, despite its growing popularity, only a
small set of languages can be compiled to WASM, probably because until
very recently, it was lacking important constructs that enables
efficient implementations of high level languages. The recent
inclusion of mechanisms for dealing with automatic memory management
and exceptions opened new opportunities for compiling new languages to
WASM. Exploring the compilation of dynamic languages to WASM is yet an
unexplored domain. This is the purpose of this PhD thesis proposal.

WASM does not expose any particular mechanisms for JIT-ted executions
so generating WASM code requires AOT techniques. Fortunat

Plus d'emplois de Inria