haikuwebkit/Source/JavaScriptCore/llint
Mark Lam c209a4cab6 Add some offlineasm enhancements.
https://bugs.webkit.org/show_bug.cgi?id=229332
rdar://82163923

Reviewed by Keith Miller.

1. Enhance "include" offlineasm Instruction to always attempt to include an asm
   file from <build-products>/usr/local/include/WebKitAdditions/ first.  If the
   specified file is not available there, then it will attempt to include the file
   from the same directory as the current source file (which in practice, means
   Source/JavaScriptCore/llint/).

2. Enhance "include" offlineasm Instruction to allow an optional file to be
   included if it exists.  For example, the following offlineasm code:

        include? LowLevelInterpreterAdditions

   ... will attempt to include a file LowLevelInterpreterAdditions.asm.  If the
   file does not exist, this will be a no-op.  Note: the "?" after the "include"
   means the include is optional.

3. Enhanced "emit" offlineasm Instruction to be able to take more than one operand.

   "emit" used to just copy the string operand that follows into the generated
   LLIntAssembly.h.  Now, "emit" can take multiple comma separated operands, and
   will concatenate all the operands.

   Additionally, "emit" can now take a LocalLabelReference as an operand.  For
   example, this offline asm code:

           emit "b ", .done
           ...
        .done:

   ... will generate this inline asm code in LLIntAssembly.h:

        "b " LOCAL_LABEL_STRING(_offlineasm_someLabel_done) "\n"

   This makes it easier to emit branches to local labels.

4. Also fixed LLInt code alignment for ARM_THUMB2 and ARM64.

   Previously, it was aligned using ".align 4" which means aligned on a 4
   instruction boundary.  Note: the interpretation of .align varies for different
   target CPU architectures.

   Now, we do the alignment using ".balign 4" which means align on a 4 byte
   boundary.  This is the intended alignment because ARM64 instruction size is
   4 bytes, and ARM_THUMB2 instruction size is either 2 bytes or 4 bytes.
   Using .align before was potentially wasting some code space.

* llint/LowLevelInterpreter.asm:
* llint/LowLevelInterpreter.cpp:
* offlineasm/ast.rb:
* offlineasm/parser.rb:



Canonical link: https://commits.webkit.org/240738@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@281321 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2021-08-20 17:01:00 +00:00
..
LLIntCLoop.cpp
LLIntCLoop.h
LLIntCommon.h
LLIntData.cpp [JSC] JITCage's Gate mechanism is used in ARM64E even if JITCage is disable 2021-01-11 05:40:00 +00:00
LLIntData.h We should not static_assert on an ENABLE() macro. 2021-02-10 22:00:54 +00:00
LLIntEntrypoint.cpp [JSC] JITCage's Gate mechanism is used in ARM64E even if JITCage is disable 2021-01-11 05:40:00 +00:00
LLIntEntrypoint.h [JSC] Add JITCage support 2020-11-04 02:31:56 +00:00
LLIntExceptions.cpp Non-unified build fixes, mid October 2020 2020-10-14 20:46:32 +00:00
LLIntExceptions.h Non-unified build fixes, mid October 2020 2020-10-14 20:46:32 +00:00
LLIntOfflineAsmConfig.h [JSC] Allow to build WebAssembly without B3 2021-01-23 12:32:22 +00:00
LLIntOffsetsExtractor.cpp [WTF] Introduce FixedVector and use it for FixedOperands 2021-04-06 19:47:47 +00:00
LLIntOpcode.h
LLIntPCRanges.h Unreviewed, relanding r269940 2020-11-18 20:22:16 +00:00
LLIntSettingsExtractor.cpp
LLIntSlowPaths.cpp Unreviewed, reverting r279546, r279554, r279558 and r279567. 2021-07-07 03:12:05 +00:00
LLIntSlowPaths.h Adding missing REFERENCED_FROM_ASM annotations to facilitate LTO 2021-08-09 10:53:05 +00:00
LLIntThunks.cpp Enhance Link Buffer stats to have more fine grain profiles, and to collect count information. 2021-05-23 06:07:01 +00:00
LLIntThunks.h REGRESSION(r274724): JITCage trampoline needs to be adjusted 2021-04-01 23:06:51 +00:00
LowLevelInterpreter.asm Add some offlineasm enhancements. 2021-08-20 17:01:00 +00:00
LowLevelInterpreter.cpp Add some offlineasm enhancements. 2021-08-20 17:01:00 +00:00
LowLevelInterpreter.h
LowLevelInterpreter32_64.asm Add LLInt fast path for less, lesseq, greater and greatereq 2021-06-28 17:55:12 +00:00
LowLevelInterpreter64.asm for-in should only emit one loop in bytecode 2021-08-07 21:38:59 +00:00
WebAssembly.asm [WASM-Function-References] Add call_ref instruction 2021-05-03 11:00:43 +00:00