Assume that I am writing a compiler with an asm.js-backend. In order to generate the most efficient code, I'd like to know how the generated asm.js code is translated to machine code. Is there a way to dump the (x86-64 in my case) assembly generated by OdinMonkey with a SpiderMonkey build like here: https://developer.mozilla.org/en-US/docs/SpiderMonkey/Build_Documentation?
Optimize for asm.js in OdinMonkey
398 Views Asked by Marc At
1
There are 1 best solutions below
Related Questions in JAVASCRIPT
- Using Puppeteer to scrape a public API only when the data changes
- inline SVG text (js)
- An array of images and a for loop display the buttons. How to assign each button to open its own block by name?
- Storing the preferred font-size in localStorage
- Simple movie API request not showing up in the console log
- Authenticate Flask rest API
- Deploying sveltekit app with gunjs on vercel throws cannot find module './lib/text-encoding'
- How to request administrator rights?
- mp4 embedded videos within github pages website not loading
- Scrimba tutorial was working, suddenly stopped even trying the default
- In Datatables, start value resets to 0, when column sorting
- How do I link two models in mongoose?
- parameter values only being sent to certain columns in google sheet?
- Run main several times of wasm in browser
- Variable inside a Variable, not updating
Related Questions in ASSEMBLY
- Is there some way to use printf to print a horizontal list of decrementing hex digits in NASM assembly on Linux
- How to call a C language function from x86 assembly code?
- Binary Bomb Phase 2 - Decoding Assembly
- AVR Assembly Clock Cycle
- Understanding the differences between mov and lea instructions in x86 assembly
- ARM Assembly code is not executing in Vitis IDE
- Which version of ARM does the M1 chip run on?
- Why would %rbp not be equal to the value of %rsp, which is 0x28?
- Move immediate 8-bit value into RSI, RDI, RSP or RBP
- Unable to run get .exe file from assembly NASM
- DOSbox automatically freezes and crashes without any prompt warnings
- Load function written in amd64 assembly into memory and call it
- link.exe unresolved external symbol _mainCRTStartup
- x86 Wrote a boot loader that prints a message to the screen but the characters are completely different to what I expected
- running an imf file using dosbox in parallel to a game
Related Questions in X86
- How to call a C language function from x86 assembly code?
- the difference between two style of inline ASM
- Understanding the differences between mov and lea instructions in x86 assembly
- ARM Assembly code is not executing in Vitis IDE
- x86 - compare numbers and push the result onto the stack
- Seeking for the the method for adding the DL (data register) value to DX register
- link.exe unresolved external symbol _mainCRTStartup
- x86 Wrote a boot loader that prints a message to the screen but the characters are completely different to what I expected
- How does CPU tell between MMIO(Memory Mapped IO) and normal memory access in x86 architecture
- Why do register arg values need to be re-assigned in NASM after an int 0x80 system call?
- Why does LLVM-MCA measure an execution stall?
- Why does shr eax, 32 not do anything?
- Evaluating this in Assembly (A % B) % (C % D)
- Understanding throughput of simd sum implementation x86
- Making portable execution errors
Related Questions in SPIDERMONKEY
- FreeSWTICH Language Bundle Customization
- Do JavaScript engines have any specific optimizations for classes?
- String concatenation is not happening in JS SpiderMonkey
- V8 (or other JS engine) BigInt Implementation - Displaying as Decimal
- What was a GuardedCatchClause in the SpiderMonkey parser?
- How would i go about creating a browser using Gecko and SpiderMonkey? A FireFox eqv
- Web Audio API with SpiderMonkey?
- How to install Spidermonkey JS SHell
- Chromium (V8) vs. Firefox (SpiderMonkey) error on accessing property of undefined
- Building SpiderMonkey for Windows
- mongodb shell require a js function from another file
- Why do neither V8 nor spidermonkey seem to unroll static loops?
- Simulate JS execution to read heap memory
- Can the delphi-javascript library (js15/spidermonkey) easily be updated to mozilla's latest javascript engine version?
- Issues in using Excel.Application COMObject with Javascript and Spidermonkey (within Sparx EA)
Related Questions in ASM.JS
- I2C communication with PIC18f4321 and wii nunchuck
- How to detect when you are ready to use functions loaded in asm.js module
- Translating C++ program to JavaScript/asm.js does not produce the same sequence of numbers
- Building projects with emscripten - stuck on acorn-optimizer
- Why is WebAssembly safe and what is the linear memory model?
- Unity 2020 project building asm.js files instead of wasm
- "Invalid Heap Size" error when writing ASM.js by hand
- Assertion failed: native function `int_sqrt` called before runtime initialization error while calling c function in .js file ( emscripten )
- How this piece of ASM.js code should be evaluated by the engine?
- Why does ASM.js have no annotations for unsigned?
- LinkError: WebAssembly.instantiate() function import requires a callable
- Other than portability and security reasons, why would someone want to run their existing go/rust/c++ applications in web browsers via WebAssembly?
- link-arg not passing compiler options to rustc
- Compiled TIFF.js with Emscripten does not have access to FS
- Why asm.js is slower than normal js (prime numbers generation)? How to speed up?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular # Hahtags
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
I have just learnt that OdinMonkey does not directly generate assembler code (https://github.com/dherman/asm.js/issues/80#issuecomment-31673247) but does generate optimized MIR code for IonMonkey, which is then translated to LIR code and then to machine code.
Thus my question should have been how to dump the assembly that IonMonkey processes and outputs. For the intermediate code one can use a debug build of SpiderMonkey's js shell with IONFLAGS=logs. This gives quite a lot of information in /tmp/ion.cfg. For the assembly code, this site (https://developer.mozilla.org/en-US/docs/SpiderMonkey/Hacking_Tips) suggests to use gdb to disassemble the machine code.