native-code

ART prevents any Java calls from JNI during native signal handling

我只是一个虾纸丫 提交于 2019-11-26 17:07:46
问题 My project use a module of capturing crash and send in android system. When handling the native crash, native code will do something and then do java calls from JNI. It works well on the Dalvik. But it fails in android version above 5.0 using ART. Because ART prevents any Java calls from JNI during native signal handling. It says that ART signal handling uses alternate signal stack, so during the process of signal handing, can't call java methods? Is there any other ways?? Flow: 1. Java call

Compile JavaScript to Native Code with V8

眉间皱痕 提交于 2019-11-26 16:41:14
问题 Is it really possible, with Google's V8 Engine, to compile JavaScript into Native Code, save it as a binary file, and execute it whenever I want through my software envorinment, on any machine? 回答1: You can use the V8 snapshot functionality to precompile the code. This still means that you have to have a full version of V8 running to load the snapshot (i.e., you don't get stand-alone native code, it needs to run inside the V8 VM), so all you save is the compilation time. Also, the quality of

Can I compile Java to native code?

风流意气都作罢 提交于 2019-11-26 15:50:46
问题 Is there any way to compile from Java to standalone (or library) machine code without requiring a JVM? 回答1: There used to be a tool called GCJ that was part of GCC, but it's been removed. Now, all the links in the GCC site re-direct to their non-GCJ equivalents. NB: the comments all refered to my original answer saying you can compile Java to native code with GCJ. 回答2: Excelsior JET is a commercial Java to native code compiler. 回答3: Yes! Oracle has been working on the GraalVm, which supports

Is there a native machine code compiler for JavaScript? [closed]

倖福魔咒の 提交于 2019-11-26 15:40:07
问题 Is there a native machine code compiler for JavaScript? I'm not talking about a VM. If it doesn't exist can it be done? I am wondering if it can be compiled to binary due to the dynamic nature of the language. 回答1: As far as I know, there are no static compilers for JavaScript. It is certainly theoretically possible; however, a static compilation of JavaScript would need a very heavyweight runtime to support all of its features (such as dynamic typing and eval). As a small aside, when

How to compile a .NET application to native code?

偶尔善良 提交于 2019-11-26 14:09:47
If I want to run a .NET application in a machine where the .NET framework is not available; Is there any way to compile the application to native code? Microsoft has an article describing how you can Compile MSIL to Native Code You can use Ngen . The Native Image Generator (Ngen.exe) is a tool that improves the performance of managed applications. Ngen.exe creates native images, which are files containing compiled processor-specific machine code, and installs them into the native image cache on the local computer. The runtime can use native images from the cache instead using the just-in-time

How to compile a .NET application to native code?

回眸只為那壹抹淺笑 提交于 2019-11-26 03:49:03
问题 If I want to run a .NET application in a machine where the .NET framework is not available; Is there any way to compile the application to native code? 回答1: Microsoft has an article describing how you can Compile MSIL to Native Code You can use Ngen. The Native Image Generator (Ngen.exe) is a tool that improves the performance of managed applications. Ngen.exe creates native images, which are files containing compiled processor-specific machine code, and installs them into the native image

How to use addr2line in Android

本小妞迷上赌 提交于 2019-11-26 01:48:29
问题 I am stuck with my app, as I am unable to debug as it is a multithreaded one and crashes with error SIGSEGV. I get lot of information from LogCat, which gives me addresses in my native library. It would be helpful if I could convert these addresses into my code. Does anybody have any idea how to use addr2line, which is provided with android-ndk? 回答1: Let's say that logcat show you the following crash log (this is from one of my projects): I/DEBUG ( 31): *** *** *** *** *** *** *** *** *** ***

How to use addr2line in Android

可紊 提交于 2019-11-25 23:33:06
I am stuck with my app, as I am unable to debug as it is a multithreaded one and crashes with error SIGSEGV. I get lot of information from LogCat, which gives me addresses in my native library. It would be helpful if I could convert these addresses into my code. Does anybody have any idea how to use addr2line, which is provided with android-ndk? Let's say that logcat show you the following crash log (this is from one of my projects): I/DEBUG ( 31): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** I/DEBUG ( 31): Build fingerprint: 'generic/sdk/generic:2.3/GRH55/79397:eng/test