comparison README.md @ 22208:df57bc2fcdbd

Bringing the README.md up-to-date and providing references to Javadoc which should be the primary source of information.
author Jaroslav Tulach <jaroslav.tulach@oracle.com>
date Wed, 30 Sep 2015 12:38:35 +0200
parents 8ec8f7831ab4
children
comparison
equal deleted inserted replaced
22207:e2ae3893ef98 22208:df57bc2fcdbd
14 included TruffleDSL provides a convenient way to express such optimizations. 14 included TruffleDSL provides a convenient way to express such optimizations.
15 15
16 Truffle is developed and maintained by Oracle Labs and the Institute for System 16 Truffle is developed and maintained by Oracle Labs and the Institute for System
17 Software of the Johannes Kepler University Linz. 17 Software of the Johannes Kepler University Linz.
18 18
19 ## Using Truffle
19 20
20 ## Building and Using Truffle 21 Truffle official documentation is part of [Truffle javadoc](http://lafo.ssw.uni-linz.ac.at/javadoc/truffle/latest/).
22 It includes description of common use-cases, references to various tutorials,
23 code snippets and more. In case you want to embedded Truffle into your
24 application or write your own high speed language interpreter, start
25 [here](http://lafo.ssw.uni-linz.ac.at/javadoc/truffle/latest/).
21 26
22 Truffle and Graal use the [MX build tool](https://bitbucket.org/allr/mxtool2), 27 Our typicial sample language is called the SimpleLanguage. A good entry point for
23 which is part of this repository. To build Truffle execute: 28 exploring SimpleLanguage is the [SLLanguage class](https://github.com/graalvm/Truffle/blob/master/truffle/com.oracle.truffle.sl/src/com/oracle/truffle/sl/SLLanguage.java).
29 In addition to that here are links to presentations, FAQs and papers about
30 Graal and Truffle:
31
32 - [Truffle Tutorials and Presentations](https://wiki.openjdk.java.net/display/Graal/Publications+and+Presentations)
33 - [Truffle FAQ and Guidelines](https://wiki.openjdk.java.net/display/Graal/Truffle+FAQ+and+Guidelines)
34 - [Graal VM and Truffle/JS](http://www.oracle.com/technetwork/oracle-labs/program-languages/overview/index-2301583.html) on the Oracle Technology Network
35 - [Papers on Truffle](http://ssw.jku.at/Research/Projects/JVM/Truffle.html)
36 - [Papers on Graal](http://ssw.jku.at/Research/Projects/JVM/Graal.html)
37
38 ## Hacking Truffle
39
40 Truffle and Graal use the [MX build tool](https://bitbucket.org/allr/mx),
41 which needs to be installed before using this repository. To do so execute
42 in a clean directory:
24 43
25 ```bash 44 ```bash
26 ./mx.sh build 45 $ hg clone https://bitbucket.org/allr/mx
46 $ mx/mx
47 ```
48
49 the mx/*mx* command is a wrapper around Python script that serves as our build tool.
50 Make sure you put it onto your ''PATH'' and then you can work with Truffle
51 sources from a command line:
52
53 ```bash
54 $ mx clean
55 $ mx build
56 $ mx unittest
27 ``` 57 ```
28 58
29 The created `./build` directory contains all necessary jars and source bundles. 59 The created `./build` directory contains all necessary jars and source bundles.
30 60
31 - `truffle-api.jar` contains the framework 61 - `truffle-api.jar` contains the framework
32 - `truffle-dsl-processor.jar` contains the TruffleDSL annotation processor 62 - `truffle-dsl-processor.jar` contains the TruffleDSL annotation processor
33 63
34 ### Maven 64 You can open Truffle sources in your favorite Java IDE by invoking:
35 65
36 For Maven based projects, prebuilt binaries can be included into a project by 66 ```bash
37 adding the following dependencies to a `pom.xml`: 67 $ mx ideinit
68 ```
69
70 the necessary IDE metadata will then be generated into *truffle* subdirectory
71 and its folders.
72
73 *mx* supports Maven integration. To register prebuilt binaries into local Maven
74 repository you can invoke:
75
76 ```bash
77 $ mx build
78 $ mx maven-install
79 ```
80
81 and then it is possible to include the artifacts as dependencies to a `pom.xml`:
38 82
39 ```xml 83 ```xml
40 <dependency> 84 <dependency>
41 <groupId>com.oracle</groupId> 85 <groupId>com.oracle</groupId>
42 <artifactId>truffle</artifactId> 86 <artifactId>truffle</artifactId>
48 <version>0.8</version> 92 <version>0.8</version>
49 <scope>provided</scope> 93 <scope>provided</scope>
50 </dependency> 94 </dependency>
51 ``` 95 ```
52 96
53 ## Resources and Documentation
54
55 This repository contains the SimpleLanguage, which comes with JavaDoc
56 documentation to demonstrate how Truffle is used. A good entry point for
57 exploring SimpleLanguage is the [SLLanguage class](https://github.com/OracleLabs/Truffle/blob/master/truffle/com.oracle.truffle.sl/src/com/oracle/truffle/sl/SLLanguage.java).
58
59 - [Truffle Tutorials and Presentations](https://wiki.openjdk.java.net/display/Graal/Publications+and+Presentations)
60 - [Truffle FAQ and Guidelines](https://wiki.openjdk.java.net/display/Graal/Truffle+FAQ+and+Guidelines)
61 - [Graal VM and Truffle/JS](http://www.oracle.com/technetwork/oracle-labs/program-languages/overview/index-2301583.html) on the Oracle Technology Network
62 - [Papers on Truffle](http://ssw.jku.at/Research/Projects/JVM/Truffle.html)
63 - [Papers on Graal](http://ssw.jku.at/Research/Projects/JVM/Graal.html)
64
65 ## Contributing 97 ## Contributing
66 98
67 TODO 99 You can contact the Truffle developers at graal-dev@openjdk.java.net mailing
68 100 list.
69 101
70 ## License 102 ## License
71 103
72 The Truffle framework is licensed under the [GPL 2 with Classpath exception](http://openjdk.java.net/legal/gplv2+ce.html). 104 The Truffle framework is licensed under the [GPL 2 with Classpath exception](http://openjdk.java.net/legal/gplv2+ce.html).
73 The SimpleLanguage is licensed under the [Universal Permissive License (UPL)](http://opensource.org/licenses/UPL). 105 The SimpleLanguage is licensed under the [Universal Permissive License (UPL)](http://opensource.org/licenses/UPL).