@@ -0,0 +1,15 @@
|
|||||||
|
## v0.2 ##
|
||||||
|
* Added support for coroutines
|
||||||
|
* Fixed most stdlib incompatibilities
|
||||||
|
* Improved memory management performance
|
||||||
|
* Cross-module inline function support
|
||||||
|
* Unicode support independent from installed system locales
|
||||||
|
* Interoperability improvements
|
||||||
|
* file-based filtering in definition file
|
||||||
|
* stateless lambdas could be used as C callbacks
|
||||||
|
* any Unicode string could be passed to C function
|
||||||
|
* Very basic debugging support
|
||||||
|
* Improve compilation and linking performance
|
||||||
|
|
||||||
|
## v0.1 ##
|
||||||
|
Initial technical preview of Kotlin/Native.
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
Kotlin/Native #
|
# Kotlin/Native #
|
||||||
|
|
||||||
_Kotlin/Native_ is a LLVM backend for the Kotlin compiler, runtime
|
_Kotlin/Native_ is a LLVM backend for the Kotlin compiler, runtime
|
||||||
implementation and native code generation facility using LLVM toolchain.
|
implementation and native code generation facility using LLVM toolchain.
|
||||||
|
|||||||
+4
-7
@@ -31,7 +31,8 @@ the following platforms:
|
|||||||
|
|
||||||
## Compatibility and features ##
|
## Compatibility and features ##
|
||||||
|
|
||||||
To run _Kotlin/Native_ JDK8 or later for the host platform has to be installed.
|
To run _Kotlin/Native_ JDK8 for the host platform has to be installed.
|
||||||
|
Note that Java 9 not yet supported.
|
||||||
|
|
||||||
The language and library version supported by this EAP release mostly match Kotlin 1.1.
|
The language and library version supported by this EAP release mostly match Kotlin 1.1.
|
||||||
However, there are certain limitations, see section [Known Limitations](#limitations).
|
However, there are certain limitations, see section [Known Limitations](#limitations).
|
||||||
@@ -67,12 +68,8 @@ for benchmarking and competitive analysis of any kind.
|
|||||||
|
|
||||||
### Standard Library ###
|
### Standard Library ###
|
||||||
|
|
||||||
The standard library in _Kotlin/Native_ is known to be incomplete and doesn't include
|
The standard library in _Kotlin/Native_ is known to be incomplete and may not include
|
||||||
certain methods available in standard library of Kotlin.
|
few methods available in standard library of Kotlin (notably, regular expression-related).
|
||||||
|
|
||||||
### Coroutines ###
|
|
||||||
|
|
||||||
Coroutines are not yet supported with this release.
|
|
||||||
|
|
||||||
### Reflection ###
|
### Reflection ###
|
||||||
|
|
||||||
|
|||||||
@@ -19,3 +19,5 @@ Compile:
|
|||||||
Run:
|
Run:
|
||||||
|
|
||||||
./HelloTensorflow.kexe
|
./HelloTensorflow.kexe
|
||||||
|
|
||||||
|
You may need to specify `LD_LIBRARY_PATH` or `DYLD_LIBRARY_PATH` to `/opt/local/lib` if TensorFlow dynamic library cannot be found.
|
||||||
|
|||||||
@@ -2,11 +2,12 @@
|
|||||||
|
|
||||||
PATH=../../dist/bin:../../bin:$PATH
|
PATH=../../dist/bin:../../bin:$PATH
|
||||||
DIR=.
|
DIR=.
|
||||||
|
TF_TARGET_DIRECTORY="/opt/local"
|
||||||
|
|
||||||
if [ x$TARGET == x ]; then
|
if [ x$TARGET == x ]; then
|
||||||
case "$OSTYPE" in
|
case "$OSTYPE" in
|
||||||
darwin*) TARGET=macbook ;;
|
darwin*) TARGET=macbook; TF_TARGET=darwin ;;
|
||||||
linux*) TARGET=linux ;;
|
linux*) TARGET=linux; TF_TARGET=linux ;;
|
||||||
*) echo "unknown: $OSTYPE" && exit 1;;
|
*) echo "unknown: $OSTYPE" && exit 1;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
@@ -18,6 +19,15 @@ LINKER_ARGS=${!var}
|
|||||||
var=COMPILER_ARGS_${TARGET}
|
var=COMPILER_ARGS_${TARGET}
|
||||||
COMPILER_ARGS=${!var} # add -opt for an optimized build.
|
COMPILER_ARGS=${!var} # add -opt for an optimized build.
|
||||||
|
|
||||||
|
if [ ! -d $TF_TARGET_DIRECTORY/include/tensorflow ]; then
|
||||||
|
echo "Installing TensorFlow..."
|
||||||
|
TF_TYPE="cpu" # Change to "gpu" for GPU support
|
||||||
|
TF_TARGET_DIRECTORY="/opt/local"
|
||||||
|
curl -s -L \
|
||||||
|
"https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-${TF_TYPE}-${TF_TARGET}-x86_64-1.1.0.tar.gz" |
|
||||||
|
sudo tar -C $TF_TARGET_DIRECTORY -xz
|
||||||
|
fi
|
||||||
|
|
||||||
cinterop -def $DIR/tensorflow.def -copt "$CFLAGS" -target $TARGET -o tensorflow.kt.bc || exit 1
|
cinterop -def $DIR/tensorflow.def -copt "$CFLAGS" -target $TARGET -o tensorflow.kt.bc || exit 1
|
||||||
konanc $COMPILER_ARGS -target $TARGET $DIR/HelloTensorflow.kt -library tensorflow.kt.bc -o HelloTensorflow.kexe \
|
konanc $COMPILER_ARGS -target $TARGET $DIR/HelloTensorflow.kt -library tensorflow.kt.bc -o HelloTensorflow.kexe \
|
||||||
-linkerArgs "-L/usr/local/lib -ltensorflow" || exit 1
|
-linkerArgs "-L/opt/local/lib -ltensorflow" || exit 1
|
||||||
|
|||||||
@@ -1,2 +1,2 @@
|
|||||||
headers = tensorflow/c/c_api.h
|
headers = tensorflow/c/c_api.h
|
||||||
compilerOpts = -I/usr/local/include -L/usr/local/lib
|
compilerOpts = -I/opt/local/include -L/opt/local/lib
|
||||||
|
|||||||
Reference in New Issue
Block a user