Commit Graph

114 Commits

Author SHA1 Message Date
Alexey Andreev
32ae1ab8f0 js: fix deobfuscator, use new ES2015 module builder 2024-03-13 15:44:18 +01:00
Alexey Andreev
582fcf904c jso: implement vararg support for method calls 2024-03-12 18:56:19 +01:00
Alexey Andreev
ccfe19994b js: refactor and simplify AstWriter, properly fix case with variable in catch block 2024-03-06 20:24:35 +01:00
Alexey Andreev
e4452152b7 jso: improve JS class import to Java 2024-02-27 20:16:10 +01:00
Alexey Andreev
8db406c603 jso: implement exporting Java methods to JS
Fix #785
2024-02-15 21:00:10 +01:00
Alexey Andreev
6ac598b927 js: add limit for top-level declarations
Rationale: turns out that V8 utilizes stack even to represent module-level functions.
This can cause SOE when there's too many classes and methods in source JVM
2024-02-01 09:41:50 +01:00
Alexey Andreev
a9af6e4f33 JSO: fix wrapping undefined value 2023-12-07 10:02:30 +01:00
Alexey Andreev
067f7453fe JS: a better fix for wrapping/unwrapping JS objects implemented in Java 2023-11-27 13:05:51 +01:00
Alexey Andreev
9757213379 JS: fix unwrapping JS objects implemented in Java 2023-11-26 21:57:19 +01:00
Alexey Andreev
be53236d23 JS: fix wrapping keys for native indexers 2023-11-20 20:33:47 +01:00
Alexey Andreev
6738d6f1f8 JS: add remembering source writer, refactor PreparedMethod and Renderer to use it, get rid of $rt_globals 2023-11-02 19:03:10 +01:00
Alexey Andreev
23ad999bbd JS: get rid of IOException in SourceWriter and related classes 2023-10-31 20:09:55 +01:00
Alexey Andreev
32ee8943c1 JS: rewrite more natives with templates, get rid of runtime aliases in minification mode 2023-10-31 19:29:32 +01:00
Alexey Andreev
a1cc817504 JS: rewrite more native generators with templates, fix issues in template engine 2023-10-29 20:17:18 +01:00
Alexey Andreev
7acc81ce4d JS: remove lazy creation of primitive classes 2023-10-21 20:07:49 +02:00
Alexey Andreev
02b3c92912 JS: use native string to represent internals of java.lang.String 2023-10-21 19:30:16 +02:00
Alexey Andreev
772dd9eded JS: fix returning JSO objects from Async methods
Fix #805
2023-10-12 21:13:09 +02:00
Alexey Andreev
eed44998f0 jso: trying to improve optimization of JSWrapper 2023-09-27 13:50:30 +02:00
Alexey Andreev
b9f5e9be1c JS: optimize case when JS method returns java.lang.Object and then treated as JS object 2023-08-04 20:40:57 +02:00
Alexey Andreev
35f1284ac5 js: fix issue in obfuscated mode 2023-08-04 10:27:44 +02:00
Alexey Andreev
f30a050bfd JS: relax several JSO declarations to accept Object instead of JSObject 2023-08-03 20:50:22 +02:00
Alexey Andreev
334e2829b3 JS: supports module imports in JSBody 2023-08-03 15:42:15 +02:00
Alexey Andreev
a1ed797d73 JS: allow passing Object to JS methods 2023-07-31 20:42:09 +02:00
Alexey Andreev
4cfbca96b8 JS: fix visibility modifier for consistency 2023-07-31 13:13:35 +02:00
Alexey Andreev
c4c6b029e3 JS: add support for exporting Java methods as JS properties 2023-07-30 20:48:43 +02:00
Alexey Andreev
948244cbf4 JS: marshall JS object to Java in a wrapper 2023-07-29 18:54:23 +02:00
Alexey Andreev
8014c038c0 Migrate to gradle 2023-01-23 17:16:07 +01:00
Alexey Andreev
64ae44ee01 JS: store global object in a variable to avoid name clashes between generated declarations (in minified mode) and global declarations 2022-11-17 12:02:46 +01:00
Alexey Andreev
81bfe3f6e2 Improve pom.xml configuration 2021-03-18 11:16:41 +03:00
Alexey Andreev
195f4c8426 Fix checkstyle error 2021-03-18 00:12:42 +03:00
Alexey Andreev
4c0c7872a1 JS: add support for CCE in strict mode 2021-03-17 21:11:18 +03:00
Alexey Andreev
d76eeb9be3 Improve <clinit> elimination. Improve inlining in ADVANCED optimization mode 2020-02-14 12:46:57 +03:00
Alexey Andreev
fb78377db8 Fix various issues reported by PVS Studio and LGTM 2019-10-31 14:36:37 +03:00
Alexey Andreev
f0b6cc2f30 Update version to 0.7.0 2019-09-24 16:26:14 +03:00
Alexey Andreev
62b3c68a5b Don't report compile-0time error when there's possible way to reach suspension point. Generate runtime error instead. 2019-06-22 23:30:05 +03:00
Alexey Andreev
ca50f72fe9 Fix displaying diagnostics in out-of-process mode 2019-05-14 14:46:44 +03:00
Alexey Andreev
f33c90f778 Improve <clinit> elimination:
* Generate clinit instruction instead of calling <clinit>
  directly
* Rename annotation that indicates absence of side effects
* Don't apply this annotation automatically to all JSBody methods
2019-03-24 12:54:06 +03:00
Alexey Andreev
de84105241 Call <clinit> methods before main method when possible, eliminate
lazy class initialization for these <clinit> methods.
2019-03-22 19:40:56 +03:00
Alexey Andreev
ac627580c6 JS: Support JSByRef annotation on method return types 2019-03-21 18:09:38 +03:00
Alexey Andreev
68522811f2 Fix issue with incremental compilation and JSBody annotation 2019-01-23 19:24:42 +03:00
Alexey Andreev
9305a532bb Replace ArrayList with array to store arguments of InvokeInstruction 2019-01-09 12:51:52 +03:00
Alexey Andreev
f589b0035a Decrease memory consumption 2018-12-29 19:02:03 +03:00
Alexey Andreev
d74bcbe2b9 Fast dependency analyzer, fix bugs in incremental compiler 2018-12-07 17:41:21 +03:00
Alexey Andreev
a3dfc0c486 Add API to catch native JS exceptions 2018-11-23 19:54:37 +03:00
Alexey Andreev
753755918d Update build config to avoid jar hell 2018-11-22 14:49:30 +03:00
Alexey Andreev
fc799afcda Add Maven option to run TeaVM in a separate process 2018-11-20 14:22:35 +03:00
Alexey Andreev
e5c85dd3bd Prevent inlining of JSBody code in some complex cases 2018-11-16 19:04:15 +03:00
Alexey Andreev
4d2c075c07 Always embed runtime into generated file. Remove 'runtime' build property 2018-10-28 00:15:36 +03:00
Alexey Andreev
6551f3eb68 Make JS function out of JS object when casting to JSFunctor interface 2018-10-24 14:30:26 +03:00
Alexey Andreev
b66053f5ce Don't generate virtual wrappers for methods that aren't ever called virtually 2018-10-04 11:55:34 +03:00