Commit Graph

2343 Commits

Author SHA1 Message Date
Alexander Gorshenev 2a246a9a3a Some tests for inline members. 2017-05-17 22:04:32 +03:00
Nikolay Igotti c6d13abddc Small cleanup in demos (#572) 2017-05-17 01:00:03 +03:00
Igor Chevdar 8a789a9ac4 Added test on function overriding return type with Unit 2017-05-16 16:30:29 +03:00
Igor Chevdar bdb185ee93 Added bridge for functions overriding return type with Unit 2017-05-16 16:30:29 +03:00
Konstantin Anisimov 3e35db5a51 Generate artificial return for inlined constructor 2017-05-16 19:24:52 +07:00
Igor Chevdar e15878bfe9 Fresh box tests 2017-05-15 15:24:58 +03:00
Ilya Matveev 12847428fa samples: Install Tensorflow in HOME directory 2017-05-15 18:31:30 +07:00
Ilya Matveev d28f8ce7f2 samples: Add scripts for samples building
This pach adds a root gradle project in the samples directory
which allows one to build all gradle samples using `./gradlew build`
command. It also adds a shell script in the samples directory which
can build all samples (excluding tensorflow one) using their build.sh
scripts.
2017-05-15 18:31:30 +07:00
Ilya Matveev 8ee788e6b5 gradle-plugin: Add dist target 2017-05-15 18:31:30 +07:00
Ilya Matveev 50ba283aaa gradle-plugin: Use a separate directory for compiled stubs
Two tasks (stub-generator and stub-compiler) used the same output
directory. It caused some problems with up-to-date checks: the
stub-generator task might rerun even if it's inputs isn't changed.
The patch uses separate directories for this tasks to fix this issue.
2017-05-15 18:31:30 +07:00
Ilya Matveev 43582acbf1 gradle-plugin: Don't set LIBRARY_PATH variables for stub-generator 2017-05-15 18:31:30 +07:00
SvyatoslavScherbina 5bd10dc112 Fix generating interop stubs for vararg functions with pointer retval (#569) 2017-05-11 18:54:31 +03:00
Alexander Gorshenev b5fcf0087b Print deserializer failure stack trace only if verbose mode is on. 2017-05-11 18:24:18 +03:00
Svyatoslav Scherbina 8c6718ab91 Always use at least register-sized buffer for return value in ffi_call
As required by the libffi docs.
2017-05-11 13:27:43 +03:00
Igor Chevdar 8f53018653 Disabled warning that coroutines are experimental 2017-05-11 12:51:05 +03:00
Igor Chevdar 29c30545e5 Coroutines lowering: fixed bug appeared after merging with IR symbols 2017-05-11 11:37:32 +03:00
Igor Chevdar 81a0aa1861 Coroutines: added SequenceBuilder 2017-05-11 11:37:32 +03:00
Alexander Gorshenev 5d1e6acb7c Mangle "*" as #STAR, rather than an explicit variance plus a bound. 2017-05-10 19:30:22 +03:00
Igor Chevdar 33189b079f Reused C macroses by defining bridges to them in def file 2017-05-10 18:33:04 +03:00
Igor Chevdar ec34adc66c Non-blocking echo server 2017-05-10 18:33:04 +03:00
Igor Chevdar 39d1b8956d Test on abstract bridge 2017-05-10 15:44:22 +03:00
Igor Chevdar 97fe5c6b46 Abstract methods can also have bridges 2017-05-10 15:44:22 +03:00
Konstantin Anisimov 42b1414014 Code formatting 2017-05-10 18:31:02 +07:00
Konstantin Anisimov 715db233f9 Code formatting 2017-05-10 18:31:02 +07:00
Konstantin Anisimov eba8a50c43 Code formatting 2017-05-10 18:31:02 +07:00
Konstantin Anisimov ba1f3d502e Use annotation to distinct inline constructor 2017-05-10 18:31:02 +07:00
Konstantin Anisimov 31a24d4607 Replace DelegatingConstructorCall with IrCall
Replace "this" with result of IrCall
2017-05-10 18:31:02 +07:00
Vasily Levchenko 1baf906579 .gitignore: add .iml files 2017-05-10 12:46:13 +03:00
Vasily Levchenko 432a2c1dda CODEGEN: typo missed int type 2017-05-10 10:52:28 +03:00
Ilya Matveev 6f9af1c6a1 gradle-plugin: Revert target renaming 2017-05-10 14:31:02 +07:00
Ilya Matveev 739eb6233a Revert "gradle-plugin: Rename targets"
This reverts commit 7a1a5001a3.
2017-05-10 14:31:02 +07:00
Ilya Matveev 0a7e38c25a Revert "samples: Rename targets for tetris build."
This reverts commit dbcfa84498.
2017-05-10 14:31:02 +07:00
Ilya Matveev da6be1f1f7 Revert "samples: Use camel case in tetris gradle build script"
This reverts commit 409d00db96.
2017-05-10 14:31:02 +07:00
SvyatoslavScherbina 88e3c1d05c Implement parsing additional interop header directly from .def file (#557) 2017-05-09 19:48:19 +03:00
Svyatoslav Scherbina c2d556503d Fix bug in function inlining
Fake overrides have IR now, so their declarations can be found by inliner
but are fake and thus unusable.
2017-05-08 13:31:45 +03:00
Svyatoslav Scherbina 68e6ff614d Fix bug in local declarations lowering
IrCall doesn't provide `.shallowCopy` now, so the unreachable buggy code
became reachable.
2017-05-08 13:31:45 +03:00
Svyatoslav Scherbina 0b1e7c9526 Update compiler to IR with symbols, part 1
The produced symbols are currently unbound and thus useless.
2017-05-08 13:31:45 +03:00
Julius Kunze c3074db2d0 Improved build script for tensorflow example, fixed readme (#553) 2017-05-06 09:44:19 +03:00
Ilya Matveev 409d00db96 samples: Use camel case in tetris gradle build script 2017-05-05 19:40:21 +07:00
Ilya Matveev 660f7bc1d4 gradle-plugin: Use konanVersion as plugin version 2017-05-05 19:40:21 +07:00
Ilya Matveev c0c971a526 samples: Use latest gradle plugin version 2017-05-05 19:40:21 +07:00
Ilya Matveev ede419494a gradle-plugin: Update GRADLE_PLUGIN.md 2017-05-05 19:40:21 +07:00
Ilya Matveev dbcfa84498 samples: Rename targets for tetris build. 2017-05-05 19:40:21 +07:00
Ilya Matveev 7a1a5001a3 gradle-plugin: Rename targets
macbook -> osx
iphone -> ios
2017-05-05 19:40:21 +07:00
Ilya Matveev 00b19b8367 interop: Fix dependency downloading 2017-05-05 19:40:21 +07:00
Ilya Matveev 52bbbc1815 gradle-plugin: Specify compiler version in project properties
This patch allows gradle-plugin user to specify a compiler version
via project properties. The default version is 0.2. It also updates
samples to use this new version of gradle plugin.
2017-05-05 19:40:21 +07:00
Alexander Gorshenev 065fb6def5 Don't serialize empty packages for modules with dependencies. 2017-05-05 12:52:50 +03:00
Vasily Levchenko 9d63662fbe CODEGEN: generation type info for complex types and refactoring.
- unchecked_cast warning suppression
- move subroutineType ext function to DebugUtils.
- there is only one diType in caodegen
- generate type references for complex types if they are references
- generating array types
2017-05-04 20:35:44 +03:00
Vasily Levchenko b1462f8da6 DEBUGDEMO: refactoring & new demo of structured types.
- extract common part for easier demo introducing.
- fixed warning [-Wincompatible-pointer-types]
- demo-types
- this debug info generated for pseudo structure:
    1 /* smth here... */
    2 A {
    3 int a;
    4 int b;
    5}

    0:b-debugger-types:minamoto@unit-703(0)# llvmDebugInfoC/build/exe/demotypes/demotypes
    define i32 @main() !dbg !3 {
    entry:
      ret i32 42
      }

    !llvm.dbg.cu = !{!0}

    !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !1, producer: "konanc", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, enums: !2)
    !1 = !DIFile(filename: "<stdin>", directory: "")
    !2 = !{}
    !3 = distinct !DISubprogram(name: "main", linkageName: "main", scope: null, file: !1, line: 1, type: !4, isLocal: false, isDefinition: true, isOptimized: false, unit: !0, variables: !2)
    !4 = !DISubroutineType(types: !5)
    !5 = !{!6}
    !6 = !DICompositeType(tag: DW_TAG_structure_type, name: "A", file: !1, line: 2, size: 64, align: 32, elements: !7)
    !7 = !{!8, !10}
    !8 = !DIDerivedType(tag: DW_TAG_member, name: "a", scope: !6, file: !1, line: 3, baseType: !9, size: 32, align: 32)
    !9 = !DIBasicType(name: "int", size: 32, align: 4)
    !10 = !DIDerivedType(tag: DW_TAG_member, name: "b", scope: !6, file: !1, line: 4, baseType: !9, size: 32, align: 32, offset: 32)
2017-05-04 20:35:44 +03:00
Vasily Levchenko dc8bcc677a DEBUGINFO: binding enchancement && composite type support
- structured datatypes usable in debug info
- bindings for llvm/Support/Dwarf.h (llvm 3.9) makes easier introducing dwarf constants from LLVM
- added HANDLE_DW_LANG generating sequence DW_LANGs (DW_LANG_Kotlin equals DW_LANG_C89 for now).
- refactoring : g/c typo
- tag (DwarfTag) of the type added as parameter in DICreateReplaceableCompositeType
- binding for creating reference type
- binding for creating array type.
2017-05-04 20:35:44 +03:00