diff options
author | Luite Stegeman <stegeman@gmail.com> | 2023-01-03 12:06:48 +0900 |
---|---|---|
committer | Luite Stegeman <stegeman@gmail.com> | 2023-01-06 18:16:24 +0900 |
commit | 28f8c0ebbfe623784988745af75dcf3fdbdd3ca5 (patch) | |
tree | a9461a0de296bdd2dbe6cba66db866235ce2cba9 /compiler/Language/Haskell/Syntax/Module | |
parent | b2a2db04b24a4654261db8e0db6ad7bac1b3d7cf (diff) | |
download | haskell-28f8c0ebbfe623784988745af75dcf3fdbdd3ca5.tar.gz |
Add support for sized literals in the bytecode interpreter.
The bytecode interpreter only has branching instructions for
word-sized values. These are used for pattern matching.
Branching instructions for other types (e.g. Int16# or Word8#)
weren't needed, since unoptimized Core or STG never requires
branching on types like this.
It's now possible for optimized STG to reach the bytecode
generator (e.g. fat interface files or certain compiler flag
combinations), which requires dealing with various sized
literals in branches.
This patch improves support for generating bytecode from
optimized STG by adding the following new bytecode
instructions:
TESTLT_I64
TESTEQ_I64
TESTLT_I32
TESTEQ_I32
TESTLT_I16
TESTEQ_I16
TESTLT_I8
TESTEQ_I8
TESTLT_W64
TESTEQ_W64
TESTLT_W32
TESTEQ_W32
TESTLT_W16
TESTEQ_W16
TESTLT_W8
TESTEQ_W8
Fixes #21945
Diffstat (limited to 'compiler/Language/Haskell/Syntax/Module')
0 files changed, 0 insertions, 0 deletions