update parallel rsp/rdp

This commit is contained in:
Logan McNaughton committed 2023-04-28 13:55:30 -06:00
1 parent e0b6b4f453
commit 1ab974bad3
279 files changed
+151392 -1467

No files matched your search

+26 -58
View File
@@ -4,7 +4,7 @@ set(CMAKE_OSX_DEPLOYMENT_TARGET "11.0")
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_C_STANDARD 99)
project(parallel-rsp LANGUAGES CXX C)
set(LIGHTNING_VERSION "2.2.2")
set(NAME_PLUGIN_SIMPLE64 "simple64-rsp-parallel")
@@ -22,12 +22,6 @@ if(ENABLE_IPO AND (CMAKE_BUILD_TYPE STREQUAL "Release"))
set(CMAKE_INTERPROCEDURAL_OPTIMIZATION ON)
endif()
if (CMAKE_COMPILER_IS_GNUCXX OR (${CMAKE_CXX_COMPILER_ID} MATCHES "Clang"))
set(PARALLEL_RSP_CXX_FLAGS -Wall -Wextra -Wno-missing-field-initializers -Wno-empty-body -ffast-math -Wno-unused-parameter)
elseif (MSVC)
set(PARALLEL_RSP_CXX_FLAGS /D_CRT_SECURE_NO_WARNINGS /wd4267 /wd4244 /wd4309 /wd4005 /MP /DNOMINMAX)
endif()
add_library(${NAME_PLUGIN_SIMPLE64} SHARED
parallel.cpp
rsp/vfunctions.cpp
@@ -69,62 +63,36 @@ add_library(${NAME_PLUGIN_SIMPLE64} SHARED
arch/simd/rsp/vxor.h
arch/simd/rsp/vmulm.h)
target_sources(${NAME_PLUGIN_SIMPLE64} PRIVATE
lightning-${LIGHTNING_VERSION}/lib/jit_disasm.c
lightning-${LIGHTNING_VERSION}/lib/jit_memory.c
lightning-${LIGHTNING_VERSION}/lib/jit_names.c
lightning-${LIGHTNING_VERSION}/lib/jit_note.c
lightning-${LIGHTNING_VERSION}/lib/jit_print.c
lightning-${LIGHTNING_VERSION}/lib/jit_size.c
lightning-${LIGHTNING_VERSION}/lib/lightning.c)
if (WIN32)
target_sources(${NAME_PLUGIN_SIMPLE64} PRIVATE win32/mman/sys/mman.c)
target_include_directories(${NAME_PLUGIN_SIMPLE64} PRIVATE win32/mman)
endif()
target_include_directories(${NAME_PLUGIN_SIMPLE64} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/lightning-${LIGHTNING_VERSION}/include)
target_include_directories(${NAME_PLUGIN_SIMPLE64} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/arch/simd/rsp)
set_property(TARGET ${NAME_PLUGIN_SIMPLE64} PROPERTY C_VISIBILITY_PRESET hidden)
set_property(TARGET ${NAME_PLUGIN_SIMPLE64} PROPERTY CXX_VISIBILITY_PRESET hidden)
set_property(TARGET ${NAME_PLUGIN_SIMPLE64} PROPERTY VISIBILITY_INLINES_HIDDEN ON)
set_target_properties(${NAME_PLUGIN_SIMPLE64} PROPERTIES PREFIX "")
target_include_directories(${NAME_PLUGIN_SIMPLE64} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
target_include_directories(${NAME_PLUGIN_SIMPLE64} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/arch/simd/rsp)
target_include_directories(${NAME_PLUGIN_SIMPLE64} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/api)
target_compile_options(${NAME_PLUGIN_SIMPLE64} PRIVATE ${PARALLEL_RSP_CXX_FLAGS} -Ofast)
target_compile_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -DHAVE_MMAP -Ofast)
target_link_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -DHAVE_MMAP -Ofast)
if (CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
target_compile_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -march=armv8-a)
target_compile_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -march=armv8-a)
target_link_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -march=armv8-a)
else()
target_compile_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -march=x86-64-v3)
endif()
option(PARALLEL_RSP_BAKED_LIGHTNING "Use built-in Lightning." ON)
target_compile_definitions(${NAME_PLUGIN_SIMPLE64} PUBLIC PARALLEL_RSP_LIGHTNING)
if (PARALLEL_RSP_BAKED_LIGHTNING)
add_library(lightning STATIC
lightning/lib/jit_disasm.c
lightning/lib/jit_memory.c
lightning/lib/jit_names.c
lightning/lib/jit_note.c
lightning/lib/jit_print.c
lightning/lib/jit_size.c
lightning/lib/lightning.c)
set_property(TARGET lightning PROPERTY POSITION_INDEPENDENT_CODE ON)
target_include_directories(lightning PUBLIC
${CMAKE_CURRENT_SOURCE_DIR}/lightning/include)
if (WIN32)
target_sources(lightning PRIVATE win32/mman/sys/mman.c)
target_include_directories(lightning PRIVATE win32/mman)
endif()
set_property(TARGET lightning PROPERTY C_VISIBILITY_PRESET hidden)
set_property(TARGET lightning PROPERTY CXX_VISIBILITY_PRESET hidden)
set_property(TARGET lightning PROPERTY VISIBILITY_INLINES_HIDDEN ON)
target_compile_options(lightning PRIVATE -DHAVE_MMAP -Ofast)
target_link_options(lightning PRIVATE -DHAVE_MMAP -Ofast)
if (CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
target_compile_options(lightning PRIVATE -march=armv8-a)
target_link_options(lightning PRIVATE -march=armv8-a)
else()
target_compile_options(lightning PRIVATE -march=x86-64-v3)
target_link_options(lightning PRIVATE -march=x86-64-v3)
endif()
if (NOT APPLE)
target_link_options(lightning PRIVATE -Wl,-Bsymbolic -Wl,-Bsymbolic-functions)
endif (NOT APPLE)
endif()
target_link_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -Ofast)
if (CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
target_link_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -march=armv8-a)
else()
target_link_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -march=x86-64-v3)
target_compile_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -march=x86-64-v3)
target_link_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -march=x86-64-v3)
endif()
if (NOT APPLE)
target_link_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -Wl,-Bsymbolic -Wl,-Bsymbolic-functions)
target_link_options(${NAME_PLUGIN_SIMPLE64} PRIVATE -Wl,-Bsymbolic -Wl,-Bsymbolic-functions)
endif (NOT APPLE)
target_link_libraries(${NAME_PLUGIN_SIMPLE64} PUBLIC lightning)
set_target_properties(${NAME_PLUGIN_SIMPLE64} PROPERTIES PREFIX "")
@@ -0,0 +1,713 @@
# Makefile.in generated by automake 1.16.5 from Makefile.am.
# include/Makefile. Generated from Makefile.in by configure.
# Copyright (C) 1994-2021 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
#
# Copyright 2000, 2001, 2002, 2012-2023 Free Software Foundation, Inc.
#
# This file is part of GNU lightning.
#
# GNU lightning is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 3, or (at your option)
# any later version.
#
# GNU lightning is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
# License for more details.
#
am__is_gnu_make = { \
if test -z '$(MAKELEVEL)'; then \
false; \
elif test -n '$(MAKE_HOST)'; then \
true; \
elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
true; \
else \
false; \
fi; \
}
am__make_running_with_option = \
case $${target_option-} in \
?) ;; \
*) echo "am__make_running_with_option: internal error: invalid" \
"target option '$${target_option-}' specified" >&2; \
exit 1;; \
esac; \
has_opt=no; \
sane_makeflags=$$MAKEFLAGS; \
if $(am__is_gnu_make); then \
sane_makeflags=$$MFLAGS; \
else \
case $$MAKEFLAGS in \
*\\[\ \ ]*) \
bs=\\; \
sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
| sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
esac; \
fi; \
skip_next=no; \
strip_trailopt () \
{ \
flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
}; \
for flg in $$sane_makeflags; do \
test $$skip_next = yes && { skip_next=no; continue; }; \
case $$flg in \
*=*|--*) continue;; \
-*I) strip_trailopt 'I'; skip_next=yes;; \
-*I?*) strip_trailopt 'I';; \
-*O) strip_trailopt 'O'; skip_next=yes;; \
-*O?*) strip_trailopt 'O';; \
-*l) strip_trailopt 'l'; skip_next=yes;; \
-*l?*) strip_trailopt 'l';; \
-[dEDm]) skip_next=yes;; \
-[JT]) skip_next=yes;; \
esac; \
case $$flg in \
*$$target_option*) has_opt=yes; break;; \
esac; \
done; \
test $$has_opt = yes
am__make_dryrun = (target_option=n; $(am__make_running_with_option))
am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
pkgdatadir = $(datadir)/lightning
pkgincludedir = $(includedir)/lightning
pkglibdir = $(libdir)/lightning
pkglibexecdir = $(libexecdir)/lightning
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = x86_64-pc-linux-gnu
host_triplet = x86_64-pc-linux-gnu
target_triplet = x86_64-pc-linux-gnu
subdir = include
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
$(top_srcdir)/m4/gnulib-common.m4 \
$(top_srcdir)/m4/gnulib-comp.m4 $(top_srcdir)/m4/libtool.m4 \
$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
$(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
$(top_srcdir)/m4/zzgnulib.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES = lightning.h
CONFIG_CLEAN_VPATH_FILES =
AM_V_P = $(am__v_P_$(V))
am__v_P_ = $(am__v_P_$(AM_DEFAULT_VERBOSITY))
am__v_P_0 = false
am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_$(V))
am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
am__v_GEN_0 = @echo " GEN " $@;
am__v_GEN_1 =
AM_V_at = $(am__v_at_$(V))
am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
am__v_at_0 = @
am__v_at_1 =
SOURCES =
DIST_SOURCES =
RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
ctags-recursive dvi-recursive html-recursive info-recursive \
install-data-recursive install-dvi-recursive \
install-exec-recursive install-html-recursive \
install-info-recursive install-pdf-recursive \
install-ps-recursive install-recursive installcheck-recursive \
installdirs-recursive pdf-recursive ps-recursive \
tags-recursive uninstall-recursive
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
*) f=$$p;; \
esac;
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
am__install_max = 40
am__nobase_strip_setup = \
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
am__nobase_strip = \
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
am__nobase_list = $(am__nobase_strip_setup); \
for p in $$list; do echo "$$p $$p"; done | \
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
if (++n[$$2] == $(am__install_max)) \
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
END { for (dir in files) print dir, files[dir] }'
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
am__uninstall_files_from_dir = { \
test -z "$$files" \
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__installdirs = "$(DESTDIR)$(includedir)"
HEADERS = $(nodist_include_HEADERS)
RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
distclean-recursive maintainer-clean-recursive
am__recursive_targets = \
$(RECURSIVE_TARGETS) \
$(RECURSIVE_CLEAN_TARGETS) \
$(am__extra_recursive_targets)
AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
distdir distdir-am
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
am__uniquify_input = $(AWK) '\
BEGIN { nonempty = 0; } \
{ items[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in items) print i; }; } \
'
# Make sure the list of sources is unique. This is necessary because,
# e.g., the same source file might be shared among _SOURCES variables
# for different programs/libraries.
am__define_uniq_tagged_files = \
list='$(am__tagged_files)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
DIST_SUBDIRS = $(SUBDIRS)
am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/lightning.h.in
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
am__relativize = \
dir0=`pwd`; \
sed_first='s,^\([^/]*\)/.*$$,\1,'; \
sed_rest='s,^[^/]*/*,,'; \
sed_last='s,^.*/\([^/]*\)$$,\1,'; \
sed_butlast='s,/*[^/]*$$,,'; \
while test -n "$$dir1"; do \
first=`echo "$$dir1" | sed -e "$$sed_first"`; \
if test "$$first" != "."; then \
if test "$$first" = ".."; then \
dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
else \
first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
if test "$$first2" = "$$first"; then \
dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
else \
dir2="../$$dir2"; \
fi; \
dir0="$$dir0"/"$$first"; \
fi; \
fi; \
dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
done; \
reldir="$$dir2"
ACLOCAL = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' aclocal-1.16
AMTAR = $${TAR-tar}
AM_DEFAULT_VERBOSITY = 0
AR = ar
ARFLAGS = cr
AUTOCONF = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' autoconf
AUTOHEADER = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' autoheader
AUTOMAKE = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' automake-1.16
AWK = gawk
CC = gcc
CCDEPMODE = depmode=gcc3
CFLAGS = -g -O2
CPP = gcc -E
CPPFLAGS =
CSCOPE = cscope
CTAGS = ctags
CYGPATH_W = echo
DEFS = -DHAVE_CONFIG_H
DEPDIR = .deps
DLLTOOL = false
DSYMUTIL =
DUMPBIN =
ECHO_C =
ECHO_N = -n
ECHO_T =
EGREP = /usr/bin/grep -E
ETAGS = etags
EXEEXT =
FGREP = /usr/bin/grep -F
FILECMD = file
GREP = /usr/bin/grep
INSTALL = /usr/bin/install -c
INSTALL_DATA = ${INSTALL} -m 644
INSTALL_PROGRAM = ${INSTALL}
INSTALL_SCRIPT = ${INSTALL}
INSTALL_STRIP_PROGRAM = $(install_sh) -c -s
LD = /usr/bin/ld -m elf_x86_64
LDFLAGS =
LIBOBJS =
LIBS = -lz
LIBTOOL = $(SHELL) $(top_builddir)/libtool
LIGHTNING_CFLAGS = -DNDEBUG
LIPO =
LN_S = ln -s
LTLIBOBJS =
LT_SYS_LIBRARY_PATH =
MAKEINFO = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' makeinfo
MANIFEST_TOOL = :
MAYBE_INCLUDE_STDINT_H = #include <stdint.h>
MKDIR_P = /usr/bin/mkdir -p
NM = /usr/bin/nm -B
NMEDIT =
OBJDUMP = objdump
OBJEXT = o
OTOOL =
OTOOL64 =
PACKAGE = lightning
PACKAGE_BUGREPORT = pcpa@gnu.org
PACKAGE_NAME = GNU lightning
PACKAGE_STRING = GNU lightning 2.2.2
PACKAGE_TARNAME = lightning
PACKAGE_URL = https://www.gnu.org/software/lightning/
PACKAGE_VERSION = 2.2.2
PATH_SEPARATOR = :
RANLIB = ranlib
SED = /usr/bin/sed
SET_MAKE =
SHELL = /bin/sh
SHLIB = -ldl
STRIP = strip
VERSION = 2.2.2
abs_builddir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/include
abs_srcdir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/include
abs_top_builddir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2
abs_top_srcdir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2
ac_ct_AR = ar
ac_ct_CC = gcc
ac_ct_DUMPBIN =
am__include = include
am__leading_dot = .
am__quote =
am__tar = $${TAR-tar} chof - "$$tardir"
am__untar = $${TAR-tar} xf -
bindir = ${exec_prefix}/bin
build = x86_64-pc-linux-gnu
build_alias =
build_cpu = x86_64
build_os = linux-gnu
build_vendor = pc
builddir = .
cpu = x86
datadir = ${datarootdir}
datarootdir = ${prefix}/share
docdir = ${datarootdir}/doc/${PACKAGE_TARNAME}
dvidir = ${docdir}
exec_prefix = ${prefix}
gl_LIBOBJS =
gl_LTLIBOBJS =
gltests_LIBOBJS =
gltests_LTLIBOBJS =
gltests_WITNESS = IN_LIGHTNING_GNULIB_TESTS
host = x86_64-pc-linux-gnu
host_alias =
host_cpu = x86_64
host_os = linux-gnu
host_vendor = pc
htmldir = ${docdir}
includedir = ${prefix}/include
infodir = ${datarootdir}/info
install_sh = ${SHELL} /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/install-sh
libdir = ${exec_prefix}/lib
libexecdir = ${exec_prefix}/libexec
localedir = ${datarootdir}/locale
localstatedir = ${prefix}/var
mandir = ${datarootdir}/man
mkdir_p = $(MKDIR_P)
oldincludedir = /usr/include
pdfdir = ${docdir}
prefix = /usr/local
program_transform_name = s,x,x,
psdir = ${docdir}
runstatedir = ${localstatedir}/run
sbindir = ${exec_prefix}/sbin
sharedstatedir = ${prefix}/com
srcdir = .
sysconfdir = ${prefix}/etc
target = x86_64-pc-linux-gnu
target_alias =
target_cpu = x86_64
target_os = linux-gnu
target_vendor = pc
top_build_prefix = ../
top_builddir = ..
top_srcdir = ..
SUBDIRS = \
lightning
nodist_include_HEADERS = lightning.h
all: all-recursive
.SUFFIXES:
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
&& { if test -f $@; then exit 0; else break; fi; }; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu include/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --gnu include/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
lightning.h: $(top_builddir)/config.status $(srcdir)/lightning.h.in
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
install-nodist_includeHEADERS: $(nodist_include_HEADERS)
@$(NORMAL_INSTALL)
@list='$(nodist_include_HEADERS)'; test -n "$(includedir)" || list=; \
if test -n "$$list"; then \
echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \
$(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \
fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
done | $(am__base_list) | \
while read files; do \
echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \
$(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \
done
uninstall-nodist_includeHEADERS:
@$(NORMAL_UNINSTALL)
@list='$(nodist_include_HEADERS)'; test -n "$(includedir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir)
# This directory's subdirectories are mostly independent; you can cd
# into them and run 'make' without going through this Makefile.
# To change the values of 'make' variables: instead of editing Makefiles,
# (1) if the variable is set in 'config.status', edit 'config.status'
# (which will cause the Makefiles to be regenerated when you run 'make');
# (2) otherwise, pass the desired values on the 'make' command line.
$(am__recursive_targets):
@fail=; \
if $(am__make_keepgoing); then \
failcom='fail=yes'; \
else \
failcom='exit 1'; \
fi; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
case "$@" in \
distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
*) list='$(SUBDIRS)' ;; \
esac; \
for subdir in $$list; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
dot_seen=yes; \
local_target="$$target-am"; \
else \
local_target="$$target"; \
fi; \
($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| eval $$failcom; \
done; \
if test "$$dot_seen" = "no"; then \
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
fi; test -z "$$fail"
ID: $(am__tagged_files)
$(am__define_uniq_tagged_files); mkid -fID $$unique
tags: tags-recursive
TAGS: tags
tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
set x; \
here=`pwd`; \
if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
include_option=--etags-include; \
empty_fix=.; \
else \
include_option=--include; \
empty_fix=; \
fi; \
list='$(SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
test ! -f $$subdir/TAGS || \
set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
fi; \
done; \
$(am__define_uniq_tagged_files); \
shift; \
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
if test $$# -gt 0; then \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
"$$@" $$unique; \
else \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$unique; \
fi; \
fi
ctags: ctags-recursive
CTAGS: ctags
ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
$(am__define_uniq_tagged_files); \
test -z "$(CTAGS_ARGS)$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
cscopelist: cscopelist-recursive
cscopelist-am: $(am__tagged_files)
list='$(am__tagged_files)'; \
case "$(srcdir)" in \
[\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
*) sdir=$(subdir)/$(srcdir) ;; \
esac; \
for i in $$list; do \
if test -f "$$i"; then \
echo "$(subdir)/$$i"; \
else \
echo "$$sdir/$$i"; \
fi; \
done >> $(top_builddir)/cscope.files
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
$(am__make_dryrun) \
|| test -d "$(distdir)/$$subdir" \
|| $(MKDIR_P) "$(distdir)/$$subdir" \
|| exit 1; \
dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
$(am__relativize); \
new_distdir=$$reldir; \
dir1=$$subdir; dir2="$(top_distdir)"; \
$(am__relativize); \
new_top_distdir=$$reldir; \
echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
($(am__cd) $$subdir && \
$(MAKE) $(AM_MAKEFLAGS) \
top_distdir="$$new_top_distdir" \
distdir="$$new_distdir" \
am__remove_distdir=: \
am__skip_length_check=: \
am__skip_mode_fix=: \
distdir) \
|| exit 1; \
fi; \
done
check-am: all-am
check: check-recursive
all-am: Makefile $(HEADERS)
installdirs: installdirs-recursive
installdirs-am:
for dir in "$(DESTDIR)$(includedir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-recursive
install-exec: install-exec-recursive
install-data: install-data-recursive
uninstall: uninstall-recursive
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-recursive
install-strip:
if test -z '$(STRIP)'; then \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
install; \
else \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
fi
mostlyclean-generic:
clean-generic:
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
clean: clean-recursive
clean-am: clean-generic clean-libtool mostlyclean-am
distclean: distclean-recursive
-rm -f Makefile
distclean-am: clean-am distclean-generic distclean-tags
dvi: dvi-recursive
dvi-am:
html: html-recursive
html-am:
info: info-recursive
info-am:
install-data-am: install-nodist_includeHEADERS
install-dvi: install-dvi-recursive
install-dvi-am:
install-exec-am:
install-html: install-html-recursive
install-html-am:
install-info: install-info-recursive
install-info-am:
install-man:
install-pdf: install-pdf-recursive
install-pdf-am:
install-ps: install-ps-recursive
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-recursive
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-recursive
mostlyclean-am: mostlyclean-generic mostlyclean-libtool
pdf: pdf-recursive
pdf-am:
ps: ps-recursive
ps-am:
uninstall-am: uninstall-nodist_includeHEADERS
.MAKE: $(am__recursive_targets) install-am install-strip
.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
check-am clean clean-generic clean-libtool cscopelist-am ctags \
ctags-am distclean distclean-generic distclean-libtool \
distclean-tags distdir dvi dvi-am html html-am info info-am \
install install-am install-data install-data-am install-dvi \
install-dvi-am install-exec install-exec-am install-html \
install-html-am install-info install-info-am install-man \
install-nodist_includeHEADERS install-pdf install-pdf-am \
install-ps install-ps-am install-strip installcheck \
installcheck-am installdirs installdirs-am maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-generic \
mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
uninstall-am uninstall-nodist_includeHEADERS
.PRECIOUS: Makefile
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
@@ -0,0 +1,20 @@
#
# Copyright 2000, 2001, 2002, 2012-2023 Free Software Foundation, Inc.
#
# This file is part of GNU lightning.
#
# GNU lightning is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 3, or (at your option)
# any later version.
#
# GNU lightning is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
# License for more details.
#
SUBDIRS = \
lightning
nodist_include_HEADERS = lightning.h
@@ -0,0 +1,713 @@
# Makefile.in generated by automake 1.16.5 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2021 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
@SET_MAKE@
#
# Copyright 2000, 2001, 2002, 2012-2023 Free Software Foundation, Inc.
#
# This file is part of GNU lightning.
#
# GNU lightning is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 3, or (at your option)
# any later version.
#
# GNU lightning is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
# License for more details.
#
VPATH = @srcdir@
am__is_gnu_make = { \
if test -z '$(MAKELEVEL)'; then \
false; \
elif test -n '$(MAKE_HOST)'; then \
true; \
elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
true; \
else \
false; \
fi; \
}
am__make_running_with_option = \
case $${target_option-} in \
?) ;; \
*) echo "am__make_running_with_option: internal error: invalid" \
"target option '$${target_option-}' specified" >&2; \
exit 1;; \
esac; \
has_opt=no; \
sane_makeflags=$$MAKEFLAGS; \
if $(am__is_gnu_make); then \
sane_makeflags=$$MFLAGS; \
else \
case $$MAKEFLAGS in \
*\\[\ \ ]*) \
bs=\\; \
sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
| sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
esac; \
fi; \
skip_next=no; \
strip_trailopt () \
{ \
flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
}; \
for flg in $$sane_makeflags; do \
test $$skip_next = yes && { skip_next=no; continue; }; \
case $$flg in \
*=*|--*) continue;; \
-*I) strip_trailopt 'I'; skip_next=yes;; \
-*I?*) strip_trailopt 'I';; \
-*O) strip_trailopt 'O'; skip_next=yes;; \
-*O?*) strip_trailopt 'O';; \
-*l) strip_trailopt 'l'; skip_next=yes;; \
-*l?*) strip_trailopt 'l';; \
-[dEDm]) skip_next=yes;; \
-[JT]) skip_next=yes;; \
esac; \
case $$flg in \
*$$target_option*) has_opt=yes; break;; \
esac; \
done; \
test $$has_opt = yes
am__make_dryrun = (target_option=n; $(am__make_running_with_option))
am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
pkgdatadir = $(datadir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkglibexecdir = $(libexecdir)/@PACKAGE@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
target_triplet = @target@
subdir = include
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
$(top_srcdir)/m4/gnulib-common.m4 \
$(top_srcdir)/m4/gnulib-comp.m4 $(top_srcdir)/m4/libtool.m4 \
$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
$(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
$(top_srcdir)/m4/zzgnulib.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES = lightning.h
CONFIG_CLEAN_VPATH_FILES =
AM_V_P = $(am__v_P_@AM_V@)
am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
am__v_P_0 = false
am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_@AM_V@)
am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
am__v_GEN_0 = @echo " GEN " $@;
am__v_GEN_1 =
AM_V_at = $(am__v_at_@AM_V@)
am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
am__v_at_1 =
SOURCES =
DIST_SOURCES =
RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
ctags-recursive dvi-recursive html-recursive info-recursive \
install-data-recursive install-dvi-recursive \
install-exec-recursive install-html-recursive \
install-info-recursive install-pdf-recursive \
install-ps-recursive install-recursive installcheck-recursive \
installdirs-recursive pdf-recursive ps-recursive \
tags-recursive uninstall-recursive
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
*) f=$$p;; \
esac;
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
am__install_max = 40
am__nobase_strip_setup = \
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
am__nobase_strip = \
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
am__nobase_list = $(am__nobase_strip_setup); \
for p in $$list; do echo "$$p $$p"; done | \
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
if (++n[$$2] == $(am__install_max)) \
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
END { for (dir in files) print dir, files[dir] }'
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
am__uninstall_files_from_dir = { \
test -z "$$files" \
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__installdirs = "$(DESTDIR)$(includedir)"
HEADERS = $(nodist_include_HEADERS)
RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
distclean-recursive maintainer-clean-recursive
am__recursive_targets = \
$(RECURSIVE_TARGETS) \
$(RECURSIVE_CLEAN_TARGETS) \
$(am__extra_recursive_targets)
AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
distdir distdir-am
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
am__uniquify_input = $(AWK) '\
BEGIN { nonempty = 0; } \
{ items[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in items) print i; }; } \
'
# Make sure the list of sources is unique. This is necessary because,
# e.g., the same source file might be shared among _SOURCES variables
# for different programs/libraries.
am__define_uniq_tagged_files = \
list='$(am__tagged_files)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
DIST_SUBDIRS = $(SUBDIRS)
am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/lightning.h.in
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
am__relativize = \
dir0=`pwd`; \
sed_first='s,^\([^/]*\)/.*$$,\1,'; \
sed_rest='s,^[^/]*/*,,'; \
sed_last='s,^.*/\([^/]*\)$$,\1,'; \
sed_butlast='s,/*[^/]*$$,,'; \
while test -n "$$dir1"; do \
first=`echo "$$dir1" | sed -e "$$sed_first"`; \
if test "$$first" != "."; then \
if test "$$first" = ".."; then \
dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
else \
first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
if test "$$first2" = "$$first"; then \
dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
else \
dir2="../$$dir2"; \
fi; \
dir0="$$dir0"/"$$first"; \
fi; \
fi; \
dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
done; \
reldir="$$dir2"
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
AR = @AR@
ARFLAGS = @ARFLAGS@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CSCOPE = @CSCOPE@
CTAGS = @CTAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
DLLTOOL = @DLLTOOL@
DSYMUTIL = @DSYMUTIL@
DUMPBIN = @DUMPBIN@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
ETAGS = @ETAGS@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
FILECMD = @FILECMD@
GREP = @GREP@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@
LDFLAGS = @LDFLAGS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
LIGHTNING_CFLAGS = @LIGHTNING_CFLAGS@
LIPO = @LIPO@
LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@
LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
MAKEINFO = @MAKEINFO@
MANIFEST_TOOL = @MANIFEST_TOOL@
MAYBE_INCLUDE_STDINT_H = @MAYBE_INCLUDE_STDINT_H@
MKDIR_P = @MKDIR_P@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
OTOOL = @OTOOL@
OTOOL64 = @OTOOL64@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_URL = @PACKAGE_URL@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
RANLIB = @RANLIB@
SED = @SED@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SHLIB = @SHLIB@
STRIP = @STRIP@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_AR = @ac_ct_AR@
ac_ct_CC = @ac_ct_CC@
ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__tar = @am__tar@
am__untar = @am__untar@
bindir = @bindir@
build = @build@
build_alias = @build_alias@
build_cpu = @build_cpu@
build_os = @build_os@
build_vendor = @build_vendor@
builddir = @builddir@
cpu = @cpu@
datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
gl_LIBOBJS = @gl_LIBOBJS@
gl_LTLIBOBJS = @gl_LTLIBOBJS@
gltests_LIBOBJS = @gltests_LIBOBJS@
gltests_LTLIBOBJS = @gltests_LTLIBOBJS@
gltests_WITNESS = @gltests_WITNESS@
host = @host@
host_alias = @host_alias@
host_cpu = @host_cpu@
host_os = @host_os@
host_vendor = @host_vendor@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
runstatedir = @runstatedir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target = @target@
target_alias = @target_alias@
target_cpu = @target_cpu@
target_os = @target_os@
target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
SUBDIRS = \
lightning
nodist_include_HEADERS = lightning.h
all: all-recursive
.SUFFIXES:
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
&& { if test -f $@; then exit 0; else break; fi; }; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu include/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --gnu include/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
lightning.h: $(top_builddir)/config.status $(srcdir)/lightning.h.in
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
install-nodist_includeHEADERS: $(nodist_include_HEADERS)
@$(NORMAL_INSTALL)
@list='$(nodist_include_HEADERS)'; test -n "$(includedir)" || list=; \
if test -n "$$list"; then \
echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \
$(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \
fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
done | $(am__base_list) | \
while read files; do \
echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \
$(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \
done
uninstall-nodist_includeHEADERS:
@$(NORMAL_UNINSTALL)
@list='$(nodist_include_HEADERS)'; test -n "$(includedir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir)
# This directory's subdirectories are mostly independent; you can cd
# into them and run 'make' without going through this Makefile.
# To change the values of 'make' variables: instead of editing Makefiles,
# (1) if the variable is set in 'config.status', edit 'config.status'
# (which will cause the Makefiles to be regenerated when you run 'make');
# (2) otherwise, pass the desired values on the 'make' command line.
$(am__recursive_targets):
@fail=; \
if $(am__make_keepgoing); then \
failcom='fail=yes'; \
else \
failcom='exit 1'; \
fi; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
case "$@" in \
distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
*) list='$(SUBDIRS)' ;; \
esac; \
for subdir in $$list; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
dot_seen=yes; \
local_target="$$target-am"; \
else \
local_target="$$target"; \
fi; \
($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| eval $$failcom; \
done; \
if test "$$dot_seen" = "no"; then \
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
fi; test -z "$$fail"
ID: $(am__tagged_files)
$(am__define_uniq_tagged_files); mkid -fID $$unique
tags: tags-recursive
TAGS: tags
tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
set x; \
here=`pwd`; \
if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
include_option=--etags-include; \
empty_fix=.; \
else \
include_option=--include; \
empty_fix=; \
fi; \
list='$(SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
test ! -f $$subdir/TAGS || \
set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
fi; \
done; \
$(am__define_uniq_tagged_files); \
shift; \
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
if test $$# -gt 0; then \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
"$$@" $$unique; \
else \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$unique; \
fi; \
fi
ctags: ctags-recursive
CTAGS: ctags
ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
$(am__define_uniq_tagged_files); \
test -z "$(CTAGS_ARGS)$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
cscopelist: cscopelist-recursive
cscopelist-am: $(am__tagged_files)
list='$(am__tagged_files)'; \
case "$(srcdir)" in \
[\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
*) sdir=$(subdir)/$(srcdir) ;; \
esac; \
for i in $$list; do \
if test -f "$$i"; then \
echo "$(subdir)/$$i"; \
else \
echo "$$sdir/$$i"; \
fi; \
done >> $(top_builddir)/cscope.files
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
$(am__make_dryrun) \
|| test -d "$(distdir)/$$subdir" \
|| $(MKDIR_P) "$(distdir)/$$subdir" \
|| exit 1; \
dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
$(am__relativize); \
new_distdir=$$reldir; \
dir1=$$subdir; dir2="$(top_distdir)"; \
$(am__relativize); \
new_top_distdir=$$reldir; \
echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
($(am__cd) $$subdir && \
$(MAKE) $(AM_MAKEFLAGS) \
top_distdir="$$new_top_distdir" \
distdir="$$new_distdir" \
am__remove_distdir=: \
am__skip_length_check=: \
am__skip_mode_fix=: \
distdir) \
|| exit 1; \
fi; \
done
check-am: all-am
check: check-recursive
all-am: Makefile $(HEADERS)
installdirs: installdirs-recursive
installdirs-am:
for dir in "$(DESTDIR)$(includedir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-recursive
install-exec: install-exec-recursive
install-data: install-data-recursive
uninstall: uninstall-recursive
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-recursive
install-strip:
if test -z '$(STRIP)'; then \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
install; \
else \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
fi
mostlyclean-generic:
clean-generic:
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
clean: clean-recursive
clean-am: clean-generic clean-libtool mostlyclean-am
distclean: distclean-recursive
-rm -f Makefile
distclean-am: clean-am distclean-generic distclean-tags
dvi: dvi-recursive
dvi-am:
html: html-recursive
html-am:
info: info-recursive
info-am:
install-data-am: install-nodist_includeHEADERS
install-dvi: install-dvi-recursive
install-dvi-am:
install-exec-am:
install-html: install-html-recursive
install-html-am:
install-info: install-info-recursive
install-info-am:
install-man:
install-pdf: install-pdf-recursive
install-pdf-am:
install-ps: install-ps-recursive
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-recursive
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-recursive
mostlyclean-am: mostlyclean-generic mostlyclean-libtool
pdf: pdf-recursive
pdf-am:
ps: ps-recursive
ps-am:
uninstall-am: uninstall-nodist_includeHEADERS
.MAKE: $(am__recursive_targets) install-am install-strip
.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
check-am clean clean-generic clean-libtool cscopelist-am ctags \
ctags-am distclean distclean-generic distclean-libtool \
distclean-tags distdir dvi dvi-am html html-am info info-am \
install install-am install-data install-data-am install-dvi \
install-dvi-am install-exec install-exec-am install-html \
install-html-am install-info install-info-am install-man \
install-nodist_includeHEADERS install-pdf install-pdf-am \
install-ps install-ps-am install-strip installcheck \
installcheck-am installdirs installdirs-am maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-generic \
mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
uninstall-am uninstall-nodist_includeHEADERS
.PRECIOUS: Makefile
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,636 @@
# Makefile.in generated by automake 1.16.5 from Makefile.am.
# include/lightning/Makefile. Generated from Makefile.in by configure.
# Copyright (C) 1994-2021 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
#
# Copyright 2000, 2001, 2002, 2012-2022 Free Software Foundation, Inc.
#
# This file is part of GNU lightning.
#
# GNU lightning is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 3, or (at your option)
# any later version.
#
# GNU lightning is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
# License for more details.
#
am__is_gnu_make = { \
if test -z '$(MAKELEVEL)'; then \
false; \
elif test -n '$(MAKE_HOST)'; then \
true; \
elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
true; \
else \
false; \
fi; \
}
am__make_running_with_option = \
case $${target_option-} in \
?) ;; \
*) echo "am__make_running_with_option: internal error: invalid" \
"target option '$${target_option-}' specified" >&2; \
exit 1;; \
esac; \
has_opt=no; \
sane_makeflags=$$MAKEFLAGS; \
if $(am__is_gnu_make); then \
sane_makeflags=$$MFLAGS; \
else \
case $$MAKEFLAGS in \
*\\[\ \ ]*) \
bs=\\; \
sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
| sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
esac; \
fi; \
skip_next=no; \
strip_trailopt () \
{ \
flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
}; \
for flg in $$sane_makeflags; do \
test $$skip_next = yes && { skip_next=no; continue; }; \
case $$flg in \
*=*|--*) continue;; \
-*I) strip_trailopt 'I'; skip_next=yes;; \
-*I?*) strip_trailopt 'I';; \
-*O) strip_trailopt 'O'; skip_next=yes;; \
-*O?*) strip_trailopt 'O';; \
-*l) strip_trailopt 'l'; skip_next=yes;; \
-*l?*) strip_trailopt 'l';; \
-[dEDm]) skip_next=yes;; \
-[JT]) skip_next=yes;; \
esac; \
case $$flg in \
*$$target_option*) has_opt=yes; break;; \
esac; \
done; \
test $$has_opt = yes
am__make_dryrun = (target_option=n; $(am__make_running_with_option))
am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
pkgdatadir = $(datadir)/lightning
pkgincludedir = $(includedir)/lightning
pkglibdir = $(libdir)/lightning
pkglibexecdir = $(libexecdir)/lightning
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = x86_64-pc-linux-gnu
host_triplet = x86_64-pc-linux-gnu
target_triplet = x86_64-pc-linux-gnu
subdir = include/lightning
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
$(top_srcdir)/m4/gnulib-common.m4 \
$(top_srcdir)/m4/gnulib-comp.m4 $(top_srcdir)/m4/libtool.m4 \
$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
$(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
$(top_srcdir)/m4/zzgnulib.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
DIST_COMMON = $(srcdir)/Makefile.am \
$(am__lightning_include_HEADERS_DIST) $(am__DIST_COMMON)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
AM_V_P = $(am__v_P_$(V))
am__v_P_ = $(am__v_P_$(AM_DEFAULT_VERBOSITY))
am__v_P_0 = false
am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_$(V))
am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
am__v_GEN_0 = @echo " GEN " $@;
am__v_GEN_1 =
AM_V_at = $(am__v_at_$(V))
am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
am__v_at_0 = @
am__v_at_1 =
SOURCES =
DIST_SOURCES =
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__lightning_include_HEADERS_DIST = jit_aarch64.h jit_alpha.h \
jit_arm.h jit_hppa.h jit_ia64.h jit_loongarch.h jit_mips.h \
jit_ppc.h jit_riscv.h jit_s390.h jit_sparc.h jit_x86.h
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
*) f=$$p;; \
esac;
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
am__install_max = 40
am__nobase_strip_setup = \
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
am__nobase_strip = \
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
am__nobase_list = $(am__nobase_strip_setup); \
for p in $$list; do echo "$$p $$p"; done | \
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
if (++n[$$2] == $(am__install_max)) \
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
END { for (dir in files) print dir, files[dir] }'
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
am__uninstall_files_from_dir = { \
test -z "$$files" \
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__installdirs = "$(DESTDIR)$(lightning_includedir)"
HEADERS = $(lightning_include_HEADERS)
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
am__uniquify_input = $(AWK) '\
BEGIN { nonempty = 0; } \
{ items[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in items) print i; }; } \
'
# Make sure the list of sources is unique. This is necessary because,
# e.g., the same source file might be shared among _SOURCES variables
# for different programs/libraries.
am__define_uniq_tagged_files = \
list='$(am__tagged_files)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
am__DIST_COMMON = $(srcdir)/Makefile.in
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' aclocal-1.16
AMTAR = $${TAR-tar}
AM_DEFAULT_VERBOSITY = 0
AR = ar
ARFLAGS = cr
AUTOCONF = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' autoconf
AUTOHEADER = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' autoheader
AUTOMAKE = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' automake-1.16
AWK = gawk
CC = gcc
CCDEPMODE = depmode=gcc3
CFLAGS = -g -O2
CPP = gcc -E
CPPFLAGS =
CSCOPE = cscope
CTAGS = ctags
CYGPATH_W = echo
DEFS = -DHAVE_CONFIG_H
DEPDIR = .deps
DLLTOOL = false
DSYMUTIL =
DUMPBIN =
ECHO_C =
ECHO_N = -n
ECHO_T =
EGREP = /usr/bin/grep -E
ETAGS = etags
EXEEXT =
FGREP = /usr/bin/grep -F
FILECMD = file
GREP = /usr/bin/grep
INSTALL = /usr/bin/install -c
INSTALL_DATA = ${INSTALL} -m 644
INSTALL_PROGRAM = ${INSTALL}
INSTALL_SCRIPT = ${INSTALL}
INSTALL_STRIP_PROGRAM = $(install_sh) -c -s
LD = /usr/bin/ld -m elf_x86_64
LDFLAGS =
LIBOBJS =
LIBS = -lz
LIBTOOL = $(SHELL) $(top_builddir)/libtool
LIGHTNING_CFLAGS = -DNDEBUG
LIPO =
LN_S = ln -s
LTLIBOBJS =
LT_SYS_LIBRARY_PATH =
MAKEINFO = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' makeinfo
MANIFEST_TOOL = :
MAYBE_INCLUDE_STDINT_H = #include <stdint.h>
MKDIR_P = /usr/bin/mkdir -p
NM = /usr/bin/nm -B
NMEDIT =
OBJDUMP = objdump
OBJEXT = o
OTOOL =
OTOOL64 =
PACKAGE = lightning
PACKAGE_BUGREPORT = pcpa@gnu.org
PACKAGE_NAME = GNU lightning
PACKAGE_STRING = GNU lightning 2.2.2
PACKAGE_TARNAME = lightning
PACKAGE_URL = https://www.gnu.org/software/lightning/
PACKAGE_VERSION = 2.2.2
PATH_SEPARATOR = :
RANLIB = ranlib
SED = /usr/bin/sed
SET_MAKE =
SHELL = /bin/sh
SHLIB = -ldl
STRIP = strip
VERSION = 2.2.2
abs_builddir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/include/lightning
abs_srcdir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/include/lightning
abs_top_builddir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2
abs_top_srcdir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2
ac_ct_AR = ar
ac_ct_CC = gcc
ac_ct_DUMPBIN =
am__include = include
am__leading_dot = .
am__quote =
am__tar = $${TAR-tar} chof - "$$tardir"
am__untar = $${TAR-tar} xf -
bindir = ${exec_prefix}/bin
build = x86_64-pc-linux-gnu
build_alias =
build_cpu = x86_64
build_os = linux-gnu
build_vendor = pc
builddir = .
cpu = x86
datadir = ${datarootdir}
datarootdir = ${prefix}/share
docdir = ${datarootdir}/doc/${PACKAGE_TARNAME}
dvidir = ${docdir}
exec_prefix = ${prefix}
gl_LIBOBJS =
gl_LTLIBOBJS =
gltests_LIBOBJS =
gltests_LTLIBOBJS =
gltests_WITNESS = IN_LIGHTNING_GNULIB_TESTS
host = x86_64-pc-linux-gnu
host_alias =
host_cpu = x86_64
host_os = linux-gnu
host_vendor = pc
htmldir = ${docdir}
includedir = ${prefix}/include
infodir = ${datarootdir}/info
install_sh = ${SHELL} /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/install-sh
libdir = ${exec_prefix}/lib
libexecdir = ${exec_prefix}/libexec
localedir = ${datarootdir}/locale
localstatedir = ${prefix}/var
mandir = ${datarootdir}/man
mkdir_p = $(MKDIR_P)
oldincludedir = /usr/include
pdfdir = ${docdir}
prefix = /usr/local
program_transform_name = s,x,x,
psdir = ${docdir}
runstatedir = ${localstatedir}/run
sbindir = ${exec_prefix}/sbin
sharedstatedir = ${prefix}/com
srcdir = .
sysconfdir = ${prefix}/etc
target = x86_64-pc-linux-gnu
target_alias =
target_cpu = x86_64
target_os = linux-gnu
target_vendor = pc
top_build_prefix = ../../
top_builddir = ../..
top_srcdir = ../..
lightning_includedir = $(includedir)/lightning
EXTRA_DIST = \
jit_private.h
#lightning_include_HEADERS = \
# jit_aarch64.h
#lightning_include_HEADERS = \
# jit_alpha.h
#lightning_include_HEADERS = \
# jit_arm.h
#lightning_include_HEADERS = \
# jit_hppa.h
#lightning_include_HEADERS = \
# jit_ia64.h
#lightning_include_HEADERS = \
# jit_loongarch.h
#lightning_include_HEADERS = \
# jit_mips.h
#lightning_include_HEADERS = \
# jit_ppc.h
#lightning_include_HEADERS = \
# jit_riscv.h
#lightning_include_HEADERS = \
# jit_s390.h
#lightning_include_HEADERS = \
# jit_sparc.h
lightning_include_HEADERS = \
jit_x86.h
all: all-am
.SUFFIXES:
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
&& { if test -f $@; then exit 0; else break; fi; }; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu include/lightning/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --gnu include/lightning/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
install-lightning_includeHEADERS: $(lightning_include_HEADERS)
@$(NORMAL_INSTALL)
@list='$(lightning_include_HEADERS)'; test -n "$(lightning_includedir)" || list=; \
if test -n "$$list"; then \
echo " $(MKDIR_P) '$(DESTDIR)$(lightning_includedir)'"; \
$(MKDIR_P) "$(DESTDIR)$(lightning_includedir)" || exit 1; \
fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
done | $(am__base_list) | \
while read files; do \
echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(lightning_includedir)'"; \
$(INSTALL_HEADER) $$files "$(DESTDIR)$(lightning_includedir)" || exit $$?; \
done
uninstall-lightning_includeHEADERS:
@$(NORMAL_UNINSTALL)
@list='$(lightning_include_HEADERS)'; test -n "$(lightning_includedir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
dir='$(DESTDIR)$(lightning_includedir)'; $(am__uninstall_files_from_dir)
ID: $(am__tagged_files)
$(am__define_uniq_tagged_files); mkid -fID $$unique
tags: tags-am
TAGS: tags
tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
set x; \
here=`pwd`; \
$(am__define_uniq_tagged_files); \
shift; \
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
if test $$# -gt 0; then \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
"$$@" $$unique; \
else \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$unique; \
fi; \
fi
ctags: ctags-am
CTAGS: ctags
ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
$(am__define_uniq_tagged_files); \
test -z "$(CTAGS_ARGS)$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
cscopelist: cscopelist-am
cscopelist-am: $(am__tagged_files)
list='$(am__tagged_files)'; \
case "$(srcdir)" in \
[\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
*) sdir=$(subdir)/$(srcdir) ;; \
esac; \
for i in $$list; do \
if test -f "$$i"; then \
echo "$(subdir)/$$i"; \
else \
echo "$$sdir/$$i"; \
fi; \
done >> $(top_builddir)/cscope.files
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
check-am: all-am
check: check-am
all-am: Makefile $(HEADERS)
installdirs:
for dir in "$(DESTDIR)$(lightning_includedir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-am
install-exec: install-exec-am
install-data: install-data-am
uninstall: uninstall-am
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-am
install-strip:
if test -z '$(STRIP)'; then \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
install; \
else \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
fi
mostlyclean-generic:
clean-generic:
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
clean-am: clean-generic clean-libtool mostlyclean-am
distclean: distclean-am
-rm -f Makefile
distclean-am: clean-am distclean-generic distclean-tags
dvi: dvi-am
dvi-am:
html: html-am
html-am:
info: info-am
info-am:
install-data-am: install-lightning_includeHEADERS
install-dvi: install-dvi-am
install-dvi-am:
install-exec-am:
install-html: install-html-am
install-html-am:
install-info: install-info-am
install-info-am:
install-man:
install-pdf: install-pdf-am
install-pdf-am:
install-ps: install-ps-am
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-am
mostlyclean-am: mostlyclean-generic mostlyclean-libtool
pdf: pdf-am
pdf-am:
ps: ps-am
ps-am:
uninstall-am: uninstall-lightning_includeHEADERS
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
clean-libtool cscopelist-am ctags ctags-am distclean \
distclean-generic distclean-libtool distclean-tags distdir dvi \
dvi-am html html-am info info-am install install-am \
install-data install-data-am install-dvi install-dvi-am \
install-exec install-exec-am install-html install-html-am \
install-info install-info-am install-lightning_includeHEADERS \
install-man install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs maintainer-clean maintainer-clean-generic \
mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
ps ps-am tags tags-am uninstall uninstall-am \
uninstall-lightning_includeHEADERS
.PRECIOUS: Makefile
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
@@ -0,0 +1,69 @@
#
# Copyright 2000, 2001, 2002, 2012-2022 Free Software Foundation, Inc.
#
# This file is part of GNU lightning.
#
# GNU lightning is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 3, or (at your option)
# any later version.
#
# GNU lightning is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
# License for more details.
#
lightning_includedir = $(includedir)/lightning
EXTRA_DIST = \
jit_private.h
if cpu_arm
lightning_include_HEADERS = \
jit_arm.h
endif
if cpu_mips
lightning_include_HEADERS = \
jit_mips.h
endif
if cpu_ppc
lightning_include_HEADERS = \
jit_ppc.h
endif
if cpu_sparc
lightning_include_HEADERS = \
jit_sparc.h
endif
if cpu_x86
lightning_include_HEADERS = \
jit_x86.h
endif
if cpu_ia64
lightning_include_HEADERS = \
jit_ia64.h
endif
if cpu_hppa
lightning_include_HEADERS = \
jit_hppa.h
endif
if cpu_aarch64
lightning_include_HEADERS = \
jit_aarch64.h
endif
if cpu_s390
lightning_include_HEADERS = \
jit_s390.h
endif
if cpu_alpha
lightning_include_HEADERS = \
jit_alpha.h
endif
if cpu_riscv
lightning_include_HEADERS = \
jit_riscv.h
endif
if cpu_loongarch
lightning_include_HEADERS = \
jit_loongarch.h
endif
@@ -0,0 +1,636 @@
# Makefile.in generated by automake 1.16.5 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2021 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
@SET_MAKE@
#
# Copyright 2000, 2001, 2002, 2012-2022 Free Software Foundation, Inc.
#
# This file is part of GNU lightning.
#
# GNU lightning is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 3, or (at your option)
# any later version.
#
# GNU lightning is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
# License for more details.
#
VPATH = @srcdir@
am__is_gnu_make = { \
if test -z '$(MAKELEVEL)'; then \
false; \
elif test -n '$(MAKE_HOST)'; then \
true; \
elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
true; \
else \
false; \
fi; \
}
am__make_running_with_option = \
case $${target_option-} in \
?) ;; \
*) echo "am__make_running_with_option: internal error: invalid" \
"target option '$${target_option-}' specified" >&2; \
exit 1;; \
esac; \
has_opt=no; \
sane_makeflags=$$MAKEFLAGS; \
if $(am__is_gnu_make); then \
sane_makeflags=$$MFLAGS; \
else \
case $$MAKEFLAGS in \
*\\[\ \ ]*) \
bs=\\; \
sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
| sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
esac; \
fi; \
skip_next=no; \
strip_trailopt () \
{ \
flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
}; \
for flg in $$sane_makeflags; do \
test $$skip_next = yes && { skip_next=no; continue; }; \
case $$flg in \
*=*|--*) continue;; \
-*I) strip_trailopt 'I'; skip_next=yes;; \
-*I?*) strip_trailopt 'I';; \
-*O) strip_trailopt 'O'; skip_next=yes;; \
-*O?*) strip_trailopt 'O';; \
-*l) strip_trailopt 'l'; skip_next=yes;; \
-*l?*) strip_trailopt 'l';; \
-[dEDm]) skip_next=yes;; \
-[JT]) skip_next=yes;; \
esac; \
case $$flg in \
*$$target_option*) has_opt=yes; break;; \
esac; \
done; \
test $$has_opt = yes
am__make_dryrun = (target_option=n; $(am__make_running_with_option))
am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
pkgdatadir = $(datadir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkglibexecdir = $(libexecdir)/@PACKAGE@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
target_triplet = @target@
subdir = include/lightning
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
$(top_srcdir)/m4/gnulib-common.m4 \
$(top_srcdir)/m4/gnulib-comp.m4 $(top_srcdir)/m4/libtool.m4 \
$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
$(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
$(top_srcdir)/m4/zzgnulib.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
DIST_COMMON = $(srcdir)/Makefile.am \
$(am__lightning_include_HEADERS_DIST) $(am__DIST_COMMON)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
AM_V_P = $(am__v_P_@AM_V@)
am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
am__v_P_0 = false
am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_@AM_V@)
am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
am__v_GEN_0 = @echo " GEN " $@;
am__v_GEN_1 =
AM_V_at = $(am__v_at_@AM_V@)
am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
am__v_at_1 =
SOURCES =
DIST_SOURCES =
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__lightning_include_HEADERS_DIST = jit_aarch64.h jit_alpha.h \
jit_arm.h jit_hppa.h jit_ia64.h jit_loongarch.h jit_mips.h \
jit_ppc.h jit_riscv.h jit_s390.h jit_sparc.h jit_x86.h
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
*) f=$$p;; \
esac;
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
am__install_max = 40
am__nobase_strip_setup = \
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
am__nobase_strip = \
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
am__nobase_list = $(am__nobase_strip_setup); \
for p in $$list; do echo "$$p $$p"; done | \
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
if (++n[$$2] == $(am__install_max)) \
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
END { for (dir in files) print dir, files[dir] }'
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
am__uninstall_files_from_dir = { \
test -z "$$files" \
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__installdirs = "$(DESTDIR)$(lightning_includedir)"
HEADERS = $(lightning_include_HEADERS)
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
am__uniquify_input = $(AWK) '\
BEGIN { nonempty = 0; } \
{ items[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in items) print i; }; } \
'
# Make sure the list of sources is unique. This is necessary because,
# e.g., the same source file might be shared among _SOURCES variables
# for different programs/libraries.
am__define_uniq_tagged_files = \
list='$(am__tagged_files)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
am__DIST_COMMON = $(srcdir)/Makefile.in
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
AR = @AR@
ARFLAGS = @ARFLAGS@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CSCOPE = @CSCOPE@
CTAGS = @CTAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
DLLTOOL = @DLLTOOL@
DSYMUTIL = @DSYMUTIL@
DUMPBIN = @DUMPBIN@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
ETAGS = @ETAGS@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
FILECMD = @FILECMD@
GREP = @GREP@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@
LDFLAGS = @LDFLAGS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
LIGHTNING_CFLAGS = @LIGHTNING_CFLAGS@
LIPO = @LIPO@
LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@
LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
MAKEINFO = @MAKEINFO@
MANIFEST_TOOL = @MANIFEST_TOOL@
MAYBE_INCLUDE_STDINT_H = @MAYBE_INCLUDE_STDINT_H@
MKDIR_P = @MKDIR_P@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
OTOOL = @OTOOL@
OTOOL64 = @OTOOL64@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_URL = @PACKAGE_URL@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
RANLIB = @RANLIB@
SED = @SED@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SHLIB = @SHLIB@
STRIP = @STRIP@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_AR = @ac_ct_AR@
ac_ct_CC = @ac_ct_CC@
ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__tar = @am__tar@
am__untar = @am__untar@
bindir = @bindir@
build = @build@
build_alias = @build_alias@
build_cpu = @build_cpu@
build_os = @build_os@
build_vendor = @build_vendor@
builddir = @builddir@
cpu = @cpu@
datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
gl_LIBOBJS = @gl_LIBOBJS@
gl_LTLIBOBJS = @gl_LTLIBOBJS@
gltests_LIBOBJS = @gltests_LIBOBJS@
gltests_LTLIBOBJS = @gltests_LTLIBOBJS@
gltests_WITNESS = @gltests_WITNESS@
host = @host@
host_alias = @host_alias@
host_cpu = @host_cpu@
host_os = @host_os@
host_vendor = @host_vendor@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
runstatedir = @runstatedir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target = @target@
target_alias = @target_alias@
target_cpu = @target_cpu@
target_os = @target_os@
target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
lightning_includedir = $(includedir)/lightning
EXTRA_DIST = \
jit_private.h
@cpu_aarch64_TRUE@lightning_include_HEADERS = \
@cpu_aarch64_TRUE@ jit_aarch64.h
@cpu_alpha_TRUE@lightning_include_HEADERS = \
@cpu_alpha_TRUE@ jit_alpha.h
@cpu_arm_TRUE@lightning_include_HEADERS = \
@cpu_arm_TRUE@ jit_arm.h
@cpu_hppa_TRUE@lightning_include_HEADERS = \
@cpu_hppa_TRUE@ jit_hppa.h
@cpu_ia64_TRUE@lightning_include_HEADERS = \
@cpu_ia64_TRUE@ jit_ia64.h
@cpu_loongarch_TRUE@lightning_include_HEADERS = \
@cpu_loongarch_TRUE@ jit_loongarch.h
@cpu_mips_TRUE@lightning_include_HEADERS = \
@cpu_mips_TRUE@ jit_mips.h
@cpu_ppc_TRUE@lightning_include_HEADERS = \
@cpu_ppc_TRUE@ jit_ppc.h
@cpu_riscv_TRUE@lightning_include_HEADERS = \
@cpu_riscv_TRUE@ jit_riscv.h
@cpu_s390_TRUE@lightning_include_HEADERS = \
@cpu_s390_TRUE@ jit_s390.h
@cpu_sparc_TRUE@lightning_include_HEADERS = \
@cpu_sparc_TRUE@ jit_sparc.h
@cpu_x86_TRUE@lightning_include_HEADERS = \
@cpu_x86_TRUE@ jit_x86.h
all: all-am
.SUFFIXES:
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
&& { if test -f $@; then exit 0; else break; fi; }; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu include/lightning/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --gnu include/lightning/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
install-lightning_includeHEADERS: $(lightning_include_HEADERS)
@$(NORMAL_INSTALL)
@list='$(lightning_include_HEADERS)'; test -n "$(lightning_includedir)" || list=; \
if test -n "$$list"; then \
echo " $(MKDIR_P) '$(DESTDIR)$(lightning_includedir)'"; \
$(MKDIR_P) "$(DESTDIR)$(lightning_includedir)" || exit 1; \
fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
done | $(am__base_list) | \
while read files; do \
echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(lightning_includedir)'"; \
$(INSTALL_HEADER) $$files "$(DESTDIR)$(lightning_includedir)" || exit $$?; \
done
uninstall-lightning_includeHEADERS:
@$(NORMAL_UNINSTALL)
@list='$(lightning_include_HEADERS)'; test -n "$(lightning_includedir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
dir='$(DESTDIR)$(lightning_includedir)'; $(am__uninstall_files_from_dir)
ID: $(am__tagged_files)
$(am__define_uniq_tagged_files); mkid -fID $$unique
tags: tags-am
TAGS: tags
tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
set x; \
here=`pwd`; \
$(am__define_uniq_tagged_files); \
shift; \
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
if test $$# -gt 0; then \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
"$$@" $$unique; \
else \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$unique; \
fi; \
fi
ctags: ctags-am
CTAGS: ctags
ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
$(am__define_uniq_tagged_files); \
test -z "$(CTAGS_ARGS)$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
cscopelist: cscopelist-am
cscopelist-am: $(am__tagged_files)
list='$(am__tagged_files)'; \
case "$(srcdir)" in \
[\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
*) sdir=$(subdir)/$(srcdir) ;; \
esac; \
for i in $$list; do \
if test -f "$$i"; then \
echo "$(subdir)/$$i"; \
else \
echo "$$sdir/$$i"; \
fi; \
done >> $(top_builddir)/cscope.files
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
check-am: all-am
check: check-am
all-am: Makefile $(HEADERS)
installdirs:
for dir in "$(DESTDIR)$(lightning_includedir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-am
install-exec: install-exec-am
install-data: install-data-am
uninstall: uninstall-am
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-am
install-strip:
if test -z '$(STRIP)'; then \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
install; \
else \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
fi
mostlyclean-generic:
clean-generic:
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
clean-am: clean-generic clean-libtool mostlyclean-am
distclean: distclean-am
-rm -f Makefile
distclean-am: clean-am distclean-generic distclean-tags
dvi: dvi-am
dvi-am:
html: html-am
html-am:
info: info-am
info-am:
install-data-am: install-lightning_includeHEADERS
install-dvi: install-dvi-am
install-dvi-am:
install-exec-am:
install-html: install-html-am
install-html-am:
install-info: install-info-am
install-info-am:
install-man:
install-pdf: install-pdf-am
install-pdf-am:
install-ps: install-ps-am
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-am
mostlyclean-am: mostlyclean-generic mostlyclean-libtool
pdf: pdf-am
pdf-am:
ps: ps-am
ps-am:
uninstall-am: uninstall-lightning_includeHEADERS
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
clean-libtool cscopelist-am ctags ctags-am distclean \
distclean-generic distclean-libtool distclean-tags distdir dvi \
dvi-am html html-am info info-am install install-am \
install-data install-data-am install-dvi install-dvi-am \
install-exec install-exec-am install-html install-html-am \
install-info install-info-am install-lightning_includeHEADERS \
install-man install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs maintainer-clean maintainer-clean-generic \
mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
ps ps-am tags tags-am uninstall uninstall-am \
uninstall-lightning_includeHEADERS
.PRECIOUS: Makefile
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
@@ -0,0 +1,93 @@
/*
* Copyright (C) 2013-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_aarch64_h
#define _jit_aarch64_h
#define JIT_HASH_CONSTS 0
#define JIT_NUM_OPERANDS 3
#if __APPLE__
# define PACKED_STACK 1
#endif
/*
* Types
*/
#define JIT_FP _R29
typedef enum {
#define jit_r(i) (_R9 + (i))
#define jit_r_num() 7
#define jit_v(i) (_R19 + (i))
#define jit_v_num() 10
#define jit_f(i) (_V8 + (i))
#define jit_f_num() 8
#define JIT_R0 _R9
#define JIT_R1 _R10
#define JIT_R2 _R11
#define JIT_R3 _R12
#define JIT_R4 _R13
#define JIT_R5 _R14
#define JIT_R6 _R15
_R8, /* indirect result */
_R18, /* platform register */
_R17, /* IP1 */
_R16, /* IP0 */
_R9, _R10, _R11, _R12, /* temporaries */
_R13, _R14, _R15,
#define JIT_V0 _R19
#define JIT_V1 _R20
#define JIT_V2 _R21
#define JIT_V3 _R22
#define JIT_V4 _R23
#define JIT_V5 _R24
#define JIT_V6 _R25
#define JIT_V7 _R26
#define JIT_V8 _R27
#define JIT_V9 _R28
_R19, _R20, _R21, _R22, /* callee save */
_R23, _R24, _R25, _R26,
_R27, _R28,
_SP, /* stack pointer */
_R30, /* link register */
_R29, /* frame pointer */
_R7, _R6, _R5, _R4,
_R3, _R2, _R1, _R0,
#define JIT_F0 _V8
#define JIT_F1 _V9
#define JIT_F2 _V10
#define JIT_F3 _V11
#define JIT_F4 _V12
#define JIT_F5 _V13
#define JIT_F6 _V14
#define JIT_F7 _V15
_V31, _V30, _V29, _V28, /* temporaries */
_V27, _V26, _V25, _V24,
_V23, _V22, _V21, _V20,
_V19, _V18, _V17, _V16,
/* callee save */
_V8, _V9, _V10, _V11,
_V12, _V13, _V14, _V15,
_V7, _V6, _V5, _V4, /* arguments */
_V3, _V2, _V1, _V0,
_NOREG,
#define JIT_NOREG _NOREG
} jit_reg_t;
#endif /* _jit_aarch64_h */
@@ -0,0 +1,105 @@
/*
* Copyright (C) 2014-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_alpha_h
#define _jit_alpha_h
#define JIT_HASH_CONSTS 1
#define JIT_NUM_OPERANDS 3
/*
* Types
*/
#define JIT_FP _FP
typedef enum {
#define jit_r(i) (_S0 + (i))
#define jit_r_num() 3
#define jit_v(i) (_S3 + (i))
#define jit_v_num() 3
#define jit_f(i) (_F2 + (i))
#define jit_f_num() 8
/* Volatile - Assembly temporary register */
_AT,
/* Volatile - Return value register */
_V0,
/* Volatile - Temporary registers */
_T0, _T1, _T2, _T3,
_T4, _T5, _T6, _T7,
_T8, _T9, _T10, _T11,
/* FIXME Use callee save register for r0-r2 (instead of 12+ JIT_RN
* and 6 JIT_VN because division must call a function)
* FIX would be to create proper functions that do not clobber
* registers and inject/inline them in the jit */
#define JIT_R0 _S0
#define JIT_R1 _S1
#define JIT_R2 _S2
#define JIT_V0 _S3
#define JIT_V1 _S4
#define JIT_V2 _S5
/* Nonvolatile - Saved registers */
_S0, _S1, _S2, _S3,
_S4, _S5,
/* Nonvolatile - Frame pointer */
_FP,
/* Volatile - Argument registers */
_A5, _A4, _A3, _A2,
_A1, _A0,
/* Volatile - Return address register */
_RA,
/* Volatile - Temporary register */
_PV,
/* Nonvolatile - Global pointer */
_GP,
/* Nonvolatile - Stack pointer */
_SP,
/* Constant RAZ / writes ignored */
_ZERO,
#define JIT_F0 _F2
#define JIT_F1 _F3
#define JIT_F2 _F4
#define JIT_F3 _F5
#define JIT_F4 _F6
#define JIT_F5 _F7
#define JIT_F6 _F8
#define JIT_F7 _F9
/* Volatile - Return value register (real part) */
_F0,
/* Volatile - Return value register (imaginary part) */
_F1,
/* Nonvolatile - Saved registers */
_F2, _F3, _F4, _F5,
_F6, _F7, _F8, _F9,
/* Volatile - Temporary registers */
_F10, _F11, _F12, _F13,
_F14, _F15,
/* Volatile - Argument registers */
_F21, _F20, _F19, _F18,
_F17, _F16,
/* Volatile - Temporary registers */
_F22, _F23, _R24, _F25,
_F26, _F27, _F28, _F29,
_F30,
/* Constant - RAZ / writes ignored */
_F31,
/* Lightning internal invalid register identifier */
_NOREG,
#define JIT_NOREG _NOREG
} jit_reg_t;
#endif /* _jit_alpha_h */
@@ -0,0 +1,193 @@
/*
* Copyright (C) 2012-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_arm_h
#define _jit_arm_h
#define JIT_HASH_CONSTS 0
#define JIT_NUM_OPERANDS 3
/*
* Types
*/
#define jit_swf_p() (jit_cpu.vfp == 0)
#define jit_hardfp_p() jit_cpu.abi
#define jit_ldrt_strt_p() jit_cpu.ldrt_strt
#define JIT_FP _R11
typedef enum {
#define jit_r(i) (_R4 + (i))
#define jit_r_num() 3
#define jit_v(i) (_R7 + (i))
#define jit_v_num() 3
#define jit_f(i) (jit_cpu.abi ? _D8 + ((i)<<1) : _D0 - ((i)<<1))
#define jit_f_num() 8
_R12, /* ip - temporary */
#define JIT_R0 _R4
#define JIT_R1 _R5
#define JIT_R2 _R6
_R4, /* r4 - variable */
_R5, /* r5 - variable */
_R6, /* r6 - variable */
#define JIT_V0 _R7
#define JIT_V1 _R8
#define JIT_V2 _R9
_R7, /* r7 - variable */
_R8, /* r8 - variable */
_R9, /* r9 - variable */
_R10, /* sl - stack limit */
_R11, /* fp - frame pointer */
_R13, /* sp - stack pointer */
_R14, /* lr - link register */
_R15, /* pc - program counter */
_R3, /* r3 - argument/result */
_R2, /* r2 - argument/result */
_R1, /* r1 - argument/result */
_R0, /* r0 - argument/result */
#define JIT_F0 (jit_hardfp_p() ? _D8 : _D0)
#define JIT_F1 (jit_hardfp_p() ? _D9 : _D1)
#define JIT_F2 (jit_hardfp_p() ? _D10 : _D2)
#define JIT_F3 (jit_hardfp_p() ? _D11 : _D3)
#define JIT_F4 (jit_hardfp_p() ? _D12 : _D4)
#define JIT_F5 (jit_hardfp_p() ? _D13 : _D5)
#define JIT_F6 (jit_hardfp_p() ? _D14 : _D6)
#define JIT_F7 (jit_hardfp_p() ? _D15 : _D7)
_S16, _D8 = _S16, _Q4 = _D8,
_S17,
_S18, _D9 = _S18,
_S19,
_S20, _D10 = _S20, _Q5 = _D10,
_S21,
_S22, _D11 = _S22,
_S23,
_S24, _D12 = _S24, _Q6 = _D12,
_S25,
_S26, _D13 = _S26,
_S27,
_S28, _D14 = _S28, _Q7 = _D14,
_S29,
_S30, _D15 = _S30,
_S31,
_S15,
_S14, _D7 = _S14,
_S13,
_S12, _D6 = _S12, _Q3 = _D6,
_S11,
_S10, _D5 = _S10,
_S9,
_S8, _D4 = _S8, _Q2 = _D4,
_S7,
_S6, _D3 = _S6,
_S5,
_S4, _D2 = _S4, _Q1 = _D2,
_S3,
_S2, _D1 = _S2,
_S1,
_S0, _D0 = _S0, _Q0 = _D0,
_NOREG,
#define JIT_NOREG _NOREG
} jit_reg_t;
typedef struct {
jit_uint32_t version : 4;
/* this field originally was only used for the 'e' in armv5te.
* it can also be used to force hardware division, if setting
* version to 7, telling it is armv7r or better. */
jit_uint32_t extend : 1;
/* only generate thumb instructions for thumb2 */
jit_uint32_t thumb : 1;
jit_uint32_t vfp : 3;
jit_uint32_t neon : 1;
jit_uint32_t abi : 2;
/* use strt+offset instead of str.w?
* on special cases it causes a SIGILL at least on qemu, probably
* due to some memory ordering constraint not being respected, so,
* disable by default */
jit_uint32_t ldrt_strt : 1;
/* assume functions called never match jit instruction set?
* that is libc, gmp, mpfr, etc functions are in thumb mode and jit
* is in arm mode, or the reverse, what may cause a crash upon return
* of that function if generating jit for a relative jump.
*/
jit_uint32_t exchange : 1;
/* By default assume cannot load unaligned data.
* A3.2.1
* Unaligned data access
* An ARMv7 implementation must support unaligned data accesses by
* some load and store instructions, as Table A3-1 shows. Software
* can set the SCTLR.A bit to control whether a misaligned access by
* one of these instructions causes an Alignment fault Data Abort
* exception.
* Table A3-1 Alignment requirements of load/store instructions
* Result if check fails when
* Instructions Alignment check SCTLR.A is 0 SCTLR.A is 1
* LDRB, LDREXB,
* LDRBT, LDRSB,
* LDRSBT, STRB,
* STREXB, STRBT,
* SWPB, TBB None - -
* LDRH, LDRHT,
* LDRSH, LDRSHT,
* STRH, STRHT,
* TBH Halfword Unaligned access Alignment fault
* LDREXH, STREXH Halfword Alignment fault Alignment fault
* LDR, LDRT,
* STR, STRT Word Unaligned access Alignment fault
* LDREX, STREX Word Alignment fault Alignment fault
* LDREXD, STREXD Doubleword Alignment fault Alignment fault
* All forms of
* LDM and STM,
* LDRD, RFE, SRS,
* STRD, SWP Word Alignment fault Alignment fault
* LDC, LDC2,
* STC, STC2 Word Alignment fault Alignment fault
* VLDM, VLDR,
* VPOP, VPUSH,
* VSTM, VSTR Word Alignment fault Alignment fault
* VLD1, VLD2,
* VLD3, VLD4,
* VST1, VST2,
* VST3, VST4,
* all with
* standard
* alignment (a) Element size Unaligned access Alignment fault
* VLD1, VLD2,
* VLD3, VLD4,
* VST1, VST2,
* VST3, VST4,
* all with
* @<align>
* specified (a) As specified by Alignment fault Alignment fault
* @<align>
*
* (a) These element and structure load/store instructions are only in
* the Advanced SIMD Extension to the ARMv7 ARM and Thumb instruction
* sets. ARMv7 does not support the pre-ARMv6 alignment model, so
* software cannot use that model with these instructions.
*/
jit_uint32_t unaligned : 1;
jit_uint32_t vfp_unaligned : 1;
} jit_cpu_t;
/*
* Initialization
*/
extern jit_cpu_t jit_cpu;
#endif /* _jit_arm_h */
@@ -0,0 +1,148 @@
/*
* Copyright (C) 2013-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_hppa_h
#define _jit_hppa_h
#define JIT_HASH_CONSTS 1
#define JIT_NUM_OPERANDS 3
/*
* Types
*/
typedef enum {
_R0, /* Always zero */
_R1, /* ADDIL implicit target */
_R2, /* B,L implicit target */
#define jit_r_num() 4
#define jit_r(n) ((n) < 3 ? _R4 + (n) : _R10 + (n) - 3)
#define jit_v_num() 11
#define jit_v(n) ((n) < 3 ? _R7 + (n) : _R11 + (n) - 3)
#define jit_f_num() 8
#define jit_f(n) (_F12 - (n))
#define JIT_FP _R3
#define JIT_R0 _R4
#define JIT_R1 _R5
#define JIT_R2 _R6
#define JIT_R3 _R10
#define JIT_V0 _R7
#define JIT_V1 _R8
#define JIT_V2 _R9
#define JIT_V3 _R11
#define JIT_V4 _R12
#define JIT_V5 _R13
#define JIT_V6 _R14
#define JIT_V7 _R15
#define JIT_V8 _R16
#define JIT_V9 _R17
#define JIT_V10 _R18
_R3,
_R19,
_R20,
_R21,
_R22,
_R29, /* ret1 */
_R28, /* ret0 */
_R4,
_R5,
_R6,
_R7,
_R8,
_R9,
_R10,
_R11,
_R12,
_R13,
_R14,
_R15,
_R16,
_R17,
_R18,
_R23, /* arg3 */
_R24, /* arg2 */
_R25, /* arg1 */
_R26, /* arg0 */
_R27, /* Data Pointer */
_R30, /* Stack Pointer */
_R31, /* Link register */
#define JIT_F0 _F12
#define JIT_F1 _F13
#define JIT_F2 _F14
#define JIT_F3 _F15
#define JIT_F4 _F16
#define JIT_F5 _F17
#define JIT_F6 _F18
#define JIT_F7 _F19
#define JIT_F8 _F20
#define JIT_F9 _F21
/* Caller Saves */
_F31,
_F30,
_F29,
_F28,
_F27,
_F26,
_F25,
_F24,
_F23,
_F22,
_F11,
_F10,
_F9,
_F8,
/* Arguments */
_F7, /* farg3 */
_F6, /* farg2 */
_F5, /* farg1 */
_F4, /* farg0 */
/* Callee Saves */
_F21,
_F20,
_F19,
_F18,
_F17,
_F16,
_F15,
_F14,
_F13,
_F12,
/* Floating-Pointer Status and Exception */
_F0,
_F1,
_F2,
_F3,
#define JIT_NOREG _NOREG
_NOREG,
} jit_reg_t;
typedef struct {
/* Need this to pass unldst.tst on . This is very strange, because
* even for aligned addresses it is required, but all other load/store
* tests *work* with index immediates. Possibly a qemu (7.0.0) bug,
* and for the moment, by default keep failing. Need to test in
* actual hardware. */
jit_uint32_t imm_idx : 1;
} jit_cpu_t;
/*
* Initialization
*/
extern jit_cpu_t jit_cpu;
#endif /* _jit_hppa */
@@ -0,0 +1,131 @@
/*
* Copyright (C) 2013-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_ia64_h
#define _jit_ia64_h
#define JIT_HASH_CONSTS 1
#define JIT_NUM_OPERANDS 3
/*
* Types
*/
#define JIT_FP _R4 /* Not abi specific */
typedef enum {
#define JIT_R0 _R40
#define JIT_R1 _R41
#define JIT_R2 _R42
#define JIT_R3 _R43
#define JIT_V0 _R44
#define JIT_V1 _R45
#define JIT_V2 _R46
#define JIT_V3 _R47
#define jit_r_num() 4
#define jit_r(n) (_R40 + (n))
#define jit_v_num() 4
#define jit_v(n) (_R44 + (n))
_R0, /* constant - Always 0 */
_R1, /* special - Global Data pointer (gp) */
/* r2-r3 - scratch - Use with 22-bit immediate add - scratch */
_R2, _R3,
/* r4-r7 - preserved */
_R4, _R5, _R6, _R7,
_R8, /* scratch - Return value; structure/union return pointer */
/* r9-r11 - scratch - Return values */
_R9, _R10, _R11,
_R12, /* special - Memory stack pointer (sp) */
_R13, /* special - Reserved as a thread pointer (tp)*/
/* r14-r31 - scratch */
_R31, _R30,
_R29, _R28, _R27, _R26, _R25, _R24, _R23, _R22,
_R21, _R20, _R19, _R18, _R17, _R16, _R15, _R14,
/* r32-r39 - aka in0-in7 - Incoming register arguments */
_R32, _R33, _R34, _R35, _R36, _R37, _R38, _R39,
/* r40-r127 - loc0...locn,out0...outn */
_R40, _R41, _R42, _R43, _R44, _R45, _R46, _R47,
_R48, _R49, _R50, _R51, _R52, _R53, _R54, _R55,
_R56, _R57, _R58, _R59, _R60, _R61, _R62, _R63,
_R64, _R65, _R66, _R67, _R68, _R69, _R70, _R71,
_R72, _R73, _R74, _R75, _R76, _R77, _R78, _R79,
_R80, _R81, _R82, _R83, _R84, _R85, _R86, _R87,
_R88, _R89, _R90, _R91, _R92, _R93, _R94, _R95,
_R96, _R97, _R98, _R99, _R100, _R101, _R102, _R103,
_R104, _R105, _R106, _R107, _R108, _R109, _R110, _R111,
_R112, _R113, _R114, _R115, _R116, _R117, _R118, _R119,
_R120, _R121, _R122, _R123, _R124, _R125, _R126, _R127,
#define JIT_F0 _F16
#define JIT_F1 _F17
#define JIT_F2 _F18
#define JIT_F3 _F19
#define JIT_F4 _F20
#define JIT_F5 _F21
#define jit_f_num() 6
#define jit_f(n) (_F16 + (n))
_F0, /* constant - Always 0.0 */
_F1, /* constant - Always 1.0 */
/* f2-f5 - preserved */
_F2, _F3, _F4, _F5,
/* f6-f7 - scratch */
_F6, _F7,
/* f8-f15 - scratch - Argument/return registers */
_F8, _F9, _F10, _F11, _F12, _F13, _F14, _F15,
/* f16-f31 - preserved */
_F16, _F17, _F18, _F19, _F20, _F21, _F22, _F23,
_F24, _F25, _F26, _F27, _F28, _F29, _F30, _F31,
/* f32-f127 - scratch - Rotating registers or scratch */
_F32, _F33, _F34, _F35, _F36, _F37, _F38, _F39,
_F40, _F41, _F42, _F43, _F44, _F45, _F46, _F47,
_F48, _F49, _F50, _F51, _F52, _F53, _F54, _F55,
_F56, _F57, _F58, _F59, _F60, _F61, _F62, _F63,
_F64, _F65, _F66, _F67, _F68, _F69, _F70, _F71,
_F72, _F73, _F74, _F75, _F76, _F77, _F78, _F79,
_F80, _F81, _F82, _F83, _F84, _F85, _F86, _F87,
_F88, _F89, _F90, _F91, _F92, _F93, _F94, _F95,
_F96, _F97, _F98, _F99, _F100, _F101, _F102, _F103,
_F104, _F105, _F106, _F107, _F108, _F109, _F110, _F111,
_F112, _F113, _F114, _F115, _F116, _F117, _F118, _F119,
#if 0
/* Do not list these to not need an unique identifier larger
* than 255 for jit_regset_t */
_F120, _F121, _F122, _F123, _F124, _F125, _F126, _F127,
#endif
/* Fake registers. Required because while "in" parameters start at r32,
* "out" parameters start *after* registers allocated for temporaries,
* and that are supposed to kept alive (what is desirable, that is, to
* not spill/reload them in memory) */
_OUT0, _OUT1, _OUT2, _OUT3, _OUT4, _OUT5, _OUT6, _OUT7,
#define JIT_NOREG _NOREG
_NOREG,
} jit_reg_t;
typedef struct {
jit_uint32_t clz : 1;
/* generate special instructions for unaligned load/store? */
jit_uint32_t unaligned : 1;
} jit_cpu_t;
/*
* Initialization
*/
extern jit_cpu_t jit_cpu;
#endif /* _jit_ia64_h */
@@ -0,0 +1,88 @@
/*
* Copyright (C) 2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_loongarch_h
#define _jit_loongarch_h
/*
* Types
*/
#define JIT_FP _FP
typedef enum {
#define jit_r_num() 9
#define jit_r(i) (_T0 - (i))
#define JIT_R0 _T0
#define JIT_R1 _T1
#define JIT_R2 _T2
#define JIT_R3 _T3
#define JIT_R4 _T4
#define JIT_R5 _T5
#define JIT_R6 _T6
#define JIT_R7 _T7
#define JIT_R8 _T8
_T8, _T7, _T6, _T5, _T4, _T3, _T2, _T1, _T0,
#define jit_v_num() 9
#define jit_v(i) (_S0 - (i))
#define JIT_V0 _S0
#define JIT_V1 _S1
#define JIT_V2 _S2
#define JIT_V3 _S3
#define JIT_V4 _S4
#define JIT_V5 _S5
#define JIT_V6 _S6
#define JIT_V7 _S7
#define JIT_V8 _S8
_S8, _S7, _S6, _S5, _S4, _S3, _S2, _S1, _S0,
_A7, _A6, _A5, _A4, _A3, _A2, _A1, _A0,
_FP,
_R21,
_ZERO,
_RA,
_TP,
_SP,
_FT0, _FT1, _FT2, _FT3, _FT4, _FT5, _FT6, _FT7,
_FT8, _FT9, _FT10, _FT11, _FT12, _FT13, _FT14, _FT15,
_FA7, _FA6, _FA5, _FA4, FA3, _FA2, _FA1, _FA0,
#define jit_f_num() 8
#define jit_f(i) (_FS0 - (i))
#define JIT_F0 _FS0
#define JIT_F1 _FS1
#define JIT_F2 _FS2
#define JIT_F3 _FS3
#define JIT_F4 _FS4
#define JIT_F5 _FS5
#define JIT_F6 _FS6
#define JIT_F7 _FS7
_FS7, _FS6, _FS5, _FS4, _FS3, _FS2, _FS1, _FS0,
#define JIT_NOREG _NOREG
_NOREG,
} jit_reg_t;
typedef struct {
/* generate special instructions for unaligned load/store? */
/* It is not guaranteed unaligned memory access is supported. */
jit_uint32_t unaligned : 1;
} jit_cpu_t;
/*
* Initialization
*/
extern jit_cpu_t jit_cpu;
#endif /* _jit_loongarch_h */
@@ -0,0 +1,138 @@
/*
* Copyright (C) 2012-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_mips_h
#define _jit_mips_h
#define JIT_HASH_CONSTS 1
#define JIT_NUM_OPERANDS 3
#if _MIPS_SIM != _ABIO32
# define NEW_ABI 1
#else
# define NEW_ABI 0
#endif
/*
* Types
*/
#define JIT_FP _FP
typedef enum {
#define jit_r(i) (_V0 + (i))
#if NEW_ABI
# define jit_r_num() 8
#else
# define jit_r_num() 12
#endif
#define jit_v(i) (_S0 + (i))
#define jit_v_num() 8
#define jit_f(i) (_F0 + (i))
#if NEW_ABI
# define jit_f_num() 6
#else
# define jit_f_num() 8
#endif
_AT,
#define JIT_R0 _V0
#define JIT_R1 _V1
#if NEW_ABI
# define JIT_R2 _T4
# define JIT_R3 _T5
# define JIT_R4 _T6
# define JIT_R5 _T7
# define JIT_R6 _T8
# define JIT_R7 _T9
#else
# define JIT_R2 _T0
# define JIT_R3 _T1
# define JIT_R4 _T2
# define JIT_R5 _T3
# define JIT_R6 _T4
# define JIT_R7 _T5
# define JIT_R8 _T6
# define JIT_R9 _T7
# define JIT_R10 _T8
# define JIT_R11 _T9
#endif
_V0, _V1,
#if !NEW_ABI
_T0, _T1, _T2, _T3,
#endif
_T4, _T5, _T6, _T7, _T8, _T9,
#define JIT_V0 _S0
#define JIT_V1 _S1
#define JIT_V2 _S2
#define JIT_V3 _S3
#define JIT_V4 _S4
#define JIT_V5 _S5
#define JIT_V6 _S6
#define JIT_V7 _S7
_S0, _S1, _S2, _S3, _S4, _S5, _S6, _S7,
_ZERO, _K0, _K1, _RA,
_GP,
_SP, _FP,
#if NEW_ABI
_A7, _A6, _A5, _A4,
#endif
_A3, _A2, _A1, _A0,
#define JIT_F0 _F0
#define JIT_F1 _F2
#define JIT_F2 _F4
#define JIT_F3 _F6
#define JIT_F4 _F8
#define JIT_F5 _F10
#if !NEW_ABI
# define JIT_F6 _F16
# define JIT_F7 _F18
#endif
_F0, _F2, _F4, _F6, _F8, _F10,
/* callee save float registers */
#if !NEW_ABI
_F16, _F18,
#endif
_F20, _F22, _F24, _F26, _F28, _F30,
#if NEW_ABI
_F19, _F18, _F17, _F16, _F15, _F14, _F13, _F12,
#else
_F14, _F12,
#endif
#define JIT_NOREG _NOREG
_NOREG,
} jit_reg_t;
typedef struct {
jit_uint32_t release : 4;
/* set if lwc1, ldc1, swc1, sdc1, mtc1, mfc1, dmtc1, and dmfc1
* can be put in delay slot */
jit_uint32_t cop1_delay : 1;
/* set if sll can be put in delay slot */
jit_uint32_t sll_delay : 1;
/* set if lwl and lwr can be put in delay slot */
jit_uint32_t lwl_lwr_delay : 1;
/* generate special instructions for un{ld,st}*; ignored for mips 6
* that does not have unaligned load/store instructions. */
jit_uint32_t unaligned : 1;
} jit_cpu_t;
/*
* Initialization
*/
extern jit_cpu_t jit_cpu;
#endif /* _jit_mips_h */
@@ -0,0 +1,85 @@
/*
* Copyright (C) 2012-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_ppc_h
#define _jit_ppc_h
#define JIT_HASH_CONSTS 1
#define JIT_NUM_OPERANDS 3
#if defined(_AIX) && !defined(_CALL_AIX) && !defined(_CALL_LINUX)
# define _CALL_AIXDESC 1
#endif
/*
* Types
*/
typedef enum {
#define jit_r(i) (_R28 + (i))
#define jit_r_num() 3
#define jit_v(i) (_R27 - (i))
#define jit_v_num() 14
#define jit_f(i) (_F14 + (i))
#define jit_f_num() 8
_R0,
#define JIT_R0 _R28
#define JIT_R1 _R29
#define JIT_R2 _R30
_R11, _R12, _R13, _R2,
#define JIT_V0 jit_v(0)
#define JIT_V1 jit_v(1)
#define JIT_V2 jit_v(2)
#define JIT_V3 jit_v(3)
#define JIT_V4 jit_v(4)
#define JIT_V5 jit_v(5)
#define JIT_V6 jit_v(6)
#define JIT_V7 jit_v(7)
#define JIT_V8 jit_v(8)
#define JIT_V9 jit_v(9)
#define JIT_V10 jit_v(10)
#define JIT_V11 jit_v(11)
#define JIT_V12 jit_v(12)
#define JIT_V13 jit_v(13)
_R14, _R15, _R16, _R17, _R18, _R19, _R20, _R21,
_R22, _R23, _R24, _R25, _R26, _R27, _R28, _R29,
_R30,
_R1,
#define JIT_FP _R31
_R31,
_R10, _R9, _R8, _R7, _R6, _R5, _R4, _R3,
_F0,
_F14, _F15, _F16, _F17, _F18, _F19, _F20, _F21,
#define JIT_F0 _F14
#define JIT_F1 _F15
#define JIT_F2 _F16
#define JIT_F3 _F17
#define JIT_F4 _F18
#define JIT_F5 _F19
#define JIT_F6 _F20
#define JIT_F7 _F21
/* FIXME _F20-_F31 not (easily) accessible and only _F14-_F21
* saved/restored (if used) */
_F22, _F23, _F24, _F25, _F26, _F27, _F28, _F29,
_F30, _F31,
_F13, _F12, _F11, _F10, _F9, _F8, _F7, _F6,
_F5, _F4, _F3, _F2, _F1,
_NOREG,
#define JIT_NOREG _NOREG
} jit_reg_t;
#endif /* _jit_ppc_h */
@@ -0,0 +1,924 @@
/*
* Copyright (C) 2012-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_private_h
#define _jit_private_h
#if HAVE_CONFIG_H
# include "config.h"
#endif
#include <assert.h>
#include <limits.h>
#include <stdio.h>
#ifdef STDC_HEADERS
# include <stddef.h>
#else
# if !defined(offsetof)
# define offsetof(type, field) ((char *)&((type *)0)->field - (char *)0)
# endif
#endif
#if defined(__GNUC__)
# define maybe_unused __attribute__ ((unused))
# define unlikely(exprn) __builtin_expect(!!(exprn), 0)
# define likely(exprn) __builtin_expect(!!(exprn), 1)
# if (__GNUC__ >= 4)
# define PUBLIC __attribute__ ((visibility("default")))
# define HIDDEN __attribute__ ((visibility("hidden")))
# else
# define PUBLIC /**/
# define HIDDEN /**/
# endif
#else
# define maybe_unused /**/
# define unlikely(exprn) exprn
# define likely(exprn) exprn
# define PUBLIC /**/
# define HIDDEN /**/
#endif
#if PACKED_STACK || STRONG_TYPE_CHECKING
# define assert_arg_type(code, expect) \
do assert((code) == (expect)); while (0)
# define assert_putarg_type(code, expect) \
do \
assert((((code) - jit_code_putargr_c) >> 2) == \
((expect) - jit_code_arg_c)); \
while (0)
#else
# define assert_arg_type(code, expect) \
do assert((int)(code) == (int)(expect) || \
(code) == jit_code_arg); while (0)
# define assert_putarg_type(code, expect) \
do \
assert(((((code) - jit_code_putargr_c) >> 2) == \
((expect) - jit_code_arg_c)) || \
((code) == jit_code_arg)); \
while (0)
#endif
#define rc(value) jit_class_##value
#define rn(reg) (jit_regno(_rvs[jit_regno(reg)].spec))
#if defined(__i386__) || defined(__x86_64__)
# define JIT_SP _RSP
# define JIT_RET _RAX
# if __X32
# define JIT_FRET _ST0
typedef jit_uint32_t jit_regset_t;
# else
# if __CYGWIN__ || _WIN32
# define JIT_RA0 _RCX
# else
# define JIT_RA0 _RDI
# endif
# define JIT_FA0 _XMM0
# define JIT_FRET _XMM0
typedef jit_uint64_t jit_regset_t;
# endif
#elif defined(__mips__)
# define JIT_RA0 _A0
# define JIT_FA0 _F12
# define JIT_SP _SP
# define JIT_RET _V0
# define JIT_FRET _F0
typedef jit_uint64_t jit_regset_t;
#elif defined(__arm__)
# define JIT_RA0 _R0
# define JIT_FA0 _D0
# define JIT_SP _R13
# define JIT_RET _R0
# if defined(__ARM_PCS_VFP)
# define JIT_FRET _D0
# else
# define JIT_FRET _R0
# endif
typedef jit_uint64_t jit_regset_t;
#elif defined(__powerpc__)
# define JIT_RA0 _R3
# define JIT_FA0 _F1
# define JIT_SP _R1
# define JIT_RET _R3
# define JIT_FRET _F1
typedef jit_uint64_t jit_regset_t;
#elif defined(__sparc__)
# define JIT_SP _SP
# define JIT_RET _I0
# define JIT_FRET _F0
# if __WORDSIZE == 32
typedef jit_uint64_t jit_regset_t;
# else
typedef struct {
jit_uint64_t rl;
jit_uint64_t rh;
} jit_regset_t;
# endif
#elif defined(__ia64__)
# define JIT_SP _R12
# define JIT_RET _R8
# define JIT_FRET _F8
typedef struct {
jit_uint64_t rl;
jit_uint64_t rh;
jit_uint64_t fl;
jit_uint64_t fh;
} jit_regset_t;
#elif defined(__hppa__)
# define JIT_SP _R30
# define JIT_RET _R28
# define JIT_FRET _F4
typedef jit_uint64_t jit_regset_t;
#elif defined(__aarch64__)
# define JIT_RA0 _R0
# define JIT_FA0 _V0
# define JIT_SP _SP
# define JIT_RET _R0
# define JIT_FRET _V0
typedef jit_uint64_t jit_regset_t;
#elif defined(__s390__) || defined(__s390x__)
# define JIT_SP _R15
# define JIT_RET _R2
# define JIT_FRET _F0
typedef jit_uint32_t jit_regset_t;
#elif defined(__alpha__)
# define JIT_SP _SP
# define JIT_RET _V0
# define JIT_FRET _F0
typedef jit_uint64_t jit_regset_t;
#elif defined(__riscv)
# define JIT_RA0 _A0
# define JIT_FA0 _FA0
# define JIT_SP _SP
# define JIT_RET _A0
# define JIT_FRET _FA0
typedef jit_uint64_t jit_regset_t;
#elif defined(__loongarch__)
# define JIT_RA0 _A0
# define JIT_FA0 _FA0
# define JIT_SP _SP
# define JIT_RET _A0
# define JIT_FRET _FA0
typedef jit_uint64_t jit_regset_t;
#endif
#define jit_data(u,v,w) _jit_data(_jit,u,v,w)
extern jit_node_t *_jit_data(jit_state_t*, const void*,
jit_word_t, jit_int32_t);
#define jit_size(vector) (sizeof(vector) / sizeof((vector)[0]))
#define jit_reg_free_p(regno) \
(!jit_regset_tstbit(&_jitc->reglive, regno) && \
!jit_regset_tstbit(&_jitc->regarg, regno) && \
!jit_regset_tstbit(&_jitc->regsav, regno))
#define jit_reg_free_if_spill_p(regno) \
(!jit_regset_tstbit(&_jitc->regarg, regno) && \
!jit_regset_tstbit(&_jitc->regsav, regno))
#define jit_code_inc_synth(code) \
do { \
(void)jit_new_node(code); \
jit_synth_inc(); \
} while (0)
#define jit_inc_synth(name) \
jit_code_inc_synth(jit_code_##name)
#define jit_code_inc_synth_w(code, u) \
do { \
(void)jit_new_node_w(code, u); \
jit_synth_inc(); \
} while (0)
#define jit_inc_synth_w(name, u) \
jit_code_inc_synth_w(jit_code_##name, u)
#define jit_code_inc_synth_f(code, u) \
do { \
(void)jit_new_node_f(code, u); \
jit_synth_inc(); \
} while (0)
#define jit_inc_synth_f(name, u) \
jit_code_inc_synth_f(jit_code_##name, u)
#define jit_code_inc_synth_d(code, u) \
do { \
(void)jit_new_node_d(code, u); \
jit_synth_inc(); \
} while (0)
#define jit_inc_synth_d(name, u) \
jit_code_inc_synth_d(jit_code_##name, u)
#define jit_code_inc_synth_ww(code, u, v) \
do { \
(void)jit_new_node_ww(code, u, v); \
jit_synth_inc(); \
} while (0)
#define jit_inc_synth_ww(name, u, v) \
jit_code_inc_synth_ww(jit_code_##name, u, v)
#define jit_code_inc_synth_wp(code, u, v) \
do { \
(void)jit_new_node_wp(code, u, v); \
jit_synth_inc(); \
} while (0)
#define jit_inc_synth_wp(name, u, v) \
jit_code_inc_synth_wp(jit_code_##name, u, v)
#define jit_code_inc_synth_fp(code, u, v) \
do { \
(void)jit_new_node_fp(code, u, v); \
jit_synth_inc(); \
} while (0)
#define jit_inc_synth_fp(name, u, v) \
jit_code_inc_synth_fp(jit_code_##name, u, v)
#define jit_code_inc_synth_dp(code, u, v) \
do { \
(void)jit_new_node_dp(code, u, v); \
jit_synth_inc(); \
} while (0)
#define jit_inc_synth_dp(name, u, v) \
jit_code_inc_synth_dp(jit_code_##name, u, v)
#define jit_inc_synth_wf(name, u, v) \
jit_code_inc_synth_wf(jit_code_##name, u, v)
#define jit_code_inc_synth_wf(code, u, v) \
do { \
(void)jit_new_node_wf(code, u, v); \
jit_synth_inc(); \
} while (0)
#define jit_inc_synth_wqf(name, u, v, w, x) \
do { \
(void)jit_new_node_wqf(jit_code_##name, u, v, w, x); \
jit_synth_inc(); \
} while (0)
#define jit_inc_synth_wd(name, u, v) \
jit_code_inc_synth_wd(jit_code_##name, u, v)
#define jit_inc_synth_wqd(name, u, v, w, x) \
do { \
(void)jit_new_node_wqd(jit_code_##name, u, v, w, x); \
jit_synth_inc(); \
} while (0)
#define jit_code_inc_synth_wd(code, u, v) \
do { \
(void)jit_new_node_wd(code, u, v); \
jit_synth_inc(); \
} while (0)
#define jit_dec_synth() jit_synth_dec()
#define jit_link_alist(node) \
do { \
node->link = _jitc->function->alist; \
_jitc->function->alist = node; \
} while (0)
#define jit_check_frame() \
do { \
if (!_jitc->function->need_frame) { \
_jitc->again = 1; \
_jitc->function->need_frame = 1; \
} \
} while (0)
#define jit_diffsize() (stack_framesize - _jitc->framesize)
#define jit_framesize() (stack_framesize - jit_diffsize())
#define jit_selfsize() (_jitc->function->self.size - jit_diffsize())
#define jit_link_prolog() \
do { \
_jitc->tail->link = _jitc->function->prolog->link; \
_jitc->function->prolog->link = _jitc->tail; \
} while (0)
#define jit_link_prepare() \
do { \
_jitc->tail->link = _jitc->prepare->link; \
_jitc->prepare->link = _jitc->tail; \
} while (0)
#define jit_link_reverse(where) \
do { \
jit_node_t *tmp, *tail = 0; \
while (where) { \
tmp = (where)->link; \
(where)->link = tail; \
tail = where; \
where = tmp; \
} \
where = tail; \
} while (0);
/*
* Private jit_class bitmasks
*/
#define jit_class_named 0x00400000 /* hit must be the named reg */
#define jit_class_nospill 0x00800000 /* hint to fail if need spill */
#define jit_class_sft 0x01000000 /* not a hardware register */
#define jit_class_rg8 0x04000000 /* x86 8 bits */
#define jit_class_xpr 0x80000000 /* float / vector */
/* Used on sparc64 where %f0-%f31 can be encode for single float
* but %f32 to %f62 only as double precision */
#define jit_class_sng 0x00010000 /* Single precision float */
#define jit_class_dbl 0x00020000 /* Only double precision float */
#define jit_regno_patch 0x00008000 /* this is a register
* returned by a "user" call
* to jit_get_reg() */
#define jit_call_default 0
#define jit_call_varargs 1
#define jit_kind_register 1
#define jit_kind_code 2
#define jit_kind_word 3
#define jit_kind_float32 4
#define jit_kind_float64 5
#define jit_cc_a0_reg 0x00000001 /* arg0 is a register */
#define jit_cc_a0_chg 0x00000002 /* arg0 is modified */
#define jit_cc_a0_jmp 0x00000004 /* arg0 is a jump target */
#define jit_cc_a0_rlh 0x00000008 /* arg0 is a register pair */
#define jit_cc_a0_int 0x00000010 /* arg0 is immediate word */
#define jit_cc_a0_flt 0x00000020 /* arg0 is immediate float */
#define jit_cc_a0_dbl 0x00000040 /* arg0 is immediate double */
#define jit_cc_a0_arg 0x00000080 /* arg1 is an argument int id */
#define jit_cc_a0_cnd 0x00000100 /* arg1 is a conditinally set register */
#define jit_cc_a1_reg 0x00000200 /* arg1 is a register */
#define jit_cc_a1_chg 0x00000400 /* arg1 is modified */
#define jit_cc_a1_int 0x00000800 /* arg1 is immediate word */
#define jit_cc_a1_flt 0x00001000 /* arg1 is immediate float */
#define jit_cc_a1_dbl 0x00002000 /* arg1 is immediate double */
#define jit_cc_a1_arg 0x00004000 /* arg1 is an argument node */
#define jit_cc_a1_rlh 0x00008000 /* arg1 is a register pair */
#define jit_cc_a2_reg 0x00010000 /* arg2 is a register */
#define jit_cc_a2_chg 0x00020000 /* arg2 is modified */
#define jit_cc_a2_int 0x00100000 /* arg2 is immediate word */
#define jit_cc_a2_flt 0x00200000 /* arg2 is immediate float */
#define jit_cc_a2_dbl 0x00400000 /* arg2 is immediate double */
#define jit_cc_a2_rlh 0x00800000 /* arg2 is a register pair */
#if __ia64__ || (__sparc__ && __WORDSIZE == 64)
extern void
jit_regset_com(jit_regset_t*, jit_regset_t*);
extern void
jit_regset_and(jit_regset_t*, jit_regset_t*, jit_regset_t*);
extern void
jit_regset_ior(jit_regset_t*, jit_regset_t*, jit_regset_t*);
extern void
jit_regset_xor(jit_regset_t*, jit_regset_t*, jit_regset_t*);
extern void
jit_regset_set(jit_regset_t*, jit_regset_t*);
extern void
jit_regset_set_mask(jit_regset_t*, jit_int32_t);
extern jit_bool_t
jit_regset_cmp_ui(jit_regset_t*, jit_word_t);
extern void
jit_regset_set_ui(jit_regset_t*, jit_word_t);
extern jit_bool_t
jit_regset_set_p(jit_regset_t*);
extern void
jit_regset_clrbit(jit_regset_t*, jit_int32_t);
extern void
jit_regset_setbit(jit_regset_t*, jit_int32_t);
extern jit_bool_t
jit_regset_tstbit(jit_regset_t*, jit_int32_t);
# if __sparc__ && __WORDSIZE == 64
# define jit_regset_new(set) \
do { (set)->rl = (set)->rh = 0; } while (0)
# define jit_regset_del(set) \
do { (set)->rl = (set)->rh = 0; } while (0)
# else
# define jit_regset_new(set) \
do { (set)->rl = (set)->rh = (set)->fl = (set)->fh = 0; } while (0)
# define jit_regset_del(set) \
do { (set)->rl = (set)->rh = (set)->fl = (set)->fh = 0; } while (0)
# endif
#else
# define jit_regset_com(u, v) (*(u) = ~*(v))
# define jit_regset_and(u, v, w) (*(u) = *(v) & *(w))
# define jit_regset_ior(u, v, w) (*(u) = *(v) | *(w))
# define jit_regset_xor(u, v, w) (*(u) = *(v) ^ *(w))
# define jit_regset_set(u, v) (*(u) = *(v))
# define jit_regset_set_mask(u, v) (*(u) = (1LL << (v)) - 1)
# define jit_regset_cmp_ui(u, v) (*(u) != (v))
# define jit_regset_set_ui(u, v) (*(u) = (v))
# define jit_regset_set_p(set) (*set)
# define jit_regset_clrbit(set, bit) (*(set) &= ~(1LL << (bit)))
# define jit_regset_setbit(set, bit) (*(set) |= 1LL << (bit))
# define jit_regset_tstbit(set, bit) (*(set) & (1LL << (bit)))
# define jit_regset_new(set) (*(set) = 0)
# define jit_regset_del(set) (*(set) = 0)
#endif
extern unsigned long
jit_regset_scan1(jit_regset_t*, jit_int32_t);
#define jit_reglive_setup() \
do { \
jit_regset_set_ui(&_jitc->reglive, 0); \
jit_regset_set_ui(&_jitc->regmask, 0); \
} while (0)
/*
* Types
*/
typedef union jit_data jit_data_t;
typedef struct jit_note jit_note_t;
typedef struct jit_line jit_line_t;
typedef struct jit_block jit_block_t;
typedef struct jit_value jit_value_t;
typedef struct jit_compiler jit_compiler_t;
typedef struct jit_function jit_function_t;
typedef struct jit_register jit_register_t;
#if __arm__
# if DISASSEMBLER
typedef struct jit_data_info jit_data_info_t;
# endif
#elif __riscv
typedef struct jit_const jit_const_t;
#endif
union jit_data {
struct {
#if __BYTE_ORDER == __LITTLE_ENDIAN
jit_int32_t l;
jit_int32_t h;
#else
jit_int32_t h;
jit_int32_t l;
#endif
} q;
jit_word_t w;
jit_float32_t f;
jit_float64_t d;
jit_pointer_t p;
jit_node_t *n;
};
struct jit_note {
jit_uint8_t *code;
char *name;
jit_line_t *lines;
jit_word_t length;
jit_word_t size; /* of code */
};
struct jit_line {
char *file;
jit_int32_t *linenos;
jit_int32_t *offsets;
jit_word_t length;
};
struct jit_node {
jit_node_t *next;
jit_code_t code;
jit_uint16_t flag;
jit_uint16_t offset; /* Used if DEVEL_DISASSEMBLER */
jit_data_t u;
jit_data_t v;
jit_data_t w;
jit_node_t *link;
};
struct jit_block {
jit_node_t *label;
jit_regset_t reglive;
jit_regset_t regmask;
jit_bool_t again; /* Flag need to rebuild regset masks
* due to changes in live and unknown
* state. */
};
struct jit_value {
jit_int32_t kind;
jit_code_t code;
jit_data_t base;
jit_data_t disp;
};
typedef struct {
#if __arm__
jit_word_t kind;
#endif
jit_word_t inst;
jit_node_t *node;
} jit_patch_t;
#if __arm__ && DISASSEMBLER
struct jit_data_info {
jit_uword_t code; /* pointer in code buffer */
jit_word_t length; /* length of constant vector */
};
#elif __riscv && __WORDSIZE == 64
struct jit_const {
jit_word_t value;
jit_word_t address;
jit_const_t *next;
};
#endif
struct jit_function {
struct {
jit_int32_t argi;
jit_int32_t argf;
jit_int32_t size;
jit_int32_t aoff;
jit_int32_t alen;
jit_int32_t call;
jit_int32_t argn; /* for debug output */
} self;
struct {
jit_int32_t argi;
jit_int32_t argf;
jit_int32_t size;
jit_int32_t call;
} call;
jit_node_t *prolog;
jit_node_t *epilog;
jit_node_t *alist;
jit_int32_t *regoff;
jit_regset_t regset;
jit_int32_t stack;
#if defined(__i386__) || defined(__x86_64__) || \
defined(__powerpc__) || defined(__sparc__) || \
defined(__s390__) || defined(__s390x__) || \
defined(__hppa__) || defined(__alpha__)
jit_int32_t cvt_offset; /* allocai'd offset for x87<->xmm or
* fpr<->gpr transfer using the stack */
#endif
/* Helper for common jit generation pattern, used in GNU Smalltalk
* and possibly others, where a static frame layout is required or
* assumed. */
jit_int32_t frame;
jit_uint32_t define_frame : 1;
jit_uint32_t assume_frame : 1;
jit_uint32_t need_frame : 1; /* need frame pointer? */
jit_uint32_t need_stack : 1; /* need stack pointer? */
jit_uint32_t need_return : 1; /* not a leaf function */
/* alloca offset offset */
jit_int32_t aoffoff;
/* uses allocar flag */
jit_uint32_t allocar : 1;
#if __arm__
/* If will, or might use float registers and vfp is not available.
* Use the first 64 bytes always, as the access to the virtual float
* registers use hardcoded instructions that can only reach 64 byte
* displacements, and to keep code simpler, do not use temporaries. */
jit_uint32_t swf_offset : 1;
/* If need to call C functions for some operation, or variadic function */
jit_uint32_t save_reg_args : 1;
#endif
/* varargs state offsets */
jit_int32_t vaoff; /* offset of jit_va_list */
jit_int32_t vagp; /* first gp va argument */
jit_int32_t vafp; /* first fp va argument */
};
/* data used only during jit generation */
struct jit_compiler {
#if __ia64__
struct {
jit_uint64_t i : 41;
jit_uint64_t t : 4;
} inst[3];
jit_regset_t regs; /* changed regs since last stop */
jit_int32_t pred; /* changed preds last stop */
jit_int32_t ioff; /* offset in inst vector */
jit_int32_t rout; /* first output register */
jit_int32_t breg; /* base register for prolog/epilog */
#endif
#if __mips__
struct {
jit_int32_t op; /* pending instruction, candidate
* to be inserted in a delay slot */
jit_bool_t pend; /* non zero if need to emit op */
} inst;
#endif
#if __mips__ || __ia64__ || __alpha__ || \
(__sparc__ && __WORDSIZE == 64) || __riscv || __loongarch__
jit_int32_t carry;
#define jit_carry _jitc->carry
#endif
jit_node_t *head;
jit_node_t *tail;
jit_node_t *prepare; /* inside prepare/finish* block */
jit_uint32_t realize : 1; /* jit_realize() called? */
jit_uint32_t dataset : 1; /* jit_dataset() called? */
jit_uint32_t done : 1; /* emit state finished */
jit_uint32_t emit : 1; /* emit state entered */
jit_uint32_t again : 1; /* start over emiting function */
jit_uint32_t synth : 8; /* emiting synthesized instructions */
#if DEBUG
jit_uint32_t getreg : 1;
#endif
jit_uint32_t no_data : 1;
jit_uint32_t no_note : 1;
/* FIXME undocumented, might be moved to a jit_cpu field or a better
* configuration api.
* These are switches to a different unld* or unst*.
* Defaults are the algorithms that generate shorter code*/
jit_uint32_t unld_algorithm : 1;
jit_uint32_t unst_algorithm : 1;
jit_int32_t framesize; /* space for callee save registers,
* frame pointer and return address */
jit_int32_t reglen; /* number of registers */
jit_regset_t regarg; /* cannot allocate */
jit_regset_t regsav; /* automatic spill only once */
jit_regset_t reglive; /* known live registers at some point */
jit_regset_t regmask; /* register mask to update reglive */
jit_regset_t explive; /* explicitly marked as live */
struct {
jit_uint8_t *end;
} code;
struct {
jit_uint8_t *ptr;
jit_node_t **table; /* very simple hash table */
jit_word_t size; /* number of vectors in table */
jit_word_t count; /* number of hash table entries */
jit_word_t offset; /* offset in bytes in ptr */
} data;
jit_node_t **spill;
jit_int32_t *gen; /* ssa like "register version" */
jit_value_t *values; /* temporary jit_value_t vector */
struct {
jit_block_t *ptr;
jit_word_t offset;
jit_word_t length;
} blocks; /* basic blocks */
struct {
jit_patch_t *ptr;
jit_word_t offset;
jit_word_t length;
} patches; /* forward patch information */
jit_function_t *function; /* current function */
struct {
jit_function_t *ptr;
jit_word_t offset;
jit_word_t length;
} functions; /* prolog/epilogue offsets in code */
struct {
jit_node_t **ptr;
jit_word_t offset;
jit_word_t length;
} pool;
jit_node_t *list;
struct {
jit_node_t *head; /* first note node */
jit_node_t *tail; /* linked list insertion */
/* fields to store temporary state information */
jit_word_t size;
jit_node_t *name;
jit_node_t *note;
jit_uint8_t *base;
} note;
#if __arm__
/* prevent using thumb instructions that set flags? */
jit_uint32_t no_set_flags : 1;
# if DISASSEMBLER
struct {
jit_data_info_t *ptr;
jit_word_t offset;
jit_word_t length;
} data_info; /* constant pools information */
# endif
/* Note that this field is somewhat hackish, but required by most
* ways to implement jit, unless implementing a pure one function
* per jit, as most times it needs to start the jit buffer with a
* jump where the "main" prolog starts, and because the initial
* code is in "arm mode", need to make an "arm mode" patch on that
* jump. A good example is the test suite assembler, where most
* test cases start with a "jmpi main" call. */
jit_uword_t thumb;
struct {
jit_uint8_t *data; /* pointer to code */
jit_word_t size; /* size data */
jit_word_t offset; /* pending patches */
jit_word_t length; /* number of pending constants */
jit_int32_t values[1024]; /* pending constants */
jit_word_t patches[2048];
} consts;
#elif (__powerpc__ && _CALL_AIXDESC) || __ia64__
/* Keep track of prolog addresses, just for the sake of making
* jit that starts with a jump to a "main" label work like other
* backends. */
struct {
jit_word_t *ptr;
jit_word_t offset;
jit_word_t length;
} prolog;
jit_bool_t jump;
#elif __riscv && __WORDSIZE == 64
struct {
/* Hash table for constants to be resolved and patched */
struct {
jit_const_t **table; /* very simple hash table */
jit_word_t size; /* number of vectors in table */
jit_word_t count; /* number of distinct entries */
} hash;
struct {
jit_const_t **ptr; /* keep a single pointer */
jit_const_t *list; /* free list */
jit_word_t length; /* length of pool */
} pool;
/* Linear list for constants that cannot be encoded easily */
struct {
jit_word_t *instrs; /* list of direct movi instructions */
jit_word_t *values; /* list of direct movi constants */
jit_word_t offset; /* offset in instrs/values vector */
jit_word_t length; /* length of instrs/values vector */
} vector;
} consts;
#endif
#if GET_JIT_SIZE
/* Temporary storage to calculate instructions length */
jit_word_t size;
/* Global flag for code buffer heuristic size computation */
jit_word_t mult;
/* Pointer to code to prevent miscalculation if reallocating buffer */
jit_uint8_t *cptr;
#endif
};
#define _jitc _jit->comp
struct jit_state {
union {
jit_uint8_t *uc;
jit_uint16_t *us;
jit_uint32_t *ui;
jit_uint64_t *ul;
jit_word_t w;
} pc;
struct {
jit_uint8_t *ptr;
jit_word_t length;
/* PROTECTED bytes starting at PTR are mprotect'd. */
jit_word_t protected;
} code;
struct {
jit_uint8_t *ptr;
jit_word_t length;
} data;
struct {
jit_note_t *ptr;
jit_word_t length;
} note;
jit_compiler_t *comp;
/* Flags to know if user did set the code and data buffers */
jit_uint32_t user_code : 1;
jit_uint32_t user_data : 1;
};
struct jit_register {
jit_reg_t spec;
char *name;
};
/*
* Prototypes
*/
extern void jit_get_cpu(void);
#define jit_init() _jit_init(_jit)
extern void _jit_init(jit_state_t*);
#define jit_synth_inc() _jit_synth_inc(_jit)
extern void _jit_synth_inc(jit_state_t*);
#define jit_new_node_no_link(u) _jit_new_node_no_link(_jit, u)
extern jit_node_t *_jit_new_node_no_link(jit_state_t*, jit_code_t);
#define jit_link_node(u) _jit_link_node(_jit, u)
extern void _jit_link_node(jit_state_t*, jit_node_t*);
#define jit_link_label(l) _jit_link_label(_jit,l)
extern void
_jit_link_label(jit_state_t*,jit_node_t*);
#define jit_synth_dec() _jit_synth_dec(_jit)
extern void _jit_synth_dec(jit_state_t*);
#define jit_reglive(node) _jit_reglive(_jit, node)
extern void
_jit_reglive(jit_state_t*, jit_node_t*);
#define jit_regarg_set(n,v) _jit_regarg_set(_jit,n,v)
extern void
_jit_regarg_set(jit_state_t*, jit_node_t*, jit_int32_t);
#define jit_regarg_clr(n,v) _jit_regarg_clr(_jit,n,v)
extern void
_jit_regarg_clr(jit_state_t*, jit_node_t*, jit_int32_t);
#define jit_save(reg) _jit_save(_jit, reg)
extern void
_jit_save(jit_state_t*, jit_int32_t);
#define jit_load(reg) _jit_load(_jit, reg)
extern void
_jit_load(jit_state_t*, jit_int32_t);
#define jit_trampoline(u,v) _jit_trampoline(_jit, u, v)
extern void _jit_trampoline(jit_state_t*, jit_int32_t, jit_bool_t);
#define jit_optimize() _jit_optimize(_jit)
extern void
_jit_optimize(jit_state_t*);
#define jit_classify(code) _jit_classify(_jit, code)
extern jit_int32_t
_jit_classify(jit_state_t*, jit_code_t);
#define jit_regarg_p(n, r) _jit_regarg_p(_jit, n, r)
extern jit_bool_t
_jit_regarg_p(jit_state_t*, jit_node_t*, jit_int32_t);
#define emit_code() _emit_code(_jit)
extern jit_pointer_t
_emit_code(jit_state_t*);
extern void
jit_flush(void *fptr, void *tptr);
#define emit_ldxi(r0, r1, i0) _emit_ldxi(_jit, r0, r1, i0)
extern void
_emit_ldxi(jit_state_t*, jit_int32_t, jit_int32_t, jit_word_t);
#define emit_stxi(i0, r0, r1) _emit_stxi(_jit, i0, r0, r1)
extern void
_emit_stxi(jit_state_t*, jit_word_t, jit_int32_t, jit_int32_t);
#define emit_ldxi_d(r0, r1, i0) _emit_ldxi_d(_jit, r0, r1, i0)
extern void
_emit_ldxi_d(jit_state_t*, jit_int32_t, jit_int32_t, jit_word_t);
#define emit_stxi_d(i0, r0, r1) _emit_stxi_d(_jit, i0, r0, r1)
extern void
_emit_stxi_d(jit_state_t*, jit_word_t, jit_int32_t, jit_int32_t);
extern void jit_init_print(void);
extern void jit_init_debug(const char*);
extern void jit_finish_debug(void);
extern void jit_init_note(void);
extern void jit_finish_note(void);
#define jit_set_note(n,u,v,w) _jit_set_note(_jit, n, u, v, w)
extern void _jit_set_note(jit_state_t*, jit_note_t*, char*, int, jit_int32_t);
#define jit_annotate() _jit_annotate(_jit)
extern void _jit_annotate(jit_state_t*);
#define jit_print_node(u) _jit_print_node(_jit,u)
extern void _jit_print_node(jit_state_t*,jit_node_t*);
extern jit_pointer_t jit_memcpy(jit_pointer_t,const void*,jit_word_t);
extern jit_pointer_t jit_memmove(jit_pointer_t,const void*,jit_word_t);
extern void jit_alloc(jit_pointer_t*, jit_word_t);
extern void jit_realloc(jit_pointer_t*, jit_word_t, jit_word_t);
void jit_free(jit_pointer_t*);
extern void jit_init_size(void);
extern void jit_finish_size(void);
#if GET_JIT_SIZE
# define jit_size_prepare() _jit_size_prepare(_jit)
extern void
_jit_size_prepare(jit_state_t*);
# define jit_size_collect(node) _jit_size_collect(_jit, node)
extern void
_jit_size_collect(jit_state_t*, jit_node_t*);
#else
# define jit_get_size() _jit_get_size(_jit)
extern jit_word_t
_jit_get_size(jit_state_t*);
#endif
extern jit_word_t
jit_get_max_instr(void);
/*
* Externs
*/
extern jit_register_t _rvs[];
#endif /* _jit_private_h */
@@ -0,0 +1,167 @@
/*
* Copyright (C) 2019-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_riscv_h
#define _jit_riscv_h
#define JIT_HASH_CONSTS 0
#define JIT_NUM_OPERANDS 3
/*
* Types
*/
#define JIT_FP _FP
typedef enum {
#define jit_r(i) (JIT_R0 + (i))
#define jit_r_num() 7
#define jit_v(i) (JIT_V0 + (i))
#define jit_v_num() 11
#define jit_f(i) (JIT_F0 + (i))
#define jit_f_num() 12
_ZERO, /* x0 - Hard-wired zero --- */
_RA, /* x1 - Return address (CalleR save) */
_SP, /* x2 - Stack pointer (CalleE save) */
_GP, /* x3 - Global pointer --- */
#if 0 /* Pretend it does not exist, so _NOREG can be used in
* a 64 bit bitmask */
_TP, /* x4 - Thread pointer --- */
#endif
#define JIT_R0 _T0
#define JIT_R1 _T1
#define JIT_R2 _T2
#define JIT_R3 _T3
#define JIT_R4 _T4
#define JIT_R5 _T5
#define JIT_R6 _T6
_T0, /* x5 - Temporary/alternate
link register (CalleR save) */
_T1, /* x6 - Temporary (CalleR save) */
_T2, /* x7 - Temporary (CalleR save) */
_T3, /* x28 - Temporary (CalleR save) */
_T4, /* x28 - Temporary (CalleR save) */
_T5, /* x30 - Temporary (CalleR save) */
_T6, /* x31 - Temporary (CalleR save) */
_FP, /* x8 - Saved register/frame
pointer (CalleE save) */
_S0 = _FP,
#define JIT_V0 _S1
#define JIT_V1 _S2
#define JIT_V2 _S3
#define JIT_V3 _S4
#define JIT_V4 _S5
#define JIT_V5 _S6
#define JIT_V6 _S7
#define JIT_V7 _S8
#define JIT_V8 _S9
#define JIT_V9 _S10
#define JIT_V10 _S11
_S1, /* x9 - Saved register (CalleE save) */
_S2, /* x18 - Saved register (CalleE save) */
_S3, /* x19 - Saved register (CalleE save) */
_S4, /* x20 - Saved register (CalleE save) */
_S5, /* x21 - Saved register (CalleE save) */
_S6, /* x22 - Saved register (CalleE save) */
_S7, /* x23 - Saved register (CalleE save) */
_S8, /* x24 - Saved register (CalleE save) */
_S9, /* x25 - Saved register (CalleE save) */
_S10, /* x26 - Saved register (CalleE save) */
_S11, /* x27 - Saved register (CalleE save) */
_A7, /* x17 - Function argument (CalleR save) */
_A6, /* x16 - Function argument (CalleR save) */
_A5, /* x15 - Function argument (CalleR save) */
_A4, /* x14 - Function argument (CalleR save) */
_A3, /* x13 - Function argument (CalleR save) */
_A2, /* x12 - Function argument (CalleR save) */
_A1, /* x11 - Function argument/
return value (CalleR save) */
_A0, /* x10 - Function argument/
return value (CalleR save) */
_FT0, /* f0 - FP temporary (CalleR save) */
_FT1, /* f1 - FP temporary (CalleR save) */
_FT2, /* f2 - FP temporary (CalleR save) */
_FT3, /* f3 - FP temporary (CalleR save) */
_FT4, /* f4 - FP temporary (CalleR save) */
_FT5, /* f5 - FP temporary (CalleR save) */
_FT6, /* f6 - FP temporary (CalleR save) */
_FT7, /* f7 - FP temporary (CalleR save) */
_FT8, /* f28 - FP temporary (CalleR save) */
_FT9, /* f29 - FP temporary (CalleR save) */
_FT10, /* f30 - FP temporary (CalleR save) */
_FT11, /* f31 - FP temporary (CalleR save) */
#define JIT_F0 _FS0
#define JIT_F1 _FS1
#define JIT_F2 _FS2
#define JIT_F3 _FS3
#define JIT_F4 _FS4
#define JIT_F5 _FS5
#define JIT_F6 _FS6
#define JIT_F7 _FS7
#define JIT_F8 _FS8
#define JIT_F9 _FS9
#define JIT_F10 _FS10
#define JIT_F11 _FS11
_FS0, /* f8 - FP saved register (CalleE save) */
_FS1, /* f9 - FP saved register (CalleE save) */
_FS2, /* f18 - FP saved register (CalleE save) */
_FS3, /* f19 - FP saved register (CalleE save) */
_FS4, /* f20 - FP saved register (CalleE save) */
_FS5, /* f21 - FP saved register (CalleE save) */
_FS6, /* f22 - FP saved register (CalleE save) */
_FS7, /* f23 - FP saved register (CalleE save) */
_FS8, /* f24 - FP saved register (CalleE save) */
_FS9, /* f25 - FP saved register (CalleE save) */
_FS10, /* f26 - FP saved register (CalleE save) */
_FS11, /* f27 - FP saved register (CalleE save) */
_FA7, /* f17 - FP Function argument (CalleR save) */
_FA6, /* f16 - FP Function argument (CalleR save) */
_FA5, /* f15 - FP Function argument (CalleR save) */
_FA4, /* f14 - FP Function argument (CalleR save) */
_FA3, /* f13 - FP Function argument (CalleR save) */
_FA2, /* f12 - FP Function argument (CalleR save) */
_FA1, /* f11 - FP function argument/
return value (CalleR save) */
_FA0, /* f10 - FP function argument/
return value (CalleR save) */
_NOREG,
#define JIT_NOREG _NOREG
} jit_reg_t;
typedef struct {
/* generate special instructions for unaligned load/store? */
/*
* For best performance, the effective address for all loads and stores
* should be naturally aligned for each data type (i.e., on a four-byte
* boundary for 32-bit accesses, and a two-byte boundary for 16-bit
* accesses). The base ISA supports misaligned accesses, but these might
* run extremely slowly depending on the implementation. Furthermore,
* naturally aligned loads and stores are guaranteed to execute atomically,
* whereas misaligned loads and stores might not, and hence require
* additional synchronization to ensure atomicity
*/
jit_uint32_t unaligned : 1;
} jit_cpu_t;
/*
* Initialization
*/
extern jit_cpu_t jit_cpu;
#endif /* _jit_riscv_h */
@@ -0,0 +1,77 @@
/*
* Copyright (C) 2013-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_s390_h
#define _jit_s390_h
#define JIT_HASH_CONSTS 1
#define JIT_NUM_OPERANDS 2
/*
* Types
*/
#define JIT_FP _R13
typedef enum {
#define jit_r(i) (_R12 + ((i) << 1))
#define jit_r_num() 3
#define jit_v(i) (_R11 + ((i) << 1))
#define jit_v_num() 3
#define jit_f(i) (_F8 + (i))
#define jit_f_num() 6
#define JIT_R0 _R12
#define JIT_R1 _R10
#define JIT_R2 _R8
#define JIT_V0 _R11
#define JIT_V1 _R9
#define JIT_V2 _R7
_R0, _R1, /* Volatile */
_R12, /* Saved, GOT */
_R11, _R10, _R9, _R8, /* Saved */
_R7, /* Saved */
_R6, /* Saved, parameter */
_R5, _R4, _R3, /* Parameter passing */
_R2, /* Volatile, parameter and return value */
_R13, /* Saved, literal pool pointer */
_R14, /* Volatile, return address */
_R15, /* Saved, stack pointer */
#define JIT_F0 _F8
#define JIT_F1 _F9
#define JIT_F2 _F10
#define JIT_F3 _F11
#define JIT_F4 _F12
#define JIT_F5 _F13
_F1, _F3, _F5, _F7, /* Volatile */
_F14, _F15, _F8, _F9, /* Saved */
_F10, _F11, _F12, _F13, /* Saved */
_F6, _F4, _F2, /* Volatile, parameter */
_F0, /* Volatile, parameter and return value */
_NOREG,
#define JIT_NOREG _NOREG
} jit_reg_t;
typedef struct {
jit_uint32_t flogr : 1;
} jit_cpu_t;
/*
* Initialization
*/
extern jit_cpu_t jit_cpu;
#endif /* _jit_s390_h */
@@ -0,0 +1,111 @@
/*
* Copyright (C) 2013-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_sparc_h
#define _jit_sparc_h
#define JIT_HASH_CONSTS 1
#define JIT_NUM_OPERANDS 3
/*
* Types
*/
#define JIT_FP _FP
typedef enum {
#define jit_r(i) (_G2 + (i))
#define jit_r_num() 3
#define jit_v(i) (_L0 + (i))
#define jit_v_num() 8
#if __WORDSIZE == 32
# define jit_f(i) (_F0 + ((i) << 1))
# define jit_f_num() 8
#else
# define jit_f(i) (_F32 - (i))
# define jit_f_num() 16
#endif
#define JIT_R0 _G2
#define JIT_R1 _G3
#define JIT_R2 _G4
#define JIT_V0 _L0
#define JIT_V1 _L1
#define JIT_V2 _L2
#define JIT_V3 _L3
#define JIT_V4 _L4
#define JIT_V5 _L5
#define JIT_V6 _L6
#define JIT_V7 _L7
_G0, _G1, _G2, _G3, _G4, _G5, _G6, _G7,
_O0, _O1, _O2, _O3, _O4, _O5, _SP, _O7,
_L0, _L1, _L2, _L3, _L4, _L5, _L6, _L7,
_I0, _I1, _I2, _I3, _I4, _I5, _FP, _I7,
#if __WORDSIZE == 32
# define JIT_F0 _F0
# define JIT_F1 _F2
# define JIT_F2 _F4
# define JIT_F3 _F6
# define JIT_F4 _F8
# define JIT_F5 _F10
# define JIT_F6 _F12
# define JIT_F7 _F14
_F0, _F1, _F2, _F3, _F4, _F5, _F6, _F7,
_F8, _F9, _F10, _F11, _F12, _F13, _F14, _F15,
#else
/* All single precision operations have a high cost due to being
* stored on registers only encodable as double precision.
* The cost is due to needing to move values to a register with
* value <= 31.
* This is a limitation due to using fixed named registers in
* lightning. */
# define JIT_F0 _F32
# define JIT_F1 _F34
# define JIT_F2 _F36
# define JIT_F3 _F38
# define JIT_F4 _F40
# define JIT_F5 _F42
# define JIT_F6 _F44
# define JIT_F7 _F46
# define JIT_F8 _F48
# define JIT_F9 _F50
# define JIT_F10 _F52
# define JIT_F11 _F54
# define JIT_F12 _F56
# define JIT_F13 _F58
# define JIT_F14 _F60
# define JIT_F15 _F62
_F62, _F60, _F58, _F56, _F54, _F52, _F50, _F48,
_F46, _F44, _F42, _F40, _F38, _F36, _F34, _F32,
_F31, _F30, _F29, _F28, _F27, _F26, _F25, _F24,
_F23, _F22, _F21, _F20, _F19, _F18, _F17, _F16,
_F15, _F14, _F13, _F12, _F11, _F10, _F9, _F8,
_F7, _F6, _F5, _F4, _F3, _F2, _F1, _F0,
#endif
#define JIT_NOREG _NOREG
_NOREG,
} jit_reg_t;
typedef struct {
jit_uint32_t lzcnt : 1;
} jit_cpu_t;
/*
* Initialization
*/
extern jit_cpu_t jit_cpu;
#endif /* _jit_sparc_h */
@@ -0,0 +1,207 @@
/*
* Copyright (C) 2012-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#ifndef _jit_x86_h
#define _jit_x86_h
#define JIT_HASH_CONSTS 1
#define JIT_NUM_OPERANDS 2
/*
* Types
*/
#define jit_sse2_p() jit_cpu.sse2
#define jit_x87_reg_p(reg) ((reg) >= _ST0 && (reg) <= _ST6)
#if __WORDSIZE == 32
# if defined(__x86_64__)
# define __X64_32 1
# define __X64 1
# else
# define __X32 1
# endif
#else
# define __X64 1
#endif
#define JIT_FP _RBP
typedef enum {
#if __X32
# define jit_r(i) (_RAX + (i))
# define jit_r_num() 3
# define jit_v(i) (_RBX + (i))
# define jit_v_num() 3
# define jit_f(i) (jit_cpu.sse2 ? _XMM0 + (i) : _ST0 + (i))
# define jit_f_num() (jit_cpu.sse2 ? 8 : 6)
# define JIT_R0 _RAX
# define JIT_R1 _RCX
# define JIT_R2 _RDX
_RAX, _RCX, _RDX,
# define JIT_V0 _RBX
# define JIT_V1 _RSI
# define JIT_V2 _RDI
_RBX, _RSI, _RDI,
_RSP, _RBP,
# define JIT_F0 (jit_sse2_p() ? _XMM0 : _ST0)
# define JIT_F1 (jit_sse2_p() ? _XMM1 : _ST1)
# define JIT_F2 (jit_sse2_p() ? _XMM2 : _ST2)
# define JIT_F3 (jit_sse2_p() ? _XMM3 : _ST3)
# define JIT_F4 (jit_sse2_p() ? _XMM4 : _ST4)
# define JIT_F5 (jit_sse2_p() ? _XMM5 : _ST5)
# define JIT_F6 (jit_sse2_p() ? _XMM6 : _ST6)
_XMM0, _XMM1, _XMM2, _XMM3, _XMM4, _XMM5, _XMM6, _XMM7,
# define jit_sse_reg_p(reg) ((reg) >= _XMM0 && (reg) <= _XMM7)
#else
# if __CYGWIN__ || _WIN32
# define jit_r(i) (_RAX + (i))
# define jit_r_num() 3
# define jit_v(i) (_RBX + (i))
# define jit_v_num() 7
# define jit_f(index) (_XMM4 + (index))
# define jit_f_num() 12
# define JIT_R0 _RAX
# define JIT_R1 _R10
# define JIT_R2 _R11
# define JIT_V0 _RBX
# define JIT_V1 _RDI
# define JIT_V2 _RSI
# define JIT_V3 _R12
# define JIT_V4 _R13
# define JIT_V5 _R14
# define JIT_V6 _R15
/* Volatile - Return value register */
_RAX,
/* Volatile */
_R10, _R11,
/* Nonvolatile */
_RBX, _RDI, _RSI,
_R12, _R13, _R14, _R15,
/* Volatile - Integer arguments (4 to 1) */
_R9, _R8, _RDX, _RCX,
/* Nonvolatile */
_RSP, _RBP,
# define JIT_F0 _XMM4
# define JIT_F1 _XMM5
# define JIT_F2 _XMM6
# define JIT_F3 _XMM7
# define JIT_F4 _XMM8
# define JIT_F5 _XMM9
# define JIT_F6 _XMM10
# define JIT_F7 _XMM11
# define JIT_F8 _XMM12
# define JIT_F9 _XMM13
# define JIT_F10 _XMM14
# define JIT_F11 _XMM15
/* Volatile */
_XMM4, _XMM5,
/* Nonvolatile */
_XMM6, _XMM7, _XMM8, _XMM9, _XMM10,
_XMM11, _XMM12, _XMM13, _XMM14, _XMM15,
/* Volatile - FP arguments (4 to 1) */
_XMM3, _XMM2, _XMM1, _XMM0,
# define jit_sse_reg_p(reg) ((reg) >= _XMM4 && (reg) <= _XMM0)
# else
# define jit_r(i) (_RAX + (i))
# define jit_r_num() 3
# define jit_v(i) (_RBX + (i))
# define jit_v_num() 5
# define jit_f(index) (_XMM8 + (index))
# define jit_f_num() 8
# define JIT_R0 _RAX
# define JIT_R1 _R10
# define JIT_R2 _R11
_RAX, _R10, _R11,
# define JIT_V0 _RBX
# define JIT_V1 _R13
# define JIT_V2 _R14
# define JIT_V3 _R15
# define JIT_V4 _R12
_RBX, _R13, _R14, _R15, _R12,
_R9, _R8, _RCX, _RDX, _RSI, _RDI,
_RSP, _RBP,
# define JIT_F0 _XMM8
# define JIT_F1 _XMM9
# define JIT_F2 _XMM10
# define JIT_F3 _XMM11
# define JIT_F4 _XMM12
# define JIT_F5 _XMM13
# define JIT_F6 _XMM14
# define JIT_F7 _XMM15
_XMM8, _XMM9, _XMM10, _XMM11, _XMM12, _XMM13, _XMM14, _XMM15,
_XMM7, _XMM6, _XMM5, _XMM4, _XMM3, _XMM2, _XMM1, _XMM0,
# define jit_sse_reg_p(reg) ((reg) >= _XMM8 && (reg) <= _XMM0)
# endif
#endif
_ST0, _ST1, _ST2, _ST3, _ST4, _ST5, _ST6,
# define JIT_NOREG _NOREG
_NOREG,
} jit_reg_t;
typedef struct {
/* x87 present */
jit_uint32_t fpu : 1;
/* cmpxchg8b instruction */
jit_uint32_t cmpxchg8b : 1;
/* cmov and fcmov branchless conditional mov */
jit_uint32_t cmov : 1;
/* mmx registers/instructions available */
jit_uint32_t mmx : 1;
/* sse registers/instructions available */
jit_uint32_t sse : 1;
/* sse2 registers/instructions available */
jit_uint32_t sse2 : 1;
/* sse3 instructions available */
jit_uint32_t sse3 : 1;
/* pcmulqdq instruction */
jit_uint32_t pclmulqdq : 1;
/* ssse3 suplemental sse3 instructions available */
jit_uint32_t ssse3 : 1;
/* fused multiply/add using ymm state */
jit_uint32_t fma : 1;
/* cmpxchg16b instruction */
jit_uint32_t cmpxchg16b : 1;
/* sse4.1 instructions available */
jit_uint32_t sse4_1 : 1;
/* sse4.2 instructions available */
jit_uint32_t sse4_2 : 1;
/* movbe instruction available */
jit_uint32_t movbe : 1;
/* popcnt instruction available */
jit_uint32_t popcnt : 1;
/* aes instructions available */
jit_uint32_t aes : 1;
/* avx instructions available */
jit_uint32_t avx : 1;
/* lahf/sahf available in 64 bits mode */
jit_uint32_t lahf : 1;
/* lzcnt and tzcnt? */
jit_uint32_t abm : 1;
/* adcx and adox instructions available? */
jit_uint32_t adx : 1;
/* pdep and pext instructions available? */
jit_uint32_t bmi2 : 1;
/* fma 4 arguments instruction available? */
jit_uint32_t fma4 : 1;
} jit_cpu_t;
/*
* Initialization
*/
extern jit_cpu_t jit_cpu;
#endif /* _jit_x86_h */
@@ -0,0 +1 @@
# dummy
@@ -0,0 +1 @@
# dummy
@@ -0,0 +1 @@
# dummy
@@ -0,0 +1 @@
# dummy
@@ -0,0 +1 @@
# dummy
@@ -0,0 +1 @@
# dummy
+779
View File
@@ -0,0 +1,779 @@
# Makefile.in generated by automake 1.16.5 from Makefile.am.
# lib/Makefile. Generated from Makefile.in by configure.
# Copyright (C) 1994-2021 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
#
# Copyright 2000, 2001, 2002, 2012-2022 Free Software Foundation, Inc.
#
# This file is part of GNU lightning.
#
# GNU lightning is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 3, or (at your option)
# any later version.
#
# GNU lightning is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
# License for more details.
#
am__is_gnu_make = { \
if test -z '$(MAKELEVEL)'; then \
false; \
elif test -n '$(MAKE_HOST)'; then \
true; \
elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
true; \
else \
false; \
fi; \
}
am__make_running_with_option = \
case $${target_option-} in \
?) ;; \
*) echo "am__make_running_with_option: internal error: invalid" \
"target option '$${target_option-}' specified" >&2; \
exit 1;; \
esac; \
has_opt=no; \
sane_makeflags=$$MAKEFLAGS; \
if $(am__is_gnu_make); then \
sane_makeflags=$$MFLAGS; \
else \
case $$MAKEFLAGS in \
*\\[\ \ ]*) \
bs=\\; \
sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
| sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
esac; \
fi; \
skip_next=no; \
strip_trailopt () \
{ \
flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
}; \
for flg in $$sane_makeflags; do \
test $$skip_next = yes && { skip_next=no; continue; }; \
case $$flg in \
*=*|--*) continue;; \
-*I) strip_trailopt 'I'; skip_next=yes;; \
-*I?*) strip_trailopt 'I';; \
-*O) strip_trailopt 'O'; skip_next=yes;; \
-*O?*) strip_trailopt 'O';; \
-*l) strip_trailopt 'l'; skip_next=yes;; \
-*l?*) strip_trailopt 'l';; \
-[dEDm]) skip_next=yes;; \
-[JT]) skip_next=yes;; \
esac; \
case $$flg in \
*$$target_option*) has_opt=yes; break;; \
esac; \
done; \
test $$has_opt = yes
am__make_dryrun = (target_option=n; $(am__make_running_with_option))
am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
pkgdatadir = $(datadir)/lightning
pkgincludedir = $(includedir)/lightning
pkglibdir = $(libdir)/lightning
pkglibexecdir = $(libexecdir)/lightning
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = x86_64-pc-linux-gnu
host_triplet = x86_64-pc-linux-gnu
target_triplet = x86_64-pc-linux-gnu
#am__append_1 = -DGET_JIT_SIZE=1 -DJIT_SIZE_PATH='$(JIT_SIZE_PATH)'
#am__append_2 = -DSTRONG_TYPE_CHECKING=1
subdir = lib
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
$(top_srcdir)/m4/gnulib-common.m4 \
$(top_srcdir)/m4/gnulib-comp.m4 $(top_srcdir)/m4/libtool.m4 \
$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
$(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
$(top_srcdir)/m4/zzgnulib.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
*) f=$$p;; \
esac;
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
am__install_max = 40
am__nobase_strip_setup = \
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
am__nobase_strip = \
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
am__nobase_list = $(am__nobase_strip_setup); \
for p in $$list; do echo "$$p $$p"; done | \
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
if (++n[$$2] == $(am__install_max)) \
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
END { for (dir in files) print dir, files[dir] }'
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
am__uninstall_files_from_dir = { \
test -z "$$files" \
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__installdirs = "$(DESTDIR)$(liblightningdir)"
LTLIBRARIES = $(liblightning_LTLIBRARIES)
liblightning_la_LIBADD =
am_liblightning_la_OBJECTS = jit_disasm.lo jit_memory.lo jit_note.lo \
jit_print.lo jit_size.lo lightning.lo
liblightning_la_OBJECTS = $(am_liblightning_la_OBJECTS)
AM_V_lt = $(am__v_lt_$(V))
am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
am__v_lt_0 = --silent
am__v_lt_1 =
liblightning_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \
$(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \
$(AM_CFLAGS) $(CFLAGS) $(liblightning_la_LDFLAGS) $(LDFLAGS) \
-o $@
AM_V_P = $(am__v_P_$(V))
am__v_P_ = $(am__v_P_$(AM_DEFAULT_VERBOSITY))
am__v_P_0 = false
am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_$(V))
am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
am__v_GEN_0 = @echo " GEN " $@;
am__v_GEN_1 =
AM_V_at = $(am__v_at_$(V))
am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
am__v_at_0 = @
am__v_at_1 =
DEFAULT_INCLUDES = -I. -I$(top_builddir)
depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
am__maybe_remake_depfiles = depfiles
am__depfiles_remade = ./$(DEPDIR)/jit_disasm.Plo \
./$(DEPDIR)/jit_memory.Plo ./$(DEPDIR)/jit_note.Plo \
./$(DEPDIR)/jit_print.Plo ./$(DEPDIR)/jit_size.Plo \
./$(DEPDIR)/lightning.Plo
am__mv = mv -f
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
$(AM_CFLAGS) $(CFLAGS)
AM_V_CC = $(am__v_CC_$(V))
am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY))
am__v_CC_0 = @echo " CC " $@;
am__v_CC_1 =
CCLD = $(CC)
LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
$(AM_LDFLAGS) $(LDFLAGS) -o $@
AM_V_CCLD = $(am__v_CCLD_$(V))
am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY))
am__v_CCLD_0 = @echo " CCLD " $@;
am__v_CCLD_1 =
SOURCES = $(liblightning_la_SOURCES)
DIST_SOURCES = $(liblightning_la_SOURCES)
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
am__uniquify_input = $(AWK) '\
BEGIN { nonempty = 0; } \
{ items[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in items) print i; }; } \
'
# Make sure the list of sources is unique. This is necessary because,
# e.g., the same source file might be shared among _SOURCES variables
# for different programs/libraries.
am__define_uniq_tagged_files = \
list='$(am__tagged_files)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
am__DIST_COMMON = $(srcdir)/Makefile.in \
$(top_srcdir)/build-aux/depcomp
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' aclocal-1.16
AMTAR = $${TAR-tar}
AM_DEFAULT_VERBOSITY = 0
AR = ar
ARFLAGS = cr
AUTOCONF = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' autoconf
AUTOHEADER = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' autoheader
AUTOMAKE = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' automake-1.16
AWK = gawk
CC = gcc
CCDEPMODE = depmode=gcc3
CFLAGS = -g -O2
CPP = gcc -E
CPPFLAGS =
CSCOPE = cscope
CTAGS = ctags
CYGPATH_W = echo
DEFS = -DHAVE_CONFIG_H
DEPDIR = .deps
DLLTOOL = false
DSYMUTIL =
DUMPBIN =
ECHO_C =
ECHO_N = -n
ECHO_T =
EGREP = /usr/bin/grep -E
ETAGS = etags
EXEEXT =
FGREP = /usr/bin/grep -F
FILECMD = file
GREP = /usr/bin/grep
INSTALL = /usr/bin/install -c
INSTALL_DATA = ${INSTALL} -m 644
INSTALL_PROGRAM = ${INSTALL}
INSTALL_SCRIPT = ${INSTALL}
INSTALL_STRIP_PROGRAM = $(install_sh) -c -s
LD = /usr/bin/ld -m elf_x86_64
LDFLAGS =
LIBOBJS =
LIBS = -lz
LIBTOOL = $(SHELL) $(top_builddir)/libtool
LIGHTNING_CFLAGS = -DNDEBUG
LIPO =
LN_S = ln -s
LTLIBOBJS =
LT_SYS_LIBRARY_PATH =
MAKEINFO = ${SHELL} '/var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/missing' makeinfo
MANIFEST_TOOL = :
MAYBE_INCLUDE_STDINT_H = #include <stdint.h>
MKDIR_P = /usr/bin/mkdir -p
NM = /usr/bin/nm -B
NMEDIT =
OBJDUMP = objdump
OBJEXT = o
OTOOL =
OTOOL64 =
PACKAGE = lightning
PACKAGE_BUGREPORT = pcpa@gnu.org
PACKAGE_NAME = GNU lightning
PACKAGE_STRING = GNU lightning 2.2.2
PACKAGE_TARNAME = lightning
PACKAGE_URL = https://www.gnu.org/software/lightning/
PACKAGE_VERSION = 2.2.2
PATH_SEPARATOR = :
RANLIB = ranlib
SED = /usr/bin/sed
SET_MAKE =
SHELL = /bin/sh
SHLIB = -ldl
STRIP = strip
VERSION = 2.2.2
abs_builddir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/lib
abs_srcdir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/lib
abs_top_builddir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2
abs_top_srcdir = /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2
ac_ct_AR = ar
ac_ct_CC = gcc
ac_ct_DUMPBIN =
am__include = include
am__leading_dot = .
am__quote =
am__tar = $${TAR-tar} chof - "$$tardir"
am__untar = $${TAR-tar} xf -
bindir = ${exec_prefix}/bin
build = x86_64-pc-linux-gnu
build_alias =
build_cpu = x86_64
build_os = linux-gnu
build_vendor = pc
builddir = .
cpu = x86
datadir = ${datarootdir}
datarootdir = ${prefix}/share
docdir = ${datarootdir}/doc/${PACKAGE_TARNAME}
dvidir = ${docdir}
exec_prefix = ${prefix}
gl_LIBOBJS =
gl_LTLIBOBJS =
gltests_LIBOBJS =
gltests_LTLIBOBJS =
gltests_WITNESS = IN_LIGHTNING_GNULIB_TESTS
host = x86_64-pc-linux-gnu
host_alias =
host_cpu = x86_64
host_os = linux-gnu
host_vendor = pc
htmldir = ${docdir}
includedir = ${prefix}/include
infodir = ${datarootdir}/info
install_sh = ${SHELL} /var/home/loganmc10/git_stuff/simple64/parallel-rsp/lightning-2.2.2/build-aux/install-sh
libdir = ${exec_prefix}/lib
libexecdir = ${exec_prefix}/libexec
localedir = ${datarootdir}/locale
localstatedir = ${prefix}/var
mandir = ${datarootdir}/man
mkdir_p = $(MKDIR_P)
oldincludedir = /usr/include
pdfdir = ${docdir}
prefix = /usr/local
program_transform_name = s,x,x,
psdir = ${docdir}
runstatedir = ${localstatedir}/run
sbindir = ${exec_prefix}/sbin
sharedstatedir = ${prefix}/com
srcdir = .
sysconfdir = ${prefix}/etc
target = x86_64-pc-linux-gnu
target_alias =
target_cpu = x86_64
target_os = linux-gnu
target_vendor = pc
top_build_prefix = ../
top_builddir = ..
top_srcdir = ..
AM_CFLAGS = -I$(top_builddir)/include -I$(top_srcdir)/include \
-D_GNU_SOURCE $(LIGHTNING_CFLAGS)
liblightning_LTLIBRARIES = liblightning.la
liblightning_la_LDFLAGS = -version-info 2:1:0
AM_CPPFLAGS = $(am__append_1) $(am__append_2)
#JIT_SIZE_PATH = "$(top_builddir)/jit_$(cpu)-sz.c"
liblightningdir = $(libdir)
liblightning_la_SOURCES = \
jit_disasm.c \
jit_memory.c \
jit_note.c \
jit_print.c \
jit_size.c \
lightning.c
EXTRA_DIST = \
jit_names.c \
jit_fallback.c \
jit_rewind.c \
aarch64-logical-immediates.c \
jit_aarch64.c \
jit_aarch64-cpu.c \
jit_aarch64-fpu.c \
jit_aarch64-sz.c \
jit_alpha.c \
jit_alpha-cpu.c \
jit_alpha-fpu.c \
jit_alpha-sz.c \
jit_arm.c \
jit_arm-cpu.c \
jit_arm-swf.c \
jit_arm-vfp.c \
jit_arm-sz.c \
jit_hppa.c \
jit_hppa-cpu.c \
jit_hppa-fpu.c \
jit_hppa-sz.c \
jit_ia64.c \
jit_ia64-cpu.c \
jit_ia64-fpu.c \
jit_ia64-sz.c \
jit_loongarch.c \
jit_loongarch-cpu.c \
jit_loongarch-fpu.c \
jit_loongarch-sz.c \
jit_mips.c \
jit_mips-cpu.c \
jit_mips-fpu.c \
jit_mips-sz.c \
jit_ppc.c \
jit_ppc-cpu.c \
jit_ppc-fpu.c \
jit_ppc-sz.c \
jit_riscv.c \
jit_riscv-cpu.c \
jit_riscv-fpu.c \
jit_riscv-sz.c \
jit_s390.c \
jit_s390-cpu.c \
jit_s390-fpu.c \
jit_s390-sz.c \
jit_sparc.c \
jit_sparc-cpu.c \
jit_sparc-fpu.c \
jit_sparc-sz.c \
jit_x86.c \
jit_x86-cpu.c \
jit_x86-sse.c \
jit_x86-x87.c \
jit_x86-sz.c
all: all-am
.SUFFIXES:
.SUFFIXES: .c .lo .o .obj
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
&& { if test -f $@; then exit 0; else break; fi; }; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lib/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --gnu lib/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
install-liblightningLTLIBRARIES: $(liblightning_LTLIBRARIES)
@$(NORMAL_INSTALL)
@list='$(liblightning_LTLIBRARIES)'; test -n "$(liblightningdir)" || list=; \
list2=; for p in $$list; do \
if test -f $$p; then \
list2="$$list2 $$p"; \
else :; fi; \
done; \
test -z "$$list2" || { \
echo " $(MKDIR_P) '$(DESTDIR)$(liblightningdir)'"; \
$(MKDIR_P) "$(DESTDIR)$(liblightningdir)" || exit 1; \
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(liblightningdir)'"; \
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(liblightningdir)"; \
}
uninstall-liblightningLTLIBRARIES:
@$(NORMAL_UNINSTALL)
@list='$(liblightning_LTLIBRARIES)'; test -n "$(liblightningdir)" || list=; \
for p in $$list; do \
$(am__strip_dir) \
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(liblightningdir)/$$f'"; \
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(liblightningdir)/$$f"; \
done
clean-liblightningLTLIBRARIES:
-test -z "$(liblightning_LTLIBRARIES)" || rm -f $(liblightning_LTLIBRARIES)
@list='$(liblightning_LTLIBRARIES)'; \
locs=`for p in $$list; do echo $$p; done | \
sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
sort -u`; \
test -z "$$locs" || { \
echo rm -f $${locs}; \
rm -f $${locs}; \
}
liblightning.la: $(liblightning_la_OBJECTS) $(liblightning_la_DEPENDENCIES) $(EXTRA_liblightning_la_DEPENDENCIES)
$(AM_V_CCLD)$(liblightning_la_LINK) -rpath $(liblightningdir) $(liblightning_la_OBJECTS) $(liblightning_la_LIBADD) $(LIBS)
mostlyclean-compile:
-rm -f *.$(OBJEXT)
distclean-compile:
-rm -f *.tab.c
include ./$(DEPDIR)/jit_disasm.Plo # am--include-marker
include ./$(DEPDIR)/jit_memory.Plo # am--include-marker
include ./$(DEPDIR)/jit_note.Plo # am--include-marker
include ./$(DEPDIR)/jit_print.Plo # am--include-marker
include ./$(DEPDIR)/jit_size.Plo # am--include-marker
include ./$(DEPDIR)/lightning.Plo # am--include-marker
$(am__depfiles_remade):
@$(MKDIR_P) $(@D)
@echo '# dummy' >$@-t && $(am__mv) $@-t $@
am--depfiles: $(am__depfiles_remade)
.c.o:
$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
# $(AM_V_CC)source='$<' object='$@' libtool=no \
# DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) \
# $(AM_V_CC_no)$(COMPILE) -c -o $@ $<
.c.obj:
$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
# $(AM_V_CC)source='$<' object='$@' libtool=no \
# DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) \
# $(AM_V_CC_no)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
.c.lo:
$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
# $(AM_V_CC)source='$<' object='$@' libtool=yes \
# DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) \
# $(AM_V_CC_no)$(LTCOMPILE) -c -o $@ $<
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
ID: $(am__tagged_files)
$(am__define_uniq_tagged_files); mkid -fID $$unique
tags: tags-am
TAGS: tags
tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
set x; \
here=`pwd`; \
$(am__define_uniq_tagged_files); \
shift; \
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
if test $$# -gt 0; then \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
"$$@" $$unique; \
else \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$unique; \
fi; \
fi
ctags: ctags-am
CTAGS: ctags
ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
$(am__define_uniq_tagged_files); \
test -z "$(CTAGS_ARGS)$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
cscopelist: cscopelist-am
cscopelist-am: $(am__tagged_files)
list='$(am__tagged_files)'; \
case "$(srcdir)" in \
[\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
*) sdir=$(subdir)/$(srcdir) ;; \
esac; \
for i in $$list; do \
if test -f "$$i"; then \
echo "$(subdir)/$$i"; \
else \
echo "$$sdir/$$i"; \
fi; \
done >> $(top_builddir)/cscope.files
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
check-am: all-am
check: check-am
all-am: Makefile $(LTLIBRARIES)
installdirs:
for dir in "$(DESTDIR)$(liblightningdir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-am
install-exec: install-exec-am
install-data: install-data-am
uninstall: uninstall-am
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-am
install-strip:
if test -z '$(STRIP)'; then \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
install; \
else \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
fi
mostlyclean-generic:
clean-generic:
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
clean-am: clean-generic clean-liblightningLTLIBRARIES clean-libtool \
mostlyclean-am
distclean: distclean-am
-rm -f ./$(DEPDIR)/jit_disasm.Plo
-rm -f ./$(DEPDIR)/jit_memory.Plo
-rm -f ./$(DEPDIR)/jit_note.Plo
-rm -f ./$(DEPDIR)/jit_print.Plo
-rm -f ./$(DEPDIR)/jit_size.Plo
-rm -f ./$(DEPDIR)/lightning.Plo
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-tags
dvi: dvi-am
dvi-am:
html: html-am
html-am:
info: info-am
info-am:
install-data-am: install-liblightningLTLIBRARIES
install-dvi: install-dvi-am
install-dvi-am:
install-exec-am:
install-html: install-html-am
install-html-am:
install-info: install-info-am
install-info-am:
install-man:
install-pdf: install-pdf-am
install-pdf-am:
install-ps: install-ps-am
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -f ./$(DEPDIR)/jit_disasm.Plo
-rm -f ./$(DEPDIR)/jit_memory.Plo
-rm -f ./$(DEPDIR)/jit_note.Plo
-rm -f ./$(DEPDIR)/jit_print.Plo
-rm -f ./$(DEPDIR)/jit_size.Plo
-rm -f ./$(DEPDIR)/lightning.Plo
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-am
mostlyclean-am: mostlyclean-compile mostlyclean-generic \
mostlyclean-libtool
pdf: pdf-am
pdf-am:
ps: ps-am
ps-am:
uninstall-am: uninstall-liblightningLTLIBRARIES
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
clean-generic clean-liblightningLTLIBRARIES clean-libtool \
cscopelist-am ctags ctags-am distclean distclean-compile \
distclean-generic distclean-libtool distclean-tags distdir dvi \
dvi-am html html-am info info-am install install-am \
install-data install-data-am install-dvi install-dvi-am \
install-exec install-exec-am install-html install-html-am \
install-info install-info-am install-liblightningLTLIBRARIES \
install-man install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs maintainer-clean maintainer-clean-generic \
mostlyclean mostlyclean-compile mostlyclean-generic \
mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
uninstall-am uninstall-liblightningLTLIBRARIES
.PRECIOUS: Makefile
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
@@ -0,0 +1,94 @@
#
# Copyright 2000, 2001, 2002, 2012-2022 Free Software Foundation, Inc.
#
# This file is part of GNU lightning.
#
# GNU lightning is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 3, or (at your option)
# any later version.
#
# GNU lightning is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
# License for more details.
#
AM_CFLAGS = -I$(top_builddir)/include -I$(top_srcdir)/include \
-D_GNU_SOURCE $(LIGHTNING_CFLAGS)
liblightning_LTLIBRARIES = liblightning.la
liblightning_la_LDFLAGS = -version-info 2:1:0
AM_CPPFLAGS =
if get_jit_size
JIT_SIZE_PATH = "$(top_builddir)/jit_$(cpu)-sz.c"
AM_CPPFLAGS += -DGET_JIT_SIZE=1 -DJIT_SIZE_PATH='$(JIT_SIZE_PATH)'
endif
if strong_type_checking
AM_CPPFLAGS += -DSTRONG_TYPE_CHECKING=1
endif
liblightningdir = $(libdir)
liblightning_la_SOURCES = \
jit_disasm.c \
jit_memory.c \
jit_note.c \
jit_print.c \
jit_size.c \
lightning.c
EXTRA_DIST = \
jit_names.c \
jit_fallback.c \
jit_rewind.c \
aarch64-logical-immediates.c \
jit_aarch64.c \
jit_aarch64-cpu.c \
jit_aarch64-fpu.c \
jit_aarch64-sz.c \
jit_alpha.c \
jit_alpha-cpu.c \
jit_alpha-fpu.c \
jit_alpha-sz.c \
jit_arm.c \
jit_arm-cpu.c \
jit_arm-swf.c \
jit_arm-vfp.c \
jit_arm-sz.c \
jit_hppa.c \
jit_hppa-cpu.c \
jit_hppa-fpu.c \
jit_hppa-sz.c \
jit_ia64.c \
jit_ia64-cpu.c \
jit_ia64-fpu.c \
jit_ia64-sz.c \
jit_loongarch.c \
jit_loongarch-cpu.c \
jit_loongarch-fpu.c \
jit_loongarch-sz.c \
jit_mips.c \
jit_mips-cpu.c \
jit_mips-fpu.c \
jit_mips-sz.c \
jit_ppc.c \
jit_ppc-cpu.c \
jit_ppc-fpu.c \
jit_ppc-sz.c \
jit_riscv.c \
jit_riscv-cpu.c \
jit_riscv-fpu.c \
jit_riscv-sz.c \
jit_s390.c \
jit_s390-cpu.c \
jit_s390-fpu.c \
jit_s390-sz.c \
jit_sparc.c \
jit_sparc-cpu.c \
jit_sparc-fpu.c \
jit_sparc-sz.c \
jit_x86.c \
jit_x86-cpu.c \
jit_x86-sse.c \
jit_x86-x87.c \
jit_x86-sz.c
@@ -0,0 +1,779 @@
# Makefile.in generated by automake 1.16.5 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2021 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
@SET_MAKE@
#
# Copyright 2000, 2001, 2002, 2012-2022 Free Software Foundation, Inc.
#
# This file is part of GNU lightning.
#
# GNU lightning is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 3, or (at your option)
# any later version.
#
# GNU lightning is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
# License for more details.
#
VPATH = @srcdir@
am__is_gnu_make = { \
if test -z '$(MAKELEVEL)'; then \
false; \
elif test -n '$(MAKE_HOST)'; then \
true; \
elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
true; \
else \
false; \
fi; \
}
am__make_running_with_option = \
case $${target_option-} in \
?) ;; \
*) echo "am__make_running_with_option: internal error: invalid" \
"target option '$${target_option-}' specified" >&2; \
exit 1;; \
esac; \
has_opt=no; \
sane_makeflags=$$MAKEFLAGS; \
if $(am__is_gnu_make); then \
sane_makeflags=$$MFLAGS; \
else \
case $$MAKEFLAGS in \
*\\[\ \ ]*) \
bs=\\; \
sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
| sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
esac; \
fi; \
skip_next=no; \
strip_trailopt () \
{ \
flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
}; \
for flg in $$sane_makeflags; do \
test $$skip_next = yes && { skip_next=no; continue; }; \
case $$flg in \
*=*|--*) continue;; \
-*I) strip_trailopt 'I'; skip_next=yes;; \
-*I?*) strip_trailopt 'I';; \
-*O) strip_trailopt 'O'; skip_next=yes;; \
-*O?*) strip_trailopt 'O';; \
-*l) strip_trailopt 'l'; skip_next=yes;; \
-*l?*) strip_trailopt 'l';; \
-[dEDm]) skip_next=yes;; \
-[JT]) skip_next=yes;; \
esac; \
case $$flg in \
*$$target_option*) has_opt=yes; break;; \
esac; \
done; \
test $$has_opt = yes
am__make_dryrun = (target_option=n; $(am__make_running_with_option))
am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
pkgdatadir = $(datadir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkglibexecdir = $(libexecdir)/@PACKAGE@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
target_triplet = @target@
@get_jit_size_TRUE@am__append_1 = -DGET_JIT_SIZE=1 -DJIT_SIZE_PATH='$(JIT_SIZE_PATH)'
@strong_type_checking_TRUE@am__append_2 = -DSTRONG_TYPE_CHECKING=1
subdir = lib
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
$(top_srcdir)/m4/gnulib-common.m4 \
$(top_srcdir)/m4/gnulib-comp.m4 $(top_srcdir)/m4/libtool.m4 \
$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
$(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
$(top_srcdir)/m4/zzgnulib.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
*) f=$$p;; \
esac;
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
am__install_max = 40
am__nobase_strip_setup = \
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
am__nobase_strip = \
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
am__nobase_list = $(am__nobase_strip_setup); \
for p in $$list; do echo "$$p $$p"; done | \
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
if (++n[$$2] == $(am__install_max)) \
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
END { for (dir in files) print dir, files[dir] }'
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
am__uninstall_files_from_dir = { \
test -z "$$files" \
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__installdirs = "$(DESTDIR)$(liblightningdir)"
LTLIBRARIES = $(liblightning_LTLIBRARIES)
liblightning_la_LIBADD =
am_liblightning_la_OBJECTS = jit_disasm.lo jit_memory.lo jit_note.lo \
jit_print.lo jit_size.lo lightning.lo
liblightning_la_OBJECTS = $(am_liblightning_la_OBJECTS)
AM_V_lt = $(am__v_lt_@AM_V@)
am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
am__v_lt_0 = --silent
am__v_lt_1 =
liblightning_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \
$(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \
$(AM_CFLAGS) $(CFLAGS) $(liblightning_la_LDFLAGS) $(LDFLAGS) \
-o $@
AM_V_P = $(am__v_P_@AM_V@)
am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
am__v_P_0 = false
am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_@AM_V@)
am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
am__v_GEN_0 = @echo " GEN " $@;
am__v_GEN_1 =
AM_V_at = $(am__v_at_@AM_V@)
am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
am__v_at_1 =
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
am__maybe_remake_depfiles = depfiles
am__depfiles_remade = ./$(DEPDIR)/jit_disasm.Plo \
./$(DEPDIR)/jit_memory.Plo ./$(DEPDIR)/jit_note.Plo \
./$(DEPDIR)/jit_print.Plo ./$(DEPDIR)/jit_size.Plo \
./$(DEPDIR)/lightning.Plo
am__mv = mv -f
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
$(AM_CFLAGS) $(CFLAGS)
AM_V_CC = $(am__v_CC_@AM_V@)
am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
am__v_CC_0 = @echo " CC " $@;
am__v_CC_1 =
CCLD = $(CC)
LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
$(AM_LDFLAGS) $(LDFLAGS) -o $@
AM_V_CCLD = $(am__v_CCLD_@AM_V@)
am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
am__v_CCLD_0 = @echo " CCLD " $@;
am__v_CCLD_1 =
SOURCES = $(liblightning_la_SOURCES)
DIST_SOURCES = $(liblightning_la_SOURCES)
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
am__uniquify_input = $(AWK) '\
BEGIN { nonempty = 0; } \
{ items[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in items) print i; }; } \
'
# Make sure the list of sources is unique. This is necessary because,
# e.g., the same source file might be shared among _SOURCES variables
# for different programs/libraries.
am__define_uniq_tagged_files = \
list='$(am__tagged_files)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
am__DIST_COMMON = $(srcdir)/Makefile.in \
$(top_srcdir)/build-aux/depcomp
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
AR = @AR@
ARFLAGS = @ARFLAGS@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CSCOPE = @CSCOPE@
CTAGS = @CTAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
DLLTOOL = @DLLTOOL@
DSYMUTIL = @DSYMUTIL@
DUMPBIN = @DUMPBIN@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
ETAGS = @ETAGS@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
FILECMD = @FILECMD@
GREP = @GREP@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@
LDFLAGS = @LDFLAGS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
LIGHTNING_CFLAGS = @LIGHTNING_CFLAGS@
LIPO = @LIPO@
LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@
LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
MAKEINFO = @MAKEINFO@
MANIFEST_TOOL = @MANIFEST_TOOL@
MAYBE_INCLUDE_STDINT_H = @MAYBE_INCLUDE_STDINT_H@
MKDIR_P = @MKDIR_P@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
OTOOL = @OTOOL@
OTOOL64 = @OTOOL64@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_URL = @PACKAGE_URL@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
RANLIB = @RANLIB@
SED = @SED@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SHLIB = @SHLIB@
STRIP = @STRIP@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_AR = @ac_ct_AR@
ac_ct_CC = @ac_ct_CC@
ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__tar = @am__tar@
am__untar = @am__untar@
bindir = @bindir@
build = @build@
build_alias = @build_alias@
build_cpu = @build_cpu@
build_os = @build_os@
build_vendor = @build_vendor@
builddir = @builddir@
cpu = @cpu@
datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
gl_LIBOBJS = @gl_LIBOBJS@
gl_LTLIBOBJS = @gl_LTLIBOBJS@
gltests_LIBOBJS = @gltests_LIBOBJS@
gltests_LTLIBOBJS = @gltests_LTLIBOBJS@
gltests_WITNESS = @gltests_WITNESS@
host = @host@
host_alias = @host_alias@
host_cpu = @host_cpu@
host_os = @host_os@
host_vendor = @host_vendor@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
runstatedir = @runstatedir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target = @target@
target_alias = @target_alias@
target_cpu = @target_cpu@
target_os = @target_os@
target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
AM_CFLAGS = -I$(top_builddir)/include -I$(top_srcdir)/include \
-D_GNU_SOURCE $(LIGHTNING_CFLAGS)
liblightning_LTLIBRARIES = liblightning.la
liblightning_la_LDFLAGS = -version-info 2:1:0
AM_CPPFLAGS = $(am__append_1) $(am__append_2)
@get_jit_size_TRUE@JIT_SIZE_PATH = "$(top_builddir)/jit_$(cpu)-sz.c"
liblightningdir = $(libdir)
liblightning_la_SOURCES = \
jit_disasm.c \
jit_memory.c \
jit_note.c \
jit_print.c \
jit_size.c \
lightning.c
EXTRA_DIST = \
jit_names.c \
jit_fallback.c \
jit_rewind.c \
aarch64-logical-immediates.c \
jit_aarch64.c \
jit_aarch64-cpu.c \
jit_aarch64-fpu.c \
jit_aarch64-sz.c \
jit_alpha.c \
jit_alpha-cpu.c \
jit_alpha-fpu.c \
jit_alpha-sz.c \
jit_arm.c \
jit_arm-cpu.c \
jit_arm-swf.c \
jit_arm-vfp.c \
jit_arm-sz.c \
jit_hppa.c \
jit_hppa-cpu.c \
jit_hppa-fpu.c \
jit_hppa-sz.c \
jit_ia64.c \
jit_ia64-cpu.c \
jit_ia64-fpu.c \
jit_ia64-sz.c \
jit_loongarch.c \
jit_loongarch-cpu.c \
jit_loongarch-fpu.c \
jit_loongarch-sz.c \
jit_mips.c \
jit_mips-cpu.c \
jit_mips-fpu.c \
jit_mips-sz.c \
jit_ppc.c \
jit_ppc-cpu.c \
jit_ppc-fpu.c \
jit_ppc-sz.c \
jit_riscv.c \
jit_riscv-cpu.c \
jit_riscv-fpu.c \
jit_riscv-sz.c \
jit_s390.c \
jit_s390-cpu.c \
jit_s390-fpu.c \
jit_s390-sz.c \
jit_sparc.c \
jit_sparc-cpu.c \
jit_sparc-fpu.c \
jit_sparc-sz.c \
jit_x86.c \
jit_x86-cpu.c \
jit_x86-sse.c \
jit_x86-x87.c \
jit_x86-sz.c
all: all-am
.SUFFIXES:
.SUFFIXES: .c .lo .o .obj
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
&& { if test -f $@; then exit 0; else break; fi; }; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu lib/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --gnu lib/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
install-liblightningLTLIBRARIES: $(liblightning_LTLIBRARIES)
@$(NORMAL_INSTALL)
@list='$(liblightning_LTLIBRARIES)'; test -n "$(liblightningdir)" || list=; \
list2=; for p in $$list; do \
if test -f $$p; then \
list2="$$list2 $$p"; \
else :; fi; \
done; \
test -z "$$list2" || { \
echo " $(MKDIR_P) '$(DESTDIR)$(liblightningdir)'"; \
$(MKDIR_P) "$(DESTDIR)$(liblightningdir)" || exit 1; \
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(liblightningdir)'"; \
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(liblightningdir)"; \
}
uninstall-liblightningLTLIBRARIES:
@$(NORMAL_UNINSTALL)
@list='$(liblightning_LTLIBRARIES)'; test -n "$(liblightningdir)" || list=; \
for p in $$list; do \
$(am__strip_dir) \
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(liblightningdir)/$$f'"; \
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(liblightningdir)/$$f"; \
done
clean-liblightningLTLIBRARIES:
-test -z "$(liblightning_LTLIBRARIES)" || rm -f $(liblightning_LTLIBRARIES)
@list='$(liblightning_LTLIBRARIES)'; \
locs=`for p in $$list; do echo $$p; done | \
sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
sort -u`; \
test -z "$$locs" || { \
echo rm -f $${locs}; \
rm -f $${locs}; \
}
liblightning.la: $(liblightning_la_OBJECTS) $(liblightning_la_DEPENDENCIES) $(EXTRA_liblightning_la_DEPENDENCIES)
$(AM_V_CCLD)$(liblightning_la_LINK) -rpath $(liblightningdir) $(liblightning_la_OBJECTS) $(liblightning_la_LIBADD) $(LIBS)
mostlyclean-compile:
-rm -f *.$(OBJEXT)
distclean-compile:
-rm -f *.tab.c
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jit_disasm.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jit_memory.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jit_note.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jit_print.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jit_size.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lightning.Plo@am__quote@ # am--include-marker
$(am__depfiles_remade):
@$(MKDIR_P) $(@D)
@echo '# dummy' >$@-t && $(am__mv) $@-t $@
am--depfiles: $(am__depfiles_remade)
.c.o:
@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
.c.obj:
@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
.c.lo:
@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
ID: $(am__tagged_files)
$(am__define_uniq_tagged_files); mkid -fID $$unique
tags: tags-am
TAGS: tags
tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
set x; \
here=`pwd`; \
$(am__define_uniq_tagged_files); \
shift; \
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
if test $$# -gt 0; then \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
"$$@" $$unique; \
else \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$unique; \
fi; \
fi
ctags: ctags-am
CTAGS: ctags
ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
$(am__define_uniq_tagged_files); \
test -z "$(CTAGS_ARGS)$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
cscopelist: cscopelist-am
cscopelist-am: $(am__tagged_files)
list='$(am__tagged_files)'; \
case "$(srcdir)" in \
[\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
*) sdir=$(subdir)/$(srcdir) ;; \
esac; \
for i in $$list; do \
if test -f "$$i"; then \
echo "$(subdir)/$$i"; \
else \
echo "$$sdir/$$i"; \
fi; \
done >> $(top_builddir)/cscope.files
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
check-am: all-am
check: check-am
all-am: Makefile $(LTLIBRARIES)
installdirs:
for dir in "$(DESTDIR)$(liblightningdir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-am
install-exec: install-exec-am
install-data: install-data-am
uninstall: uninstall-am
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-am
install-strip:
if test -z '$(STRIP)'; then \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
install; \
else \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
fi
mostlyclean-generic:
clean-generic:
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
clean-am: clean-generic clean-liblightningLTLIBRARIES clean-libtool \
mostlyclean-am
distclean: distclean-am
-rm -f ./$(DEPDIR)/jit_disasm.Plo
-rm -f ./$(DEPDIR)/jit_memory.Plo
-rm -f ./$(DEPDIR)/jit_note.Plo
-rm -f ./$(DEPDIR)/jit_print.Plo
-rm -f ./$(DEPDIR)/jit_size.Plo
-rm -f ./$(DEPDIR)/lightning.Plo
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-tags
dvi: dvi-am
dvi-am:
html: html-am
html-am:
info: info-am
info-am:
install-data-am: install-liblightningLTLIBRARIES
install-dvi: install-dvi-am
install-dvi-am:
install-exec-am:
install-html: install-html-am
install-html-am:
install-info: install-info-am
install-info-am:
install-man:
install-pdf: install-pdf-am
install-pdf-am:
install-ps: install-ps-am
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -f ./$(DEPDIR)/jit_disasm.Plo
-rm -f ./$(DEPDIR)/jit_memory.Plo
-rm -f ./$(DEPDIR)/jit_note.Plo
-rm -f ./$(DEPDIR)/jit_print.Plo
-rm -f ./$(DEPDIR)/jit_size.Plo
-rm -f ./$(DEPDIR)/lightning.Plo
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-am
mostlyclean-am: mostlyclean-compile mostlyclean-generic \
mostlyclean-libtool
pdf: pdf-am
pdf-am:
ps: ps-am
ps-am:
uninstall-am: uninstall-liblightningLTLIBRARIES
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
clean-generic clean-liblightningLTLIBRARIES clean-libtool \
cscopelist-am ctags ctags-am distclean distclean-compile \
distclean-generic distclean-libtool distclean-tags distdir dvi \
dvi-am html html-am info info-am install install-am \
install-data install-data-am install-dvi install-dvi-am \
install-exec install-exec-am install-html install-html-am \
install-info install-info-am install-liblightningLTLIBRARIES \
install-man install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs maintainer-clean maintainer-clean-generic \
mostlyclean mostlyclean-compile mostlyclean-generic \
mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
uninstall-am uninstall-liblightningLTLIBRARIES
.PRECIOUS: Makefile
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
@@ -0,0 +1,161 @@
// AArch64 Logical Immediate Encoding and Decoding
//
// I hereby place this code in the public domain, as per the terms of the
// CC0 license: https://creativecommons.org/publicdomain/zero/1.0/
#include <stdint.h>
#include <stdbool.h>
static inline int nonzeroCountTrailingZeros64(uint64_t n) {
return __builtin_ctzll(n);
}
static inline int countTrailingZeros64(uint64_t n) {
return n ? nonzeroCountTrailingZeros64(n) : 64;
}
static inline int nonzeroCountLeadingZeros64(uint64_t n) {
return __builtin_clzll(n);
}
static inline int nonzeroCountLeadingZeros32(uint32_t n) {
return __builtin_clz(n);
}
static inline uint64_t rotateRight64(uint64_t v, int n) {
// return __builtin_rotateright64(v, n);
return (v >> (n & 63)) | (v << (-n & 63));
}
static inline uint64_t clearTrailingOnes64(uint64_t n) {
return n & (n + 1);
}
#define ENCODE_FAILED (-1)
int encodeLogicalImmediate64(uint64_t val) {
// Consider an ARM64 logical immediate as a pattern of "o" ones preceded
// by "z" more-significant zeroes, repeated to fill a 64-bit integer.
// o > 0, z > 0, and the size (o + z) is a power of two in [2,64]. This
// part of the pattern is encoded in the fields "imms" and "N".
//
// "immr" encodes a further right rotate of the repeated pattern, allowing
// a wide range of useful bitwise constants to be represented.
//
// (The spec describes the "immr" rotate as rotating the "o + z" bit
// pattern before repeating it to fill 64-bits, but, as it's a repeating
// pattern, rotating afterwards is equivalent.)
// This encoding is not allowed to represent all-zero or all-one values.
if (val == 0 || ~val == 0)
return ENCODE_FAILED;
// To detect an immediate that may be encoded in this scheme, we first
// remove the right-rotate, by rotating such that the least significant
// bit is a one and the most significant bit is a zero.
//
// We do this by clearing any trailing one bits, then counting the
// trailing zeroes. This finds an "edge", where zero goes to one.
// We then rotate the original value right by that amount, moving
// the first one to the least significant bit.
int rotation = countTrailingZeros64(clearTrailingOnes64(val));
uint64_t normalized = rotateRight64(val, rotation & 63);
// Now we have normalized the value, and determined the rotation, we can
// determine "z" by counting the leading zeroes, and "o" by counting the
// trailing ones. (These will both be positive, as we already rejected 0
// and ~0, and rotated the value to start with a zero and end with a one.)
int zeroes = nonzeroCountLeadingZeros64(normalized);
int ones = nonzeroCountTrailingZeros64(~normalized);
int size = zeroes + ones;
// Detect the repeating pattern (by comparing every repetition to the
// one next to it, using rotate).
if (rotateRight64(val, size & 63) != val)
return ENCODE_FAILED;
// We do not need to further validate size to ensure it is a power of two
// between 2 and 64. The only "minimal" patterns that can repeat to fill a
// 64-bit value must have a length that is a factor of 64 (i.e. it is a
// power of two in the range [1,64]). And our pattern cannot be of length
// one (as we already rejected 0 and ~0).
//
// By "minimal" patterns I refer to patterns which do not themselves
// contain repetitions. For example, '010101' is a non-minimal pattern of
// a non-power-of-two length that can pass the above rotational test. It
// consists of the minimal pattern '01'. All our patterns are minimal, as
// they contain only one contiguous run of ones separated by at least one
// zero.
// Finally, we encode the values. "rotation" is the amount we rotated
// right by to "undo" the right-rotate encoded in immr, so must be
// negated.
// size 2: N=0 immr=00000r imms=11110s
// size 4: N=0 immr=0000rr imms=1110ss
// size 8: N=0 immr=000rrr imms=110sss
// size 16: N=0 immr=00rrrr imms=10ssss
// size 32: N=0 immr=0rrrrr imms=0sssss
// size 64: N=1 immr=rrrrrr imms=ssssss
int immr = -rotation & (size - 1);
int imms = -(size << 1) | (ones - 1);
int N = (size >> 6);
return (N << 12) | (immr << 6) | (imms & 0x3f);
}
int encodeLogicalImmediate32(uint32_t val) {
return encodeLogicalImmediate64(((uint64_t)val << 32) | val);
}
// Decoding!
bool isValidLogicalImmediate64(unsigned val) {
unsigned N = (val >> 12) & 1;
unsigned imms = val & 0x3f;
unsigned pattern = (N << 6) | (~imms & 0x3f);
return (pattern & (pattern - 1)) != 0;
}
bool isValidLogicalImmediate32(unsigned val) {
unsigned N = (val >> 12) & 1;
return N == 0 && isValidLogicalImmediate64(val);
}
#define DECODE_FAILED 0
// returns DECODE_FAILED (zero) if the encoding is invalid
uint64_t decodeLogicalImmediate64(unsigned val) {
// Fun way to generate the immediates with mask ^ (mask << S)
static const uint64_t mask_lookup[] = {
0xffffffffffffffff, // size = 64
0x00000000ffffffff, // size = 32
0x0000ffff0000ffff, // size = 16
0x00ff00ff00ff00ff, // size = 8
0x0f0f0f0f0f0f0f0f, // size = 4
0x3333333333333333, // size = 2
};
unsigned N = (val >> 12) & 1;
int immr = (val >> 6) & 0x3f;
unsigned imms = val & 0x3f;
unsigned pattern = (N << 6) | (~imms & 0x3f);
if (!(pattern & (pattern - 1))) return DECODE_FAILED;
int leading_zeroes = nonzeroCountLeadingZeros32(pattern);
unsigned imms_mask = 0x7fffffff >> leading_zeroes;
uint64_t mask = mask_lookup[leading_zeroes - 25];
unsigned S = (imms + 1) & imms_mask;
return rotateRight64(mask ^ (mask << S), immr);
}
uint32_t decodeLogicalImmediate32(unsigned val) {
unsigned N = (val >> 12) & 1;
if (N) return DECODE_FAILED;
return (uint32_t)decodeLogicalImmediate64(val);
}
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,527 @@
#if __WORDSIZE == 64
#define JIT_INSTR_MAX 140
0, /* data */
0, /* live */
4, /* align */
0, /* save */
0, /* load */
4, /* skip */
0, /* #name */
0, /* #note */
0, /* label */
88, /* prolog */
0, /* ellipsis */
0, /* va_push */
0, /* allocai */
0, /* allocar */
0, /* arg_c */
0, /* arg_s */
0, /* arg_i */
0, /* arg_l */
0, /* getarg_c */
0, /* getarg_uc */
0, /* getarg_s */
0, /* getarg_us */
0, /* getarg_i */
0, /* getarg_ui */
0, /* getarg_l */
0, /* putargr_c */
0, /* putargi_c */
0, /* putargr_uc */
0, /* putargi_uc */
0, /* putargr_s */
0, /* putargi_s */
0, /* putargr_us */
0, /* putargi_us */
0, /* putargr_i */
0, /* putargi_i */
0, /* putargr_ui */
0, /* putargi_ui */
0, /* putargr_l */
0, /* putargi_l */
20, /* va_start */
24, /* va_arg */
44, /* va_arg_d */
0, /* va_end */
4, /* addr */
32, /* addi */
12, /* addcr */
40, /* addci */
28, /* addxr */
28, /* addxi */
4, /* subr */
32, /* subi */
12, /* subcr */
40, /* subci */
28, /* subxr */
28, /* subxi */
36, /* rsbi */
4, /* mulr */
32, /* muli */
44, /* qmulr */
56, /* qmuli */
12, /* qmulr_u */
32, /* qmuli_u */
44, /* divr */
68, /* divi */
44, /* divr_u */
68, /* divi_u */
52, /* qdivr */
52, /* qdivi */
52, /* qdivr_u */
52, /* qdivi_u */
44, /* remr */
68, /* remi */
44, /* remr_u */
68, /* remi_u */
4, /* andr */
32, /* andi */
4, /* orr */
32, /* ori */
4, /* xorr */
32, /* xori */
4, /* lshr */
4, /* lshi */
4, /* rshr */
4, /* rshi */
4, /* rshr_u */
4, /* rshi_u */
4, /* negr */
4, /* negi */
4, /* comr */
4, /* comi */
4, /* ltr */
4, /* lti */
4, /* ltr_u */
8, /* lti_u */
4, /* ler */
8, /* lei */
4, /* ler_u */
4, /* lei_u */
4, /* eqr */
4, /* eqi */
4, /* ger */
8, /* gei */
4, /* ger_u */
8, /* gei_u */
4, /* gtr */
8, /* gti */
4, /* gtr_u */
8, /* gti_u */
8, /* ner */
12, /* nei */
4, /* movr */
32, /* movi */
4, /* movnr */
4, /* movzr */
32, /* casr */
60, /* casi */
4, /* extr_c */
4, /* exti_c */
4, /* extr_uc */
4, /* exti_uc */
4, /* extr_s */
4, /* exti_s */
4, /* extr_us */
16, /* exti_us */
8, /* extr_i */
28, /* exti_i */
4, /* extr_ui */
16, /* exti_ui */
16, /* bswapr_us */
4, /* bswapi_us */
36, /* bswapr_ui */
16, /* bswapi_ui */
36, /* bswapr_ul */
32, /* bswapi_ul */
16, /* htonr_us */
16, /* htoni_us */
36, /* htonr_ui */
16, /* htoni_ui */
36, /* htonr_ul */
32, /* htoni_ul */
8, /* ldr_c */
36, /* ldi_c */
4, /* ldr_uc */
32, /* ldi_uc */
8, /* ldr_s */
36, /* ldi_s */
4, /* ldr_us */
32, /* ldi_us */
4, /* ldr_i */
32, /* ldi_i */
8, /* ldr_ui */
36, /* ldi_ui */
4, /* ldr_l */
32, /* ldi_l */
12, /* ldxr_c */
40, /* ldxi_c */
8, /* ldxr_uc */
36, /* ldxi_uc */
12, /* ldxr_s */
40, /* ldxi_s */
8, /* ldxr_us */
36, /* ldxi_us */
8, /* ldxr_i */
36, /* ldxi_i */
12, /* ldxr_ui */
40, /* ldxi_ui */
8, /* ldxr_l */
36, /* ldxi_l */
4, /* str_c */
32, /* sti_c */
4, /* str_s */
32, /* sti_s */
4, /* str_i */
32, /* sti_i */
4, /* str_l */
32, /* sti_l */
8, /* stxr_c */
36, /* stxi_c */
8, /* stxr_s */
36, /* stxi_s */
8, /* stxr_i */
36, /* stxi_i */
8, /* stxr_l */
36, /* stxi_l */
8, /* bltr */
8, /* blti */
8, /* bltr_u */
12, /* blti_u */
8, /* bler */
12, /* blei */
8, /* bler_u */
12, /* blei_u */
8, /* beqr */
40, /* beqi */
8, /* bger */
12, /* bgei */
8, /* bger_u */
12, /* bgei_u */
8, /* bgtr */
12, /* bgti */
8, /* bgtr_u */
12, /* bgti_u */
8, /* bner */
40, /* bnei */
8, /* bmsr */
8, /* bmsi */
8, /* bmcr */
8, /* bmci */
28, /* boaddr */
32, /* boaddi */
16, /* boaddr_u */
16, /* boaddi_u */
28, /* bxaddr */
32, /* bxaddi */
16, /* bxaddr_u */
16, /* bxaddi_u */
28, /* bosubr */
32, /* bosubi */
16, /* bosubr_u */
16, /* bosubi_u */
28, /* bxsubr */
32, /* bxsubi */
16, /* bxsubr_u */
16, /* bxsubi_u */
4, /* jmpr */
36, /* jmpi */
8, /* callr */
36, /* calli */
0, /* prepare */
0, /* pushargr_c */
0, /* pushargi_c */
0, /* pushargr_uc */
0, /* pushargi_uc */
0, /* pushargr_s */
0, /* pushargi_s */
0, /* pushargr_us */
0, /* pushargi_us */
0, /* pushargr_i */
0, /* pushargi_i */
0, /* pushargr_ui */
0, /* pushargi_ui */
0, /* pushargr_l */
0, /* pushargi_l */
0, /* finishr */
0, /* finishi */
0, /* ret */
0, /* retr_c */
0, /* reti_c */
0, /* retr_uc */
0, /* reti_uc */
0, /* retr_s */
0, /* reti_s */
0, /* retr_us */
0, /* reti_us */
0, /* retr_i */
0, /* reti_i */
0, /* retr_ui */
0, /* reti_ui */
0, /* retr_l */
0, /* reti_l */
0, /* retval_c */
0, /* retval_uc */
0, /* retval_s */
0, /* retval_us */
0, /* retval_i */
0, /* retval_ui */
0, /* retval_l */
76, /* epilog */
0, /* arg_f */
0, /* getarg_f */
0, /* putargr_f */
0, /* putargi_f */
8, /* addr_f */
40, /* addi_f */
8, /* subr_f */
40, /* subi_f */
40, /* rsbi_f */
8, /* mulr_f */
40, /* muli_f */
8, /* divr_f */
40, /* divi_f */
4, /* negr_f */
0, /* negi_f */
4, /* absr_f */
0, /* absi_f */
8, /* sqrtr_f */
0, /* sqrti_f */
32, /* ltr_f */
64, /* lti_f */
32, /* ler_f */
64, /* lei_f */
32, /* eqr_f */
64, /* eqi_f */
32, /* ger_f */
64, /* gei_f */
32, /* gtr_f */
64, /* gti_f */
32, /* ner_f */
64, /* nei_f */
32, /* unltr_f */
64, /* unlti_f */
32, /* unler_f */
64, /* unlei_f */
32, /* uneqr_f */
64, /* uneqi_f */
32, /* unger_f */
64, /* ungei_f */
32, /* ungtr_f */
64, /* ungti_f */
32, /* ltgtr_f */
64, /* ltgti_f */
20, /* ordr_f */
52, /* ordi_f */
20, /* unordr_f */
52, /* unordi_f */
16, /* truncr_f_i */
16, /* truncr_f_l */
12, /* extr_f */
4, /* extr_d_f */
4, /* movr_f */
32, /* movi_f */
4, /* ldr_f */
32, /* ldi_f */
8, /* ldxr_f */
36, /* ldxi_f */
4, /* str_f */
32, /* sti_f */
8, /* stxr_f */
36, /* stxi_f */
24, /* bltr_f */
56, /* blti_f */
24, /* bler_f */
56, /* blei_f */
24, /* beqr_f */
56, /* beqi_f */
24, /* bger_f */
56, /* bgei_f */
24, /* bgtr_f */
56, /* bgti_f */
28, /* bner_f */
60, /* bnei_f */
28, /* bunltr_f */
60, /* bunlti_f */
28, /* bunler_f */
60, /* bunlei_f */
28, /* buneqr_f */
60, /* buneqi_f */
28, /* bunger_f */
60, /* bungei_f */
28, /* bungtr_f */
60, /* bungti_f */
28, /* bltgtr_f */
60, /* bltgti_f */
12, /* bordr_f */
44, /* bordi_f */
12, /* bunordr_f */
44, /* bunordi_f */
0, /* pushargr_f */
0, /* pushargi_f */
0, /* retr_f */
0, /* reti_f */
0, /* retval_f */
0, /* arg_d */
0, /* getarg_d */
0, /* putargr_d */
0, /* putargi_d */
8, /* addr_d */
40, /* addi_d */
8, /* subr_d */
40, /* subi_d */
40, /* rsbi_d */
8, /* mulr_d */
40, /* muli_d */
8, /* divr_d */
40, /* divi_d */
4, /* negr_d */
0, /* negi_d */
4, /* absr_d */
0, /* absi_d */
8, /* sqrtr_d */
0, /* sqrti_d */
32, /* ltr_d */
64, /* lti_d */
32, /* ler_d */
64, /* lei_d */
32, /* eqr_d */
64, /* eqi_d */
32, /* ger_d */
64, /* gei_d */
32, /* gtr_d */
64, /* gti_d */
32, /* ner_d */
64, /* nei_d */
32, /* unltr_d */
64, /* unlti_d */
32, /* unler_d */
64, /* unlei_d */
32, /* uneqr_d */
64, /* uneqi_d */
32, /* unger_d */
64, /* ungei_d */
32, /* ungtr_d */
64, /* ungti_d */
32, /* ltgtr_d */
64, /* ltgti_d */
20, /* ordr_d */
52, /* ordi_d */
20, /* unordr_d */
52, /* unordi_d */
16, /* truncr_d_i */
16, /* truncr_d_l */
12, /* extr_d */
4, /* extr_f_d */
4, /* movr_d */
32, /* movi_d */
4, /* ldr_d */
32, /* ldi_d */
8, /* ldxr_d */
36, /* ldxi_d */
4, /* str_d */
32, /* sti_d */
8, /* stxr_d */
36, /* stxi_d */
24, /* bltr_d */
56, /* blti_d */
24, /* bler_d */
56, /* blei_d */
24, /* beqr_d */
56, /* beqi_d */
24, /* bger_d */
56, /* bgei_d */
24, /* bgtr_d */
56, /* bgti_d */
28, /* bner_d */
60, /* bnei_d */
28, /* bunltr_d */
60, /* bunlti_d */
28, /* bunler_d */
60, /* bunlei_d */
28, /* buneqr_d */
60, /* buneqi_d */
28, /* bunger_d */
60, /* bungei_d */
28, /* bungtr_d */
60, /* bungti_d */
28, /* bltgtr_d */
60, /* bltgti_d */
12, /* bordr_d */
44, /* bordi_d */
12, /* bunordr_d */
44, /* bunordi_d */
0, /* pushargr_d */
0, /* pushargi_d */
0, /* retr_d */
0, /* reti_d */
0, /* retval_d */
8, /* movr_w_f */
24, /* movi_w_f */
0, /* movr_ww_d */
0, /* movi_ww_d */
8, /* movr_w_d */
20, /* movi_w_d */
8, /* movr_f_w */
16, /* movi_f_w */
0, /* movr_d_ww */
0, /* movi_d_ww */
8, /* movr_d_w */
12, /* movi_d_w */
8, /* clor */
4, /* cloi */
4, /* clzr */
4, /* clzi */
8, /* ctor */
4, /* ctoi */
4, /* ctzr */
4, /* ctzi */
84, /* rbitr */
32, /* rbiti */
4, /* popcntr */
4, /* popcnti */
20, /* lrotr */
12, /* lroti */
20, /* rrotr */
12, /* rroti */
8, /* extr */
4, /* exti */
36, /* extr_u */
4, /* exti_u */
72, /* depr */
24, /* depi */
44, /* qlshr */
8, /* qlshi */
40, /* qlshr_u */
8, /* qlshi_u */
40, /* qrshr */
8, /* qrshi */
40, /* qrshr_u */
8, /* qrshi_u */
36, /* unldr */
60, /* unldi */
36, /* unldr_u */
60, /* unldi_u */
120, /* unstr */
140, /* unsti */
40, /* unldr_x */
68, /* unldi_x */
52, /* unstr_x */
80, /* unsti_x */
16, /* fmar_f */
0, /* fmai_f */
16, /* fmsr_f */
0, /* fmsi_f */
16, /* fmar_d */
0, /* fmai_d */
16, /* fmsr_d */
0, /* fmsi_d */
20, /* fnmar_f */
0, /* fnmai_f */
20, /* fnmsr_f */
0, /* fnmsi_f */
20, /* fnmar_d */
0, /* fnmai_d */
20, /* fnmsr_d */
0, /* fnmsi_d */
#endif /* __WORDSIZE */
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,427 @@
/*
* Copyright (C) 2012-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#include <lightning.h>
#include <lightning/jit_private.h>
#if DISASSEMBLER
# include <dis-asm.h>
#endif
/*
* Prototypes
*/
#if DISASSEMBLER
static int
disasm_compare_symbols(const void *ap, const void *bp);
static void
disasm_print_address(bfd_vma addr, struct disassemble_info *info);
#define disassemble(u, v) _disassemble(_jit, u, v)
static void
_disassemble(jit_state_t *_jit, jit_pointer_t code, jit_int32_t length);
#endif
/*
* Initialization
*/
#if DISASSEMBLER
static bfd *disasm_bfd;
static disassemble_info disasm_info;
static disassembler_ftype disasm_print;
static asymbol **disasm_symbols;
static asymbol *disasm_synthetic;
static long disasm_num_symbols;
static long disasm_num_synthetic;
static jit_state_t *disasm_jit;
static FILE *disasm_stream;
#endif
#if BINUTILS_2_38
static int fprintf_styled(void * stream, enum disassembler_style style, const char* fmt, ...)
{
va_list args;
int r;
va_start(args, fmt);
r = vfprintf(disasm_stream, fmt, args);
va_end(args);
return r;
}
#endif
/*
* Implementation
*/
void
jit_init_debug(const char *progname)
{
jit_init_print();
#if DISASSEMBLER
bfd_init();
if (progname)
disasm_bfd = bfd_openr(progname, NULL);
if (disasm_bfd == NULL) {
#if defined(__linux__)
disasm_bfd = bfd_openr("/proc/self/exe", NULL);
if (disasm_bfd == NULL)
#endif
return;
}
bfd_check_format(disasm_bfd, bfd_object);
bfd_check_format(disasm_bfd, bfd_archive);
if (!disasm_stream)
disasm_stream = stderr;
#if BINUTILS_2_38
INIT_DISASSEMBLE_INFO(disasm_info, disasm_stream, fprintf, fprintf_styled);
#else
INIT_DISASSEMBLE_INFO(disasm_info, disasm_stream, fprintf);
#endif
disasm_info.arch = bfd_get_arch(disasm_bfd);
disasm_info.mach = bfd_get_mach(disasm_bfd);
# if HAVE_DISASSEMBLE_INIT_FOR_TARGET
disassemble_init_for_target(&disasm_info);
# endif
# if defined(__powerpc64__)
disasm_info.disassembler_options = "64";
# endif
# if defined(__sparc__) || defined(__s390__) || defined(__s390x__)
disasm_info.endian = disasm_info.display_endian = BFD_ENDIAN_BIG;
# endif
# if defined(__s390__) || defined(__s390x__)
disasm_info.disassembler_options = "zarch";
# endif
disasm_info.print_address_func = disasm_print_address;
# if BINUTILS_2_29
disasm_print = disassembler(disasm_info.arch, __BYTE_ORDER == __BIG_ENDIAN,
disasm_info.mach, disasm_bfd);
# else
disasm_print = disassembler(disasm_bfd);
# endif
assert(disasm_print);
if (bfd_get_file_flags(disasm_bfd) & HAS_SYMS) {
asymbol **in;
asymbol **out;
asymbol *symbol;
long offset;
long sym_count;
long dyn_count;
long sym_storage;
long dyn_storage;
if ((sym_storage = bfd_get_symtab_upper_bound(disasm_bfd)) >= 0) {
if (bfd_get_file_flags(disasm_bfd) & DYNAMIC) {
dyn_storage = bfd_get_dynamic_symtab_upper_bound(disasm_bfd);
# if defined(__alpha__)
/* XXX */
if (dyn_storage < 0)
dyn_storage = 0;
# else
assert(dyn_storage >= 0);
# endif
}
else
dyn_storage = 0;
jit_alloc((jit_pointer_t *)&disasm_symbols,
(sym_storage + dyn_storage) * sizeof(asymbol *));
sym_count = bfd_canonicalize_symtab(disasm_bfd, disasm_symbols);
assert(sym_count >= 0);
if (dyn_storage) {
dyn_count = bfd_canonicalize_dynamic_symtab(disasm_bfd,
disasm_symbols +
sym_count);
assert(dyn_count >= 0);
}
else
dyn_count = 0;
disasm_num_symbols = sym_count + dyn_count;
disasm_num_synthetic = bfd_get_synthetic_symtab(disasm_bfd,
sym_count,
disasm_symbols,
dyn_count,
disasm_symbols +
sym_count,
&disasm_synthetic);
if (disasm_num_synthetic > 0) {
jit_realloc((jit_pointer_t *)&disasm_symbols,
(sym_storage + dyn_storage) * sizeof(asymbol *),
(sym_storage + dyn_storage + disasm_num_synthetic) *
sizeof(asymbol *));
for (offset = 0; offset < disasm_num_synthetic; offset++)
disasm_symbols[disasm_num_symbols++] =
disasm_synthetic + offset;
}
/* remove symbols not useful for disassemble */
in = out = disasm_symbols;
for (offset = 0; offset < disasm_num_symbols; offset++) {
symbol = *in++;
if (symbol->name &&
symbol->name[0] != '\0' &&
!(symbol->flags & (BSF_DEBUGGING | BSF_SECTION_SYM)) &&
!bfd_is_und_section(symbol->section) &&
!bfd_is_com_section(symbol->section))
*out++ = symbol;
}
disasm_num_symbols = out - disasm_symbols;
qsort(disasm_symbols, disasm_num_symbols,
sizeof(asymbol *), disasm_compare_symbols);
}
}
#endif
}
void
jit_finish_debug(void)
{
#if DISASSEMBLER
if (disasm_synthetic)
jit_free((jit_pointer_t *)&disasm_synthetic);
if (disasm_symbols)
jit_free((jit_pointer_t *)&disasm_symbols);
if (disasm_bfd)
bfd_close (disasm_bfd);
#endif
}
void
_jit_disassemble(jit_state_t *_jit)
{
#if DISASSEMBLER
if (disasm_bfd) {
# if defined(__arm__)
/* FIXME add mapping for prolog switching to arm and possible jump
* before first prolog also in arm mode */
disasm_info.disassembler_options = jit_cpu.thumb ? "force-thumb" : "";
# endif
disassemble(_jit->code.ptr, _jit->pc.uc - _jit->code.ptr);
}
#endif
}
#if DISASSEMBLER
/* Based on objdump source */
static int
disasm_compare_symbols(const void *ap, const void *bp)
{
const asymbol *a = *(const asymbol **)ap;
const asymbol *b = *(const asymbol **)bp;
if (bfd_asymbol_value(a) > bfd_asymbol_value(b))
return (1);
if (bfd_asymbol_value(a) < bfd_asymbol_value(b))
return (-1);
return (0);
}
#if __WORDSIZE == 32
# define address_buffer_length 16
# define address_buffer_format "%llx"
#else
# define address_buffer_length 32
# define address_buffer_format "%lx"
#endif
static void
disasm_print_address(bfd_vma addr, struct disassemble_info *info)
{
char *name;
char *file;
int line;
char buffer[address_buffer_length];
sprintf(buffer, address_buffer_format, addr);
(*info->fprintf_func)(info->stream, "0x%s", buffer);
# define _jit disasm_jit
# undef jit_pointer_p
# define jit_pointer_p(u) \
((u) >= _jit->code.ptr && (u) < _jit->pc.uc)
if (jit_pointer_p((jit_uint8_t *)(jit_word_t)addr)) {
if (jit_get_note((jit_uint8_t *)(jit_word_t)addr, &name, &file, &line))
(*info->fprintf_func)(info->stream, " %s:%s:%d",
name ? name : "",
file ? file : "",
line);
}
# undef jit_pointer_p
# undef _jit
else if (disasm_num_symbols) {
long low;
long high;
long offset;
asymbol *symbol;
low = 0;
high = disasm_num_symbols;
do {
offset = (low + high) >> 1;
symbol = disasm_symbols[offset];
if (bfd_asymbol_value(symbol) > addr)
high = offset - 1;
else if (bfd_asymbol_value(symbol) < addr)
low = offset + 1;
else
break;
} while (low < high);
if (offset >= 0 && offset < disasm_num_symbols) {
if (bfd_asymbol_value(symbol) < addr) {
while (++offset < disasm_num_symbols) {
symbol = disasm_symbols[offset];
if (bfd_asymbol_value(symbol) >= addr)
break;
}
}
else if (bfd_asymbol_value(symbol) > addr) {
while (offset--) {
if (bfd_asymbol_value(disasm_symbols[offset]) < addr)
break;
symbol = disasm_symbols[offset];
}
}
if (bfd_asymbol_value(symbol) == addr)
(*info->fprintf_func)(info->stream, " # %s", symbol->name);
}
}
}
static void
_disassemble(jit_state_t *_jit, jit_pointer_t code, jit_int32_t length)
{
int bytes;
char *name, *old_name;
char *file, *old_file;
int line, old_line;
#if __riscv && __WORDSIZE == 64
jit_word_t *vector;
jit_int32_t offset;
#elif __arm__
jit_int32_t offset;
jit_bool_t data_info;
jit_int32_t data_offset;
#endif
bfd_vma pc = (jit_uword_t)code;
bfd_vma end = (jit_uword_t)code + length;
char buffer[address_buffer_length];
#if DEVEL_DISASSEMBLER
jit_node_t *node;
jit_uword_t prevw;
#endif
#if __riscv && __WORDSIZE == 64
end -= _jitc->consts.hash.count * 8;
#endif
#if __arm__
data_info = _jitc && _jitc->data_info.ptr;
data_offset = 0;
#endif
disasm_info.buffer = code;
disasm_info.buffer_vma = (jit_uword_t)code;
disasm_info.buffer_length = length;
old_file = old_name = NULL;
old_line = 0;
disasm_jit = _jit;
#if DEVEL_DISASSEMBLER
node = _jitc->head;
prevw = pc;
#endif
while (pc < end) {
#if DEVEL_DISASSEMBLER
while (node && (jit_uword_t)(prevw + node->offset) < (jit_uword_t)pc) {
prevw += node->offset;
node = node->next;
}
while (node && (jit_uword_t)(prevw + node->offset) == (jit_uword_t)pc) {
jit_print_node(node);
fputc('\n', disasm_stream);
prevw += node->offset;
node = node->next;
}
#endif
#if __arm__
again:
if (data_info) {
while (_jitc->data_info.ptr[data_offset].code < pc) {
if (++data_offset >= _jitc->data_info.length) {
data_info = 0;
goto again;
}
}
if (pc == _jitc->data_info.ptr[data_offset].code) {
offset = _jitc->data_info.ptr[data_offset].length;
for (; offset >= 4; offset -= 4, pc += 4) {
bytes = sprintf(buffer, address_buffer_format, pc);
(*disasm_info.fprintf_func)(disasm_stream,
"%*c0x%s\t.data\t0x%08x\n",
16 - bytes, ' ', buffer,
*(jit_uint32_t *)
(jit_uint32_t)pc);
}
/* reset disassemble information instead of attempting
* to hack the arm specific backend data structures to
* tell it to forward the required number of bytes. */
disasm_info.buffer = (jit_pointer_t)(jit_uint32_t)pc;
disasm_info.buffer_vma = (jit_uword_t)pc;
if ((disasm_info.buffer_length = end - pc) <= 0)
break;
}
}
#endif
if (jit_get_note((jit_uint8_t *)(jit_word_t)pc, &name, &file, &line) &&
(name != old_name || file != old_file || line != old_line)) {
(*disasm_info.fprintf_func)(disasm_stream, "# %s:%s:%d\n",
name ? name : "",
file ? file : "",
line);
old_name = name;
old_file = file;
old_line = line;
}
bytes = sprintf(buffer, address_buffer_format, pc);
(*disasm_info.fprintf_func)(disasm_stream, "%*c0x%s\t",
16 - bytes, ' ', buffer);
pc += (*disasm_print)(pc, &disasm_info);
putc('\n', disasm_stream);
}
#if __riscv && __WORDSIZE == 64
for (vector = (jit_word_t *)end, offset = 0;
offset < _jitc->consts.hash.count; offset++) {
bytes = sprintf(buffer, address_buffer_format,
(long long)end + offset * sizeof(jit_word_t));
(*disasm_info.fprintf_func)(disasm_stream,
"%*c0x%s\t.quad\t0x%016lx\t# (%ld)\n",
16 - bytes, ' ', buffer,
vector[offset], vector[offset]);
}
#endif
}
#endif
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,527 @@
#if __WORDSIZE == 32
#define JIT_INSTR_MAX 196
0, /* data */
0, /* live */
16, /* align */
0, /* save */
0, /* load */
4, /* skip */
0, /* #name */
0, /* #note */
0, /* label */
156, /* prolog */
0, /* ellipsis */
0, /* va_push */
0, /* allocai */
0, /* allocar */
0, /* arg_c */
0, /* arg_s */
0, /* arg_i */
0, /* arg_l */
0, /* getarg_c */
0, /* getarg_uc */
0, /* getarg_s */
0, /* getarg_us */
0, /* getarg_i */
0, /* getarg_ui */
0, /* getarg_l */
0, /* putargr_c */
0, /* putargi_c */
0, /* putargr_uc */
0, /* putargi_uc */
0, /* putargr_s */
0, /* putargi_s */
0, /* putargr_us */
0, /* putargi_us */
0, /* putargr_i */
0, /* putargi_i */
0, /* putargr_ui */
0, /* putargi_ui */
0, /* putargr_l */
0, /* putargi_l */
4, /* va_start */
8, /* va_arg */
20, /* va_arg_d */
0, /* va_end */
4, /* addr */
12, /* addi */
4, /* addcr */
12, /* addci */
4, /* addxr */
8, /* addxi */
4, /* subr */
12, /* subi */
4, /* subcr */
12, /* subci */
4, /* subxr */
8, /* subxi */
12, /* rsbi */
48, /* mulr */
56, /* muli */
40, /* qmulr */
44, /* qmuli */
52, /* qmulr_u */
60, /* qmuli_u */
36, /* divr */
40, /* divi */
36, /* divr_u */
40, /* divi_u */
40, /* qdivr */
40, /* qdivi */
40, /* qdivr_u */
40, /* qdivi_u */
36, /* remr */
40, /* remi */
36, /* remr_u */
40, /* remi_u */
4, /* andr */
12, /* andi */
4, /* orr */
12, /* ori */
4, /* xorr */
12, /* xori */
12, /* lshr */
4, /* lshi */
12, /* rshr */
4, /* rshi */
12, /* rshr_u */
4, /* rshi_u */
4, /* negr */
4, /* negi */
4, /* comr */
4, /* comi */
8, /* ltr */
8, /* lti */
8, /* ltr_u */
8, /* lti_u */
8, /* ler */
8, /* lei */
8, /* ler_u */
8, /* lei_u */
8, /* eqr */
12, /* eqi */
8, /* ger */
8, /* gei */
8, /* ger_u */
8, /* gei_u */
8, /* gtr */
8, /* gti */
8, /* gtr_u */
8, /* gti_u */
8, /* ner */
8, /* nei */
4, /* movr */
8, /* movi */
12, /* movnr */
12, /* movzr */
0, /* casr */
0, /* casi */
4, /* extr_c */
4, /* exti_c */
4, /* extr_uc */
4, /* exti_uc */
4, /* extr_s */
4, /* exti_s */
4, /* extr_us */
8, /* exti_us */
0, /* extr_i */
0, /* exti_i */
0, /* extr_ui */
0, /* exti_ui */
12, /* bswapr_us */
8, /* bswapi_us */
16, /* bswapr_ui */
8, /* bswapi_ui */
0, /* bswapr_ul */
0, /* bswapi_ul */
4, /* htonr_us */
8, /* htoni_us */
4, /* htonr_ui */
8, /* htoni_ui */
0, /* htonr_ul */
0, /* htoni_ul */
8, /* ldr_c */
12, /* ldi_c */
4, /* ldr_uc */
8, /* ldi_uc */
8, /* ldr_s */
12, /* ldi_s */
4, /* ldr_us */
8, /* ldi_us */
4, /* ldr_i */
8, /* ldi_i */
0, /* ldr_ui */
0, /* ldi_ui */
0, /* ldr_l */
0, /* ldi_l */
8, /* ldxr_c */
12, /* ldxi_c */
4, /* ldxr_uc */
8, /* ldxi_uc */
8, /* ldxr_s */
12, /* ldxi_s */
4, /* ldxr_us */
8, /* ldxi_us */
4, /* ldxr_i */
8, /* ldxi_i */
0, /* ldxr_ui */
0, /* ldxi_ui */
0, /* ldxr_l */
0, /* ldxi_l */
4, /* str_c */
8, /* sti_c */
4, /* str_s */
8, /* sti_s */
4, /* str_i */
8, /* sti_i */
0, /* str_l */
0, /* sti_l */
8, /* stxr_c */
12, /* stxi_c */
8, /* stxr_s */
12, /* stxi_s */
8, /* stxr_i */
12, /* stxi_i */
0, /* stxr_l */
0, /* stxi_l */
8, /* bltr */
12, /* blti */
8, /* bltr_u */
8, /* blti_u */
8, /* bler */
12, /* blei */
8, /* bler_u */
8, /* blei_u */
8, /* beqr */
16, /* beqi */
8, /* bger */
8, /* bgei */
8, /* bger_u */
8, /* bgei_u */
8, /* bgtr */
8, /* bgti */
8, /* bgtr_u */
8, /* bgti_u */
8, /* bner */
16, /* bnei */
12, /* bmsr */
16, /* bmsi */
12, /* bmcr */
16, /* bmci */
8, /* boaddr */
8, /* boaddi */
8, /* boaddr_u */
8, /* boaddi_u */
8, /* bxaddr */
8, /* bxaddi */
8, /* bxaddr_u */
8, /* bxaddi_u */
12, /* bosubr */
16, /* bosubi */
16, /* bosubr_u */
20, /* bosubi_u */
12, /* bxsubr */
16, /* bxsubi */
16, /* bxsubr_u */
20, /* bxsubi_u */
4, /* jmpr */
12, /* jmpi */
40, /* callr */
44, /* calli */
0, /* prepare */
0, /* pushargr_c */
0, /* pushargi_c */
0, /* pushargr_uc */
0, /* pushargi_uc */
0, /* pushargr_s */
0, /* pushargi_s */
0, /* pushargr_us */
0, /* pushargi_us */
0, /* pushargr_i */
0, /* pushargi_i */
0, /* pushargr_ui */
0, /* pushargi_ui */
0, /* pushargr_l */
0, /* pushargi_l */
0, /* finishr */
0, /* finishi */
0, /* ret */
0, /* retr_c */
0, /* reti_c */
0, /* retr_uc */
0, /* reti_uc */
0, /* retr_s */
0, /* reti_s */
0, /* retr_us */
0, /* reti_us */
0, /* retr_i */
0, /* reti_i */
0, /* retr_ui */
0, /* reti_ui */
0, /* retr_l */
0, /* reti_l */
0, /* retval_c */
0, /* retval_uc */
0, /* retval_s */
0, /* retval_us */
0, /* retval_i */
0, /* retval_ui */
0, /* retval_l */
196, /* epilog */
0, /* arg_f */
0, /* getarg_f */
0, /* putargr_f */
0, /* putargi_f */
4, /* addr_f */
24, /* addi_f */
4, /* subr_f */
24, /* subi_f */
24, /* rsbi_f */
4, /* mulr_f */
24, /* muli_f */
4, /* divr_f */
24, /* divi_f */
4, /* negr_f */
0, /* negi_f */
4, /* absr_f */
0, /* absi_f */
4, /* sqrtr_f */
0, /* sqrti_f */
16, /* ltr_f */
36, /* lti_f */
16, /* ler_f */
36, /* lei_f */
16, /* eqr_f */
36, /* eqi_f */
16, /* ger_f */
36, /* gei_f */
16, /* gtr_f */
36, /* gti_f */
16, /* ner_f */
36, /* nei_f */
16, /* unltr_f */
36, /* unlti_f */
16, /* unler_f */
36, /* unlei_f */
16, /* uneqr_f */
36, /* uneqi_f */
16, /* unger_f */
36, /* ungei_f */
16, /* ungtr_f */
36, /* ungti_f */
16, /* ltgtr_f */
36, /* ltgti_f */
16, /* ordr_f */
36, /* ordi_f */
16, /* unordr_f */
36, /* unordi_f */
16, /* truncr_f_i */
0, /* truncr_f_l */
20, /* extr_f */
4, /* extr_d_f */
4, /* movr_f */
20, /* movi_f */
4, /* ldr_f */
12, /* ldi_f */
8, /* ldxr_f */
12, /* ldxi_f */
4, /* str_f */
12, /* sti_f */
8, /* stxr_f */
12, /* stxi_f */
16, /* bltr_f */
36, /* blti_f */
16, /* bler_f */
36, /* blei_f */
16, /* beqr_f */
36, /* beqi_f */
16, /* bger_f */
36, /* bgei_f */
16, /* bgtr_f */
36, /* bgti_f */
16, /* bner_f */
36, /* bnei_f */
16, /* bunltr_f */
36, /* bunlti_f */
16, /* bunler_f */
36, /* bunlei_f */
16, /* buneqr_f */
36, /* buneqi_f */
16, /* bunger_f */
36, /* bungei_f */
16, /* bungtr_f */
36, /* bungti_f */
16, /* bltgtr_f */
36, /* bltgti_f */
16, /* bordr_f */
36, /* bordi_f */
16, /* bunordr_f */
36, /* bunordi_f */
0, /* pushargr_f */
0, /* pushargi_f */
0, /* retr_f */
0, /* reti_f */
0, /* retval_f */
0, /* arg_d */
0, /* getarg_d */
0, /* putargr_d */
0, /* putargi_d */
4, /* addr_d */
32, /* addi_d */
4, /* subr_d */
32, /* subi_d */
32, /* rsbi_d */
4, /* mulr_d */
32, /* muli_d */
4, /* divr_d */
32, /* divi_d */
4, /* negr_d */
0, /* negi_d */
4, /* absr_d */
0, /* absi_d */
4, /* sqrtr_d */
0, /* sqrti_d */
16, /* ltr_d */
44, /* lti_d */
16, /* ler_d */
44, /* lei_d */
16, /* eqr_d */
44, /* eqi_d */
16, /* ger_d */
44, /* gei_d */
16, /* gtr_d */
44, /* gti_d */
16, /* ner_d */
44, /* nei_d */
16, /* unltr_d */
44, /* unlti_d */
16, /* unler_d */
44, /* unlei_d */
16, /* uneqr_d */
44, /* uneqi_d */
16, /* unger_d */
44, /* ungei_d */
16, /* ungtr_d */
44, /* ungti_d */
16, /* ltgtr_d */
44, /* ltgti_d */
16, /* ordr_d */
44, /* ordi_d */
16, /* unordr_d */
44, /* unordi_d */
16, /* truncr_d_i */
0, /* truncr_d_l */
20, /* extr_d */
4, /* extr_f_d */
4, /* movr_d */
28, /* movi_d */
4, /* ldr_d */
12, /* ldi_d */
8, /* ldxr_d */
12, /* ldxi_d */
4, /* str_d */
12, /* sti_d */
8, /* stxr_d */
12, /* stxi_d */
16, /* bltr_d */
44, /* blti_d */
16, /* bler_d */
44, /* blei_d */
16, /* beqr_d */
44, /* beqi_d */
16, /* bger_d */
44, /* bgei_d */
16, /* bgtr_d */
44, /* bgti_d */
16, /* bner_d */
44, /* bnei_d */
16, /* bunltr_d */
44, /* bunlti_d */
16, /* bunler_d */
44, /* bunlei_d */
16, /* buneqr_d */
44, /* buneqi_d */
16, /* bunger_d */
44, /* bungei_d */
16, /* bungtr_d */
44, /* bungti_d */
16, /* bltgtr_d */
44, /* bltgti_d */
16, /* bordr_d */
44, /* bordi_d */
16, /* bunordr_d */
44, /* bunordi_d */
0, /* pushargr_d */
0, /* pushargi_d */
0, /* retr_d */
0, /* reti_d */
0, /* retval_d */
16, /* movr_w_f */
20, /* movi_w_f */
20, /* movr_ww_d */
28, /* movi_ww_d */
0, /* movr_w_d */
0, /* movi_w_d */
12, /* movr_f_w */
4, /* movi_f_w */
16, /* movr_d_ww */
8, /* movi_d_ww */
0, /* movr_d_w */
0, /* movi_d_w */
80, /* clor */
4, /* cloi */
60, /* clzr */
4, /* clzi */
76, /* ctor */
4, /* ctoi */
56, /* ctzr */
4, /* ctzi */
68, /* rbitr */
8, /* rbiti */
64, /* popcntr */
4, /* popcnti */
32, /* lrotr */
8, /* lroti */
32, /* rrotr */
8, /* rroti */
4, /* extr */
4, /* exti */
4, /* extr_u */
4, /* exti_u */
4, /* depr */
8, /* depi */
72, /* qlshr */
8, /* qlshi */
72, /* qlshr_u */
8, /* qlshi_u */
72, /* qrshr */
8, /* qrshi */
72, /* qrshr_u */
8, /* qrshi_u */
0, /* unldr */
0, /* unldi */
0, /* unldr_u */
0, /* unldi_u */
0, /* unstr */
0, /* unsti */
0, /* unldr_x */
0, /* unldi_x */
0, /* unstr_x */
0, /* unsti_x */
8, /* fmar_f */
0, /* fmai_f */
8, /* fmsr_f */
0, /* fmsi_f */
8, /* fmar_d */
0, /* fmai_d */
8, /* fmsr_d */
0, /* fmsi_d */
12, /* fnmar_f */
0, /* fnmai_f */
12, /* fnmsr_f */
0, /* fnmsi_f */
12, /* fnmar_d */
0, /* fnmai_d */
12, /* fnmsr_d */
0, /* fnmsi_d */
#endif /* __WORDSIZE */
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,527 @@
#if __WORDSIZE == 64
#define JIT_INSTR_MAX 144
0, /* data */
0, /* live */
32, /* align */
0, /* save */
0, /* load */
16, /* skip */
0, /* #name */
0, /* #note */
0, /* label */
80, /* prolog */
0, /* ellipsis */
0, /* va_push */
0, /* allocai */
0, /* allocar */
0, /* arg_c */
0, /* arg_s */
0, /* arg_i */
0, /* arg_l */
0, /* getarg_c */
0, /* getarg_uc */
0, /* getarg_s */
0, /* getarg_us */
0, /* getarg_i */
0, /* getarg_ui */
0, /* getarg_l */
0, /* putargr_c */
0, /* putargi_c */
0, /* putargr_uc */
0, /* putargi_uc */
0, /* putargr_s */
0, /* putargi_s */
0, /* putargr_us */
0, /* putargi_us */
0, /* putargr_i */
0, /* putargi_i */
0, /* putargr_ui */
0, /* putargi_ui */
0, /* putargr_l */
0, /* putargi_l */
16, /* va_start */
16, /* va_arg */
16, /* va_arg_d */
0, /* va_end */
16, /* addr */
16, /* addi */
16, /* addcr */
32, /* addci */
32, /* addxr */
32, /* addxi */
16, /* subr */
16, /* subi */
16, /* subcr */
32, /* subci */
32, /* subxr */
32, /* subxi */
16, /* rsbi */
32, /* mulr */
32, /* muli */
48, /* qmulr */
48, /* qmuli */
48, /* qmulr_u */
48, /* qmuli_u */
32, /* divr */
48, /* divi */
32, /* divr_u */
48, /* divi_u */
64, /* qdivr */
64, /* qdivi */
64, /* qdivr_u */
64, /* qdivi_u */
32, /* remr */
48, /* remi */
32, /* remr_u */
48, /* remi_u */
16, /* andr */
16, /* andi */
16, /* orr */
16, /* ori */
16, /* xorr */
16, /* xori */
16, /* lshr */
16, /* lshi */
16, /* rshr */
16, /* rshi */
16, /* rshr_u */
16, /* rshi_u */
16, /* negr */
16, /* negi */
16, /* comr */
16, /* comi */
16, /* ltr */
16, /* lti */
16, /* ltr_u */
16, /* lti_u */
16, /* ler */
16, /* lei */
16, /* ler_u */
16, /* lei_u */
16, /* eqr */
16, /* eqi */
16, /* ger */
16, /* gei */
16, /* ger_u */
16, /* gei_u */
16, /* gtr */
16, /* gti */
16, /* gtr_u */
16, /* gti_u */
16, /* ner */
16, /* nei */
16, /* movr */
16, /* movi */
16, /* movnr */
16, /* movzr */
32, /* casr */
32, /* casi */
16, /* extr_c */
16, /* exti_c */
16, /* extr_uc */
16, /* exti_uc */
16, /* extr_s */
16, /* exti_s */
16, /* extr_us */
16, /* exti_us */
16, /* extr_i */
16, /* exti_i */
16, /* extr_ui */
16, /* exti_ui */
16, /* bswapr_us */
16, /* bswapi_us */
16, /* bswapr_ui */
16, /* bswapi_ui */
16, /* bswapr_ul */
16, /* bswapi_ul */
16, /* htonr_us */
16, /* htoni_us */
16, /* htonr_ui */
16, /* htoni_ui */
16, /* htonr_ul */
16, /* htoni_ul */
16, /* ldr_c */
16, /* ldi_c */
16, /* ldr_uc */
16, /* ldi_uc */
16, /* ldr_s */
16, /* ldi_s */
16, /* ldr_us */
16, /* ldi_us */
16, /* ldr_i */
16, /* ldi_i */
16, /* ldr_ui */
16, /* ldi_ui */
16, /* ldr_l */
16, /* ldi_l */
16, /* ldxr_c */
32, /* ldxi_c */
16, /* ldxr_uc */
16, /* ldxi_uc */
16, /* ldxr_s */
32, /* ldxi_s */
16, /* ldxr_us */
16, /* ldxi_us */
16, /* ldxr_i */
32, /* ldxi_i */
16, /* ldxr_ui */
16, /* ldxi_ui */
16, /* ldxr_l */
16, /* ldxi_l */
16, /* str_c */
16, /* sti_c */
16, /* str_s */
16, /* sti_s */
16, /* str_i */
16, /* sti_i */
16, /* str_l */
16, /* sti_l */
16, /* stxr_c */
16, /* stxi_c */
16, /* stxr_s */
16, /* stxi_s */
16, /* stxr_i */
16, /* stxi_i */
16, /* stxr_l */
16, /* stxi_l */
16, /* bltr */
16, /* blti */
16, /* bltr_u */
16, /* blti_u */
16, /* bler */
16, /* blei */
16, /* bler_u */
16, /* blei_u */
16, /* beqr */
32, /* beqi */
16, /* bger */
16, /* bgei */
16, /* bger_u */
16, /* bgei_u */
16, /* bgtr */
16, /* bgti */
16, /* bgtr_u */
16, /* bgti_u */
16, /* bner */
32, /* bnei */
16, /* bmsr */
32, /* bmsi */
16, /* bmcr */
32, /* bmci */
48, /* boaddr */
48, /* boaddi */
32, /* boaddr_u */
32, /* boaddi_u */
48, /* bxaddr */
48, /* bxaddi */
32, /* bxaddr_u */
32, /* bxaddi_u */
48, /* bosubr */
48, /* bosubi */
32, /* bosubr_u */
32, /* bosubi_u */
48, /* bxsubr */
48, /* bxsubi */
32, /* bxsubr_u */
32, /* bxsubi_u */
16, /* jmpr */
16, /* jmpi */
16, /* callr */
32, /* calli */
0, /* prepare */
0, /* pushargr_c */
0, /* pushargi_c */
0, /* pushargr_uc */
0, /* pushargi_uc */
0, /* pushargr_s */
0, /* pushargi_s */
0, /* pushargr_us */
0, /* pushargi_us */
0, /* pushargr_i */
0, /* pushargi_i */
0, /* pushargr_ui */
0, /* pushargi_ui */
0, /* pushargr_l */
0, /* pushargi_l */
0, /* finishr */
0, /* finishi */
0, /* ret */
0, /* retr_c */
0, /* reti_c */
0, /* retr_uc */
0, /* reti_uc */
0, /* retr_s */
0, /* reti_s */
0, /* retr_us */
0, /* reti_us */
0, /* retr_i */
0, /* reti_i */
0, /* retr_ui */
0, /* reti_ui */
0, /* retr_l */
0, /* reti_l */
0, /* retval_c */
0, /* retval_uc */
0, /* retval_s */
0, /* retval_us */
0, /* retval_i */
0, /* retval_ui */
0, /* retval_l */
48, /* epilog */
0, /* arg_f */
0, /* getarg_f */
0, /* putargr_f */
0, /* putargi_f */
16, /* addr_f */
32, /* addi_f */
16, /* subr_f */
32, /* subi_f */
32, /* rsbi_f */
16, /* mulr_f */
32, /* muli_f */
64, /* divr_f */
80, /* divi_f */
16, /* negr_f */
0, /* negi_f */
16, /* absr_f */
0, /* absi_f */
32, /* sqrtr_f */
0, /* sqrti_f */
16, /* ltr_f */
32, /* lti_f */
16, /* ler_f */
32, /* lei_f */
16, /* eqr_f */
32, /* eqi_f */
16, /* ger_f */
32, /* gei_f */
16, /* gtr_f */
32, /* gti_f */
16, /* ner_f */
32, /* nei_f */
16, /* unltr_f */
32, /* unlti_f */
16, /* unler_f */
32, /* unlei_f */
32, /* uneqr_f */
48, /* uneqi_f */
16, /* unger_f */
32, /* ungei_f */
16, /* ungtr_f */
32, /* ungti_f */
32, /* ltgtr_f */
48, /* ltgti_f */
16, /* ordr_f */
32, /* ordi_f */
16, /* unordr_f */
32, /* unordi_f */
16, /* truncr_f_i */
16, /* truncr_f_l */
32, /* extr_f */
16, /* extr_d_f */
16, /* movr_f */
16, /* movi_f */
16, /* ldr_f */
16, /* ldi_f */
16, /* ldxr_f */
16, /* ldxi_f */
16, /* str_f */
16, /* sti_f */
16, /* stxr_f */
16, /* stxi_f */
16, /* bltr_f */
32, /* blti_f */
16, /* bler_f */
32, /* blei_f */
16, /* beqr_f */
32, /* beqi_f */
16, /* bger_f */
32, /* bgei_f */
16, /* bgtr_f */
32, /* bgti_f */
16, /* bner_f */
32, /* bnei_f */
16, /* bunltr_f */
32, /* bunlti_f */
16, /* bunler_f */
32, /* bunlei_f */
32, /* buneqr_f */
48, /* buneqi_f */
16, /* bunger_f */
32, /* bungei_f */
16, /* bungtr_f */
32, /* bungti_f */
32, /* bltgtr_f */
48, /* bltgti_f */
16, /* bordr_f */
32, /* bordi_f */
16, /* bunordr_f */
32, /* bunordi_f */
0, /* pushargr_f */
0, /* pushargi_f */
0, /* retr_f */
0, /* reti_f */
0, /* retval_f */
0, /* arg_d */
0, /* getarg_d */
0, /* putargr_d */
0, /* putargi_d */
16, /* addr_d */
32, /* addi_d */
16, /* subr_d */
32, /* subi_d */
32, /* rsbi_d */
16, /* mulr_d */
32, /* muli_d */
64, /* divr_d */
80, /* divi_d */
16, /* negr_d */
0, /* negi_d */
16, /* absr_d */
0, /* absi_d */
32, /* sqrtr_d */
0, /* sqrti_d */
16, /* ltr_d */
32, /* lti_d */
16, /* ler_d */
32, /* lei_d */
16, /* eqr_d */
32, /* eqi_d */
16, /* ger_d */
32, /* gei_d */
16, /* gtr_d */
32, /* gti_d */
16, /* ner_d */
32, /* nei_d */
16, /* unltr_d */
32, /* unlti_d */
16, /* unler_d */
32, /* unlei_d */
32, /* uneqr_d */
48, /* uneqi_d */
16, /* unger_d */
32, /* ungei_d */
16, /* ungtr_d */
32, /* ungti_d */
32, /* ltgtr_d */
48, /* ltgti_d */
16, /* ordr_d */
32, /* ordi_d */
16, /* unordr_d */
32, /* unordi_d */
16, /* truncr_d_i */
16, /* truncr_d_l */
32, /* extr_d */
16, /* extr_f_d */
16, /* movr_d */
16, /* movi_d */
16, /* ldr_d */
16, /* ldi_d */
16, /* ldxr_d */
16, /* ldxi_d */
16, /* str_d */
16, /* sti_d */
16, /* stxr_d */
16, /* stxi_d */
16, /* bltr_d */
32, /* blti_d */
16, /* bler_d */
32, /* blei_d */
16, /* beqr_d */
32, /* beqi_d */
16, /* bger_d */
32, /* bgei_d */
16, /* bgtr_d */
32, /* bgti_d */
16, /* bner_d */
32, /* bnei_d */
16, /* bunltr_d */
32, /* bunlti_d */
16, /* bunler_d */
32, /* bunlei_d */
32, /* buneqr_d */
48, /* buneqi_d */
16, /* bunger_d */
32, /* bungei_d */
16, /* bungtr_d */
32, /* bungti_d */
32, /* bltgtr_d */
48, /* bltgti_d */
16, /* bordr_d */
32, /* bordi_d */
16, /* bunordr_d */
32, /* bunordi_d */
0, /* pushargr_d */
0, /* pushargi_d */
0, /* retr_d */
0, /* reti_d */
0, /* retval_d */
16, /* movr_w_f */
16, /* movi_w_f */
0, /* movr_ww_d */
0, /* movi_ww_d */
16, /* movr_w_d */
16, /* movi_w_d */
16, /* movr_f_w */
16, /* movi_f_w */
0, /* movr_d_ww */
0, /* movi_d_ww */
16, /* movr_d_w */
16, /* movi_d_w */
96, /* clor */
16, /* cloi */
64, /* clzr */
16, /* clzi */
64, /* ctor */
16, /* ctoi */
48, /* ctzr */
16, /* ctzi */
64, /* rbitr */
16, /* rbiti */
16, /* popcntr */
16, /* popcnti */
32, /* lrotr */
32, /* lroti */
32, /* rrotr */
32, /* rroti */
16, /* extr */
16, /* exti */
16, /* extr_u */
16, /* exti_u */
32, /* depr */
16, /* depi */
48, /* qlshr */
16, /* qlshi */
48, /* qlshr_u */
16, /* qlshi_u */
48, /* qrshr */
16, /* qrshi */
48, /* qrshr_u */
16, /* qrshi_u */
96, /* unldr */
48, /* unldi */
96, /* unldr_u */
48, /* unldi_u */
128, /* unstr */
96, /* unsti */
80, /* unldr_x */
48, /* unldi_x */
144, /* unstr_x */
112, /* unsti_x */
16, /* fmar_f */
0, /* fmai_f */
16, /* fmsr_f */
0, /* fmsi_f */
16, /* fmar_d */
0, /* fmai_d */
16, /* fmsr_d */
0, /* fmsi_d */
16, /* fnmar_f */
0, /* fnmai_f */
16, /* fnmsr_f */
0, /* fnmsi_f */
16, /* fnmar_d */
0, /* fnmai_d */
16, /* fnmsr_d */
0, /* fnmsi_d */
#endif /* __WORDSIZE */
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,527 @@
#if __WORDSIZE == 64
#define JIT_INSTR_MAX 88
0, /* data */
0, /* live */
12, /* align */
0, /* save */
0, /* load */
4, /* skip */
0, /* #name */
0, /* #note */
0, /* label */
88, /* prolog */
0, /* ellipsis */
0, /* va_push */
0, /* allocai */
0, /* allocar */
0, /* arg_c */
0, /* arg_s */
0, /* arg_i */
0, /* arg_l */
0, /* getarg_c */
0, /* getarg_uc */
0, /* getarg_s */
0, /* getarg_us */
0, /* getarg_i */
0, /* getarg_ui */
0, /* getarg_l */
0, /* putargr_c */
0, /* putargi_c */
0, /* putargr_uc */
0, /* putargi_uc */
0, /* putargr_s */
0, /* putargi_s */
0, /* putargr_us */
0, /* putargi_us */
0, /* putargr_i */
0, /* putargi_i */
0, /* putargr_ui */
0, /* putargi_ui */
0, /* putargr_l */
0, /* putargi_l */
4, /* va_start */
8, /* va_arg */
8, /* va_arg_d */
0, /* va_end */
4, /* addr */
20, /* addi */
12, /* addcr */
28, /* addci */
28, /* addxr */
28, /* addxi */
4, /* subr */
20, /* subi */
12, /* subcr */
28, /* subci */
28, /* subxr */
28, /* subxi */
24, /* rsbi */
4, /* mulr */
20, /* muli */
12, /* qmulr */
24, /* qmuli */
12, /* qmulr_u */
24, /* qmuli_u */
4, /* divr */
20, /* divi */
4, /* divr_u */
20, /* divi_u */
12, /* qdivr */
12, /* qdivi */
12, /* qdivr_u */
12, /* qdivi_u */
4, /* remr */
20, /* remi */
4, /* remr_u */
20, /* remi_u */
4, /* andr */
20, /* andi */
4, /* orr */
20, /* ori */
4, /* xorr */
20, /* xori */
4, /* lshr */
4, /* lshi */
4, /* rshr */
4, /* rshi */
4, /* rshr_u */
4, /* rshi_u */
4, /* negr */
4, /* negi */
4, /* comr */
4, /* comi */
4, /* ltr */
4, /* lti */
4, /* ltr_u */
4, /* lti_u */
8, /* ler */
4, /* lei */
8, /* ler_u */
4, /* lei_u */
12, /* eqr */
12, /* eqi */
8, /* ger */
8, /* gei */
8, /* ger_u */
8, /* gei_u */
4, /* gtr */
8, /* gti */
4, /* gtr_u */
8, /* gti_u */
8, /* ner */
8, /* nei */
4, /* movr */
16, /* movi */
12, /* movnr */
12, /* movzr */
32, /* casr */
44, /* casi */
4, /* extr_c */
4, /* exti_c */
4, /* extr_uc */
4, /* exti_uc */
4, /* extr_s */
4, /* exti_s */
4, /* extr_us */
8, /* exti_us */
4, /* extr_i */
4, /* exti_i */
4, /* extr_ui */
12, /* exti_ui */
8, /* bswapr_us */
8, /* bswapi_us */
8, /* bswapr_ui */
8, /* bswapi_ui */
4, /* bswapr_ul */
16, /* bswapi_ul */
8, /* htonr_us */
8, /* htoni_us */
8, /* htonr_ui */
8, /* htoni_ui */
4, /* htonr_ul */
16, /* htoni_ul */
4, /* ldr_c */
20, /* ldi_c */
4, /* ldr_uc */
20, /* ldi_uc */
4, /* ldr_s */
20, /* ldi_s */
4, /* ldr_us */
20, /* ldi_us */
4, /* ldr_i */
20, /* ldi_i */
4, /* ldr_ui */
20, /* ldi_ui */
4, /* ldr_l */
20, /* ldi_l */
4, /* ldxr_c */
16, /* ldxi_c */
4, /* ldxr_uc */
16, /* ldxi_uc */
4, /* ldxr_s */
16, /* ldxi_s */
4, /* ldxr_us */
16, /* ldxi_us */
4, /* ldxr_i */
16, /* ldxi_i */
4, /* ldxr_ui */
16, /* ldxi_ui */
4, /* ldxr_l */
16, /* ldxi_l */
4, /* str_c */
20, /* sti_c */
4, /* str_s */
20, /* sti_s */
4, /* str_i */
20, /* sti_i */
4, /* str_l */
20, /* sti_l */
4, /* stxr_c */
16, /* stxi_c */
4, /* stxr_s */
16, /* stxi_s */
4, /* stxr_i */
16, /* stxi_i */
4, /* stxr_l */
16, /* stxi_l */
4, /* bltr */
8, /* blti */
4, /* bltr_u */
8, /* blti_u */
8, /* bler */
12, /* blei */
8, /* bler_u */
12, /* blei_u */
4, /* beqr */
20, /* beqi */
4, /* bger */
8, /* bgei */
4, /* bger_u */
8, /* bgei_u */
8, /* bgtr */
12, /* bgti */
8, /* bgtr_u */
12, /* bgti_u */
4, /* bner */
20, /* bnei */
8, /* bmsr */
8, /* bmsi */
8, /* bmcr */
8, /* bmci */
32, /* boaddr */
36, /* boaddi */
16, /* boaddr_u */
20, /* boaddi_u */
32, /* bxaddr */
36, /* bxaddi */
16, /* bxaddr_u */
20, /* bxaddi_u */
32, /* bosubr */
36, /* bosubi */
16, /* bosubr_u */
20, /* bosubi_u */
32, /* bxsubr */
36, /* bxsubi */
16, /* bxsubr_u */
20, /* bxsubi_u */
4, /* jmpr */
20, /* jmpi */
4, /* callr */
20, /* calli */
0, /* prepare */
0, /* pushargr_c */
0, /* pushargi_c */
0, /* pushargr_uc */
0, /* pushargi_uc */
0, /* pushargr_s */
0, /* pushargi_s */
0, /* pushargr_us */
0, /* pushargi_us */
0, /* pushargr_i */
0, /* pushargi_i */
0, /* pushargr_ui */
0, /* pushargi_ui */
0, /* pushargr_l */
0, /* pushargi_l */
0, /* finishr */
0, /* finishi */
0, /* ret */
0, /* retr_c */
0, /* reti_c */
0, /* retr_uc */
0, /* reti_uc */
0, /* retr_s */
0, /* reti_s */
0, /* retr_us */
0, /* reti_us */
0, /* retr_i */
0, /* reti_i */
0, /* retr_ui */
0, /* reti_ui */
0, /* retr_l */
0, /* reti_l */
0, /* retval_c */
0, /* retval_uc */
0, /* retval_s */
0, /* retval_us */
0, /* retval_i */
0, /* retval_ui */
0, /* retval_l */
88, /* epilog */
0, /* arg_f */
0, /* getarg_f */
0, /* putargr_f */
0, /* putargi_f */
4, /* addr_f */
12, /* addi_f */
4, /* subr_f */
12, /* subi_f */
12, /* rsbi_f */
4, /* mulr_f */
12, /* muli_f */
4, /* divr_f */
12, /* divi_f */
4, /* negr_f */
0, /* negi_f */
4, /* absr_f */
0, /* absi_f */
4, /* sqrtr_f */
0, /* sqrti_f */
8, /* ltr_f */
16, /* lti_f */
8, /* ler_f */
16, /* lei_f */
8, /* eqr_f */
16, /* eqi_f */
8, /* ger_f */
16, /* gei_f */
8, /* gtr_f */
16, /* gti_f */
8, /* ner_f */
16, /* nei_f */
8, /* unltr_f */
16, /* unlti_f */
8, /* unler_f */
16, /* unlei_f */
8, /* uneqr_f */
16, /* uneqi_f */
8, /* unger_f */
16, /* ungei_f */
8, /* ungtr_f */
16, /* ungti_f */
8, /* ltgtr_f */
16, /* ltgti_f */
8, /* ordr_f */
16, /* ordi_f */
12, /* unordr_f */
20, /* unordi_f */
8, /* truncr_f_i */
8, /* truncr_f_l */
8, /* extr_f */
4, /* extr_d_f */
4, /* movr_f */
8, /* movi_f */
4, /* ldr_f */
20, /* ldi_f */
4, /* ldxr_f */
16, /* ldxi_f */
4, /* str_f */
20, /* sti_f */
4, /* stxr_f */
16, /* stxi_f */
8, /* bltr_f */
16, /* blti_f */
8, /* bler_f */
16, /* blei_f */
8, /* beqr_f */
16, /* beqi_f */
8, /* bger_f */
16, /* bgei_f */
8, /* bgtr_f */
16, /* bgti_f */
8, /* bner_f */
16, /* bnei_f */
8, /* bunltr_f */
16, /* bunlti_f */
8, /* bunler_f */
16, /* bunlei_f */
8, /* buneqr_f */
16, /* buneqi_f */
8, /* bunger_f */
16, /* bungei_f */
8, /* bungtr_f */
16, /* bungti_f */
8, /* bltgtr_f */
16, /* bltgti_f */
8, /* bordr_f */
16, /* bordi_f */
8, /* bunordr_f */
16, /* bunordi_f */
0, /* pushargr_f */
0, /* pushargi_f */
0, /* retr_f */
0, /* reti_f */
0, /* retval_f */
0, /* arg_d */
0, /* getarg_d */
0, /* putargr_d */
0, /* putargi_d */
4, /* addr_d */
20, /* addi_d */
4, /* subr_d */
20, /* subi_d */
16, /* rsbi_d */
4, /* mulr_d */
20, /* muli_d */
4, /* divr_d */
20, /* divi_d */
4, /* negr_d */
0, /* negi_d */
4, /* absr_d */
0, /* absi_d */
4, /* sqrtr_d */
0, /* sqrti_d */
8, /* ltr_d */
24, /* lti_d */
8, /* ler_d */
24, /* lei_d */
8, /* eqr_d */
24, /* eqi_d */
8, /* ger_d */
24, /* gei_d */
8, /* gtr_d */
24, /* gti_d */
8, /* ner_d */
24, /* nei_d */
8, /* unltr_d */
24, /* unlti_d */
8, /* unler_d */
24, /* unlei_d */
8, /* uneqr_d */
24, /* uneqi_d */
8, /* unger_d */
24, /* ungei_d */
8, /* ungtr_d */
24, /* ungti_d */
8, /* ltgtr_d */
24, /* ltgti_d */
8, /* ordr_d */
24, /* ordi_d */
12, /* unordr_d */
28, /* unordi_d */
8, /* truncr_d_i */
8, /* truncr_d_l */
8, /* extr_d */
4, /* extr_f_d */
4, /* movr_d */
16, /* movi_d */
4, /* ldr_d */
20, /* ldi_d */
4, /* ldxr_d */
16, /* ldxi_d */
4, /* str_d */
20, /* sti_d */
4, /* stxr_d */
16, /* stxi_d */
8, /* bltr_d */
20, /* blti_d */
8, /* bler_d */
20, /* blei_d */
8, /* beqr_d */
24, /* beqi_d */
8, /* bger_d */
24, /* bgei_d */
8, /* bgtr_d */
24, /* bgti_d */
8, /* bner_d */
24, /* bnei_d */
8, /* bunltr_d */
24, /* bunlti_d */
8, /* bunler_d */
24, /* bunlei_d */
8, /* buneqr_d */
24, /* buneqi_d */
8, /* bunger_d */
24, /* bungei_d */
8, /* bungtr_d */
24, /* bungti_d */
8, /* bltgtr_d */
24, /* bltgti_d */
8, /* bordr_d */
20, /* bordi_d */
8, /* bunordr_d */
24, /* bunordi_d */
0, /* pushargr_d */
0, /* pushargi_d */
0, /* retr_d */
0, /* reti_d */
0, /* retval_d */
4, /* movr_w_f */
8, /* movi_w_f */
0, /* movr_ww_d */
0, /* movi_ww_d */
4, /* movr_w_d */
12, /* movi_w_d */
4, /* movr_f_w */
4, /* movi_f_w */
0, /* movr_d_ww */
0, /* movi_d_ww */
4, /* movr_d_w */
12, /* movi_d_w */
4, /* clor */
4, /* cloi */
4, /* clzr */
4, /* clzi */
4, /* ctor */
4, /* ctoi */
4, /* ctzr */
4, /* ctzi */
4, /* rbitr */
16, /* rbiti */
52, /* popcntr */
4, /* popcnti */
12, /* lrotr */
4, /* lroti */
4, /* rrotr */
4, /* rroti */
8, /* extr */
4, /* exti */
4, /* extr_u */
4, /* exti_u */
4, /* depr */
8, /* depi */
84, /* qlshr */
8, /* qlshi */
84, /* qlshr_u */
8, /* qlshi_u */
84, /* qrshr */
8, /* qrshi */
84, /* qrshr_u */
8, /* qrshi_u */
24, /* unldr */
52, /* unldi */
24, /* unldr_u */
52, /* unldi_u */
20, /* unstr */
68, /* unsti */
4, /* unldr_x */
20, /* unldi_x */
4, /* unstr_x */
24, /* unsti_x */
4, /* fmar_f */
0, /* fmai_f */
4, /* fmsr_f */
0, /* fmsi_f */
4, /* fmar_d */
0, /* fmai_d */
4, /* fmsr_d */
0, /* fmsi_d */
4, /* fnmar_f */
0, /* fnmai_f */
4, /* fnmsr_f */
0, /* fnmsi_f */
4, /* fnmar_d */
0, /* fnmai_d */
4, /* fnmsr_d */
0, /* fnmsi_d */
#endif /* __WORDSIZE */
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,122 @@
/*
* Copyright (C) 2013-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#include <lightning.h>
#include <lightning/jit_private.h>
/*
* Prototypes
*/
static void *jit_default_alloc_func(size_t);
static void *jit_default_realloc_func(void*, size_t);
static void jit_default_free_func(void *);
/*
* Initialization
*/
static jit_alloc_func_ptr jit_alloc_ptr = jit_default_alloc_func;
static jit_realloc_func_ptr jit_realloc_ptr = jit_default_realloc_func;
static jit_free_func_ptr jit_free_ptr = jit_default_free_func;
/*
* Implementation
*/
jit_pointer_t
jit_memcpy(jit_pointer_t dst, const void * src, jit_word_t size)
{
if (size)
return (memcpy(dst, src, size));
return (dst);
}
jit_pointer_t
jit_memmove(jit_pointer_t dst, const void *src , jit_word_t size)
{
if (size)
return (memmove(dst, src, size));
return (dst);
}
void
jit_set_memory_functions(jit_alloc_func_ptr alloc_ptr,
jit_realloc_func_ptr realloc_ptr,
jit_free_func_ptr free_ptr)
{
if (alloc_ptr == NULL)
alloc_ptr = jit_default_alloc_func;
if (realloc_ptr == NULL)
realloc_ptr = jit_default_realloc_func;
if (free_ptr == NULL)
free_ptr = jit_default_free_func;
jit_alloc_ptr = alloc_ptr;
jit_realloc_ptr = realloc_ptr;
jit_free_ptr = free_ptr;
}
void
jit_get_memory_functions(jit_alloc_func_ptr *alloc_ptr,
jit_realloc_func_ptr *realloc_ptr,
jit_free_func_ptr *free_ptr)
{
*alloc_ptr = jit_alloc_ptr;
*realloc_ptr = jit_realloc_ptr;
*free_ptr = jit_free_ptr;
}
void
jit_alloc(jit_pointer_t *ptr, jit_word_t size)
{
*ptr = (*jit_alloc_ptr)(size);
memset(*ptr, 0, size);
}
void
jit_realloc(jit_pointer_t *ptr, jit_word_t old_size, jit_word_t new_size)
{
*ptr = (*jit_realloc_ptr)(*ptr, new_size);
if (old_size < new_size)
memset((jit_int8_t*)*ptr + old_size, 0, new_size - old_size);
}
void
jit_free(jit_pointer_t *ptr)
{
if (*ptr) {
(*jit_free_ptr)(*ptr);
*ptr = NULL;
}
}
static void *
jit_default_alloc_func(size_t size)
{
return (malloc(size));
}
static void *
jit_default_realloc_func(void *ptr, size_t size)
{
return (realloc(ptr, size));
}
static void
jit_default_free_func(void *ptr)
{
free(ptr);
}
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,292 @@
/*
* Copyright (C) 2014-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
static char *code_name[] = {
"data",
"live", "align",
"save", "load",
"skip",
"#name", "#note",
"label",
"prolog",
"ellipsis", "va_push",
"allocai", "allocar",
"arg_c", "arg_s",
"arg_i", "arg_l",
"getarg_c", "getarg_uc",
"getarg_s", "getarg_us",
"getarg_i", "getarg_ui",
"getarg_l",
"putargr_c", "putargi_c",
"putargr_uc", "putargi_uc",
"putargr_s", "putargi_s",
"putargr_us", "putargi_us",
"putargr_i", "putargi_i",
"putargr_ui", "putargi_ui",
"putargr_l", "putargi_l",
"va_start",
"va_arg", "va_arg_d",
"va_end",
"addr", "addi",
"addcr", "addci",
"addxr", "addxi",
"subr", "subi",
"subcr", "subci",
"subxr", "subxi",
"rsbi",
"mulr", "muli",
"qmulr", "qmuli",
"qmulr_u", "qmuli_u",
"divr", "divi",
"divr_u", "divi_u",
"qdivr", "qdivi",
"qdivr_u", "qdivi_u",
"remr", "remi",
"remr_u", "remi_u",
"andr", "andi",
"orr", "ori",
"xorr", "xori",
"lshr", "lshi",
"rshr", "rshi",
"rshr_u", "rshi_u",
"negr", "negi",
"comr", "comi",
"ltr", "lti",
"ltr_u", "lti_u",
"ler", "lei",
"ler_u", "lei_u",
"eqr", "eqi",
"ger", "gei",
"ger_u", "gei_u",
"gtr", "gti",
"gtr_u", "gti_u",
"ner", "nei",
"movr", "movi",
"movnr", "movzr",
"casr", "casi",
"extr_c", "exti_c",
"extr_uc", "exti_uc",
"extr_s", "exti_s",
"extr_us", "exti_us",
"extr_i", "exti_i",
"extr_ui", "exti_ui",
"bswapr_us", "bswapi_us",
"bswapr_ui", "bswapi_ui",
"bswapr_ul", "bswapi_ul",
"htonr_us", "htoni_us",
"htonr_ui", "htoni_ui",
"htonr_ul", "htoni_ul",
"ldr_c", "ldi_c",
"ldr_uc", "ldi_uc",
"ldr_s", "ldi_s",
"ldr_us", "ldi_us",
"ldr_i", "ldi_i",
"ldr_ui", "ldi_ui",
"ldr_l", "ldi_l",
"ldxr_c", "ldxi_c",
"ldxr_uc", "ldxi_uc",
"ldxr_s", "ldxi_s",
"ldxr_us", "ldxi_us",
"ldxr_i", "ldxi_i",
"ldxr_ui", "ldxi_ui",
"ldxr_l", "ldxi_l",
"str_c", "sti_c",
"str_s", "sti_s",
"str_i", "sti_i",
"str_l", "sti_l",
"stxr_c", "stxi_c",
"stxr_s", "stxi_s",
"stxr_i", "stxi_i",
"stxr_l", "stxi_l",
"bltr", "blti",
"bltr_u", "blti_u",
"bler", "blei",
"bler_u", "blei_u",
"beqr", "beqi",
"bger", "bgei",
"bger_u", "bgei_u",
"bgtr", "bgti",
"bgtr_u", "bgti_u",
"bner", "bnei",
"bmsr", "bmsi",
"bmcr", "bmci",
"boaddr", "boaddi",
"boaddr_u", "boaddi_u",
"bxaddr", "bxaddi",
"bxaddr_u", "bxaddi_u",
"bosubr", "bosubi",
"bosubr_u", "bosubi_u",
"bxsubr", "bxsubi",
"bxsubr_u", "bxsubi_u",
"jmpr", "jmpi",
"callr", "calli",
"prepare",
"pushargr_c", "pushargi_c",
"pushargr_uc", "pushargi_uc",
"pushargr_s", "pushargi_s",
"pushargr_us", "pushargi_us",
"pushargr_i", "pushargi_i",
"pushargr_ui", "pushargi_ui",
"pushargr_l", "pushargi_l",
"finishr", "finishi",
"ret",
"retr_c", "reti_c",
"retr_uc", "reti_uc",
"retr_s", "reti_s",
"retr_us", "reti_us",
"retr_i", "reti_i",
"retr_ui", "reti_ui",
"retr_l", "reti_l",
"retval_c", "retval_uc",
"retval_s", "retval_us",
"retval_i", "retval_ui",
"retval_l",
"epilog",
"arg_f", "getarg_f",
"putargr_f", "putargi_f",
"addr_f", "addi_f",
"subr_f", "subi_f",
"rsbi_f",
"mulr_f", "muli_f",
"divr_f", "divi_f",
"negr_f", "negi_f",
"absr_f", "absi_f",
"sqrtr_f", "sqrti_f",
"ltr_f", "lti_f",
"ler_f", "lei_f",
"eqr_f", "eqi_f",
"ger_f", "gei_f",
"gtr_f", "gti_f",
"ner_f", "nei_f",
"unltr_f", "unlti_f",
"unler_f", "unlei_f",
"uneqr_f", "uneqi_f",
"unger_f", "ungei_f",
"ungtr_f", "ungti_f",
"ltgtr_f", "ltgti_f",
"ordr_f", "ordi_f",
"unordr_f", "unordi_f",
"truncr_f_i", "truncr_f_l",
"extr_f", "extr_d_f",
"movr_f", "movi_f",
"ldr_f", "ldi_f",
"ldxr_f", "ldxi_f",
"str_f", "sti_f",
"stxr_f", "stxi_f",
"bltr_f", "blti_f",
"bler_f", "blei_f",
"beqr_f", "beqi_f",
"bger_f", "bgei_f",
"bgtr_f", "bgti_f",
"bner_f", "bnei_f",
"bunltr_f", "bunlti_f",
"bunler_f", "bunlei_f",
"buneqr_f", "buneqi_f",
"bunger_f", "bungei_f",
"bungtr_f", "bungti_f",
"bltgtr_f", "bltgti_f",
"bordr_f", "bordi_f",
"bunordr_f", "bunordi_f",
"pushargr_f", "pushargi_f",
"retr_f", "reti_f",
"retval_f",
"arg_d", "getarg_d",
"putargr_d", "putargi_d",
"addr_d", "addi_d",
"subr_d", "subi_d",
"rsbi_d",
"mulr_d", "muli_d",
"divr_d", "divi_d",
"negr_d", "negi_d",
"absr_d", "absi_d",
"sqrtr_d", "sqrti_d",
"ltr_d", "lti_d",
"ler_d", "lei_d",
"eqr_d", "eqi_d",
"ger_d", "gei_d",
"gtr_d", "gti_d",
"ner_d", "nei_d",
"unltr_d", "unlti_d",
"unler_d", "unlei_d",
"uneqr_d", "uneqi_d",
"unger_d", "ungei_d",
"ungtr_d", "ungti_d",
"ltgtr_d", "ltgti_d",
"ordr_d", "ordi_d",
"unordr_d", "unordi_d",
"truncr_d_i",
"truncr_d_l",
"extr_d", "extr_f_d",
"movr_d", "movi_d",
"ldr_d", "ldi_d",
"ldxr_d", "ldxi_d",
"str_d", "sti_d",
"stxr_d", "stxi_d",
"bltr_d", "blti_d",
"bler_d", "blei_d",
"beqr_d", "beqi_d",
"bger_d", "bgei_d",
"bgtr_d", "bgti_d",
"bner_d", "bnei_d",
"bunltr_d", "bunlti_d",
"bunler_d", "bunlei_d",
"buneqr_d", "buneqi_d",
"bunger_d", "bungei_d",
"bungtr_d", "bungti_d",
"bltgtr_d", "bltgti_d",
"bordr_d", "bordi_d",
"bunordr_d", "bunordi_d",
"pushargr_d", "pushargi_d",
"retr_d", "reti_d",
"retval_d",
"movr_w_f", "movi_w_f",
"movr_ww_d", "movi_ww_d",
"movr_w_d", "movi_w_d",
"movr_f_w", "movi_f_w",
"movr_d_ww", "movi_d_ww",
"movr_d_w", "movi_d_w",
"clor", "cloi",
"clzr", "clzi",
"ctor", "ctoi",
"ctzr", "ctzi",
"rbitr", "rbiti",
"popcntr", "popcnti",
"lrotr", "lroti",
"rrotr", "rroti",
"extr", "exti",
"extr_u", "exti_u",
"depr", "depi",
"qlshr", "qlshi",
"qlshr_u", "qlshi_u",
"qrshr", "qrshi",
"qrshr_u", "qrshi_u",
"unldr", "unldi",
"unldr_u", "unldi_u",
"unstr", "unsti",
"unldr_x", "unldi_x",
"unstr_x", "unsti_x",
"fmar_f", "fmai_f",
"fmsr_f", "fmsi_f",
"fmar_d", "fmai_d",
"fmsr_d", "fmsi_d",
"fnmar_f", "fnmai_f",
"fnmsr_f", "fnmsi_f",
"fnmar_d", "fnmai_d",
"fnmsr_d", "fnmsi_d",
};
+414
View File
@@ -0,0 +1,414 @@
/*
* Copyright (C) 2013-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#include <lightning.h>
#include <lightning/jit_private.h>
/*
* Prototypes
*/
#define new_note(u, v) _new_note(_jit, u, v)
static jit_note_t *_new_note(jit_state_t *, jit_uint8_t*, char*);
static void new_line(jit_int32_t,jit_note_t*,char*,jit_int32_t,jit_int32_t);
#define note_search_index(u) _note_search_index(_jit, u)
static jit_int32_t _note_search_index(jit_state_t*, jit_uint8_t*);
static jit_int32_t line_insert_index(jit_note_t*,jit_int32_t);
static jit_int32_t line_search_index(jit_note_t*,jit_int32_t);
static jit_int32_t offset_insert_index(jit_line_t*,jit_int32_t);
static jit_int32_t offset_search_index(jit_line_t*,jit_int32_t);
/*
* Implementation
*/
void
jit_init_note(void)
{
}
void
jit_finish_note(void)
{
}
jit_node_t *
_jit_name(jit_state_t *_jit, const char *name)
{
jit_node_t *node;
node = jit_new_node(jit_code_name);
if (name)
node->v.n = jit_data(name, strlen(name) + 1, 1);
else
node->v.p = NULL;
if (_jitc->note.head == NULL)
_jitc->note.head = _jitc->note.tail = node;
else {
_jitc->note.tail->link = node;
_jitc->note.tail = node;
}
++_jit->note.length;
_jitc->note.size += sizeof(jit_note_t);
/* remember previous note is invalid due to name change */
_jitc->note.note = NULL;
return (_jitc->note.name = node);
}
jit_node_t *
_jit_note(jit_state_t *_jit, const char *name, int line)
{
jit_node_t *node;
node = jit_new_node(jit_code_note);
if (name)
node->v.n = jit_data(name, strlen(name) + 1, 1);
else
node->v.p = NULL;
node->w.w = line;
if (_jitc->note.head == NULL)
_jitc->note.head = _jitc->note.tail = node;
else {
_jitc->note.tail->link = node;
_jitc->note.tail = node;
}
if (_jitc->note.note == NULL ||
(name == NULL && _jitc->note.note != NULL) ||
(name != NULL && _jitc->note.note == NULL) ||
(name != NULL && _jitc->note.note != NULL &&
strcmp(name, (char *)_jitc->data.ptr + _jitc->note.note->v.n->u.w)))
_jitc->note.size += sizeof(jit_line_t);
_jitc->note.size += sizeof(jit_int32_t) * 2;
return (_jitc->note.note = node);
}
void
_jit_annotate(jit_state_t *_jit)
{
jit_node_t *node;
jit_note_t *note;
jit_line_t *line;
jit_word_t length;
jit_word_t note_offset;
jit_word_t line_offset;
/* initialize pointers in mmaped data area */
_jit->note.ptr = (jit_note_t *)_jitc->note.base;
_jit->note.length = 0;
note = NULL;
for (node = _jitc->note.head; node; node = node->link) {
if (node->code == jit_code_name)
note = new_note(node->u.p, node->v.p ? node->v.n->u.p : NULL);
else if (node->v.p) {
if (note == NULL)
note = new_note(node->u.p, NULL);
jit_set_note(note, node->v.n->u.p, node->w.w,
(jit_uint8_t *)node->u.p - note->code);
}
}
/* last note */
if (note)
note->size = _jit->pc.uc - note->code;
/* annotations may be very complex with conditions to extend
* or ignore redundant notes, as well as add entries to earlier
* notes, so, relocate the information to the data buffer,
* with likely over allocated reserved space */
/* relocate jit_line_t objects */
for (note_offset = 0; note_offset < _jit->note.length; note_offset++) {
note = _jit->note.ptr + note_offset;
if ((length = sizeof(jit_line_t) * note->length) == 0)
continue;
assert(_jitc->note.base + length <= _jit->data.ptr + _jit->data.length);
jit_memcpy(_jitc->note.base, note->lines, length);
jit_free((jit_pointer_t *)&note->lines);
note->lines = (jit_line_t *)_jitc->note.base;
_jitc->note.base += length;
}
/* relocate offset and line number information */
for (note_offset = 0; note_offset < _jit->note.length; note_offset++) {
note = _jit->note.ptr + note_offset;
for (line_offset = 0; line_offset < note->length; line_offset++) {
line = note->lines + line_offset;
length = sizeof(jit_int32_t) * line->length;
assert(_jitc->note.base + length <=
_jit->data.ptr + _jit->data.length);
jit_memcpy(_jitc->note.base, line->linenos, length);
jit_free((jit_pointer_t *)&line->linenos);
line->linenos = (jit_int32_t *)_jitc->note.base;
_jitc->note.base += length;
assert(_jitc->note.base + length <=
_jit->data.ptr + _jit->data.length);
jit_memcpy(_jitc->note.base, line->offsets, length);
jit_free((jit_pointer_t *)&line->offsets);
line->offsets = (jit_int32_t *)_jitc->note.base;
_jitc->note.base += length;
}
}
}
void
_jit_set_note(jit_state_t *_jit, jit_note_t *note,
char *file, int lineno, jit_int32_t offset)
{
jit_line_t *line;
jit_int32_t index;
index = line_insert_index(note, offset);
if (note->length && index == note->length &&
note->lines[index - 1].file == file)
--index;
if (index >= note->length || note->lines[index].file != file)
new_line(index, note, file, lineno, offset);
else {
line = note->lines + index;
index = offset_insert_index(line, offset);
if (index < line->length && line->offsets[index] == offset) {
/* common case if no code was generated for several source lines */
if (line->linenos[index] < lineno)
line->linenos[index] = lineno;
}
else if (index < line->length && line->linenos[index] == lineno) {
/* common case of extending entry */
if (line->offsets[index] > offset)
line->offsets[index] = offset;
}
else {
/* line or offset changed */
if ((line->length & 15) == 0) {
jit_realloc((jit_pointer_t *)&line->linenos,
line->length * sizeof(jit_int32_t),
(line->length + 17) * sizeof(jit_int32_t));
jit_realloc((jit_pointer_t *)&line->offsets,
line->length * sizeof(jit_int32_t),
(line->length + 17) * sizeof(jit_int32_t));
}
if (index < note->length) {
jit_memmove(line->linenos + index + 1, line->linenos + index,
sizeof(jit_int32_t) * (line->length - index));
jit_memmove(line->offsets + index + 1, line->offsets + index,
sizeof(jit_int32_t) * (line->length - index));
}
line->linenos[index] = lineno;
line->offsets[index] = offset;
++line->length;
}
}
}
jit_bool_t
_jit_get_note(jit_state_t *_jit, jit_pointer_t code,
char **name, char **file, jit_int32_t *lineno)
{
jit_note_t *note;
jit_line_t *line;
jit_int32_t index;
jit_int32_t offset;
if ((index = note_search_index((jit_uint8_t *)code)) >= _jit->note.length)
return (0);
note = _jit->note.ptr + index;
if ((jit_uint8_t *)code < note->code ||
(jit_uint8_t *)code >= note->code + note->size)
return (0);
offset = (jit_uint8_t *)code - note->code;
if ((index = line_search_index(note, offset)) >= note->length)
return (0);
if (index == 0 && offset < note->lines[0].offsets[0])
return (0);
line = note->lines + index;
if ((index = offset_search_index(line, offset)) >= line->length)
return (0);
if (name)
*name = note->name;
if (file)
*file = line->file;
if (lineno)
*lineno = line->linenos[index];
return (1);
}
static jit_note_t *
_new_note(jit_state_t *_jit, jit_uint8_t *code, char *name)
{
jit_note_t *note;
jit_note_t *prev;
if (_jit->note.length) {
prev = _jit->note.ptr + _jit->note.length - 1;
assert(code >= prev->code);
prev->size = code - prev->code;
}
note = (jit_note_t *)_jitc->note.base;
_jitc->note.base += sizeof(jit_note_t);
++_jit->note.length;
note->code = code;
note->name = name;
return (note);
}
static void
new_line(jit_int32_t index, jit_note_t *note,
char *file, jit_int32_t lineno, jit_int32_t offset)
{
jit_line_t *line;
if (note->lines == NULL)
jit_alloc((jit_pointer_t *)&note->lines, 16 * sizeof(jit_line_t));
else if ((note->length & 15) == 15)
jit_realloc((jit_pointer_t *)&note->lines,
note->length * sizeof(jit_line_t),
(note->length + 17) * sizeof(jit_line_t));
if (index < note->length)
jit_memmove(note->lines + index + 1, note->lines + index,
sizeof(jit_line_t) * (note->length - index));
line = note->lines + index;
++note->length;
line->file = file;
line->length = 1;
jit_alloc((jit_pointer_t *)&line->linenos, 16 * sizeof(jit_int32_t));
line->linenos[0] = lineno;
jit_alloc((jit_pointer_t *)&line->offsets, 16 * sizeof(jit_int32_t));
line->offsets[0] = offset;
}
static jit_int32_t
_note_search_index(jit_state_t *_jit, jit_uint8_t *code)
{
jit_int32_t bot;
jit_int32_t top;
jit_int32_t index;
jit_note_t *notes;
bot = 0;
top = _jit->note.length;
notes = _jit->note.ptr;
for (index = (bot + top) >> 1; bot < top; index = (bot + top) >> 1) {
if (code < notes[index].code)
top = index;
else if (code >= notes[index].code &&
code - notes[index].code < notes[index].size)
break;
else
bot = index + 1;
}
return (index);
}
static jit_int32_t
line_insert_index(jit_note_t *note, jit_int32_t offset)
{
jit_int32_t bot;
jit_int32_t top;
jit_int32_t index;
jit_line_t *lines;
bot = 0;
top = note->length;
if ((lines = note->lines) == NULL)
return (0);
for (index = (bot + top) >> 1; bot < top; index = (bot + top) >> 1) {
if (offset < *lines[index].offsets)
top = index;
else
bot = index + 1;
}
return ((bot + top) >> 1);
}
static jit_int32_t
line_search_index(jit_note_t *note, jit_int32_t offset)
{
jit_int32_t bot;
jit_int32_t top;
jit_int32_t index;
jit_line_t *lines;
bot = 0;
top = note->length;
if ((lines = note->lines) == NULL)
return (0);
for (index = (bot + top) >> 1; bot < top; index = (bot + top) >> 1) {
if (offset < *lines[index].offsets)
top = index;
/* offset should be already verified to be in range */
else if (index == note->length - 1 ||
(offset >= *lines[index].offsets &&
offset < *lines[index + 1].offsets))
break;
else
bot = index + 1;
}
return (index);
}
static jit_int32_t
offset_insert_index(jit_line_t *line, jit_int32_t offset)
{
jit_int32_t bot;
jit_int32_t top;
jit_int32_t index;
jit_int32_t *offsets;
bot = 0;
top = line->length;
offsets = line->offsets;
for (index = (bot + top) >> 1; bot < top; index = (bot + top) >> 1) {
if (offset < offsets[index])
top = index;
else
bot = index + 1;
}
return ((bot + top) >> 1);
}
static jit_int32_t
offset_search_index(jit_line_t *line, jit_int32_t offset)
{
jit_int32_t bot;
jit_int32_t top;
jit_int32_t index;
jit_int32_t *offsets;
bot = 0;
top = line->length;
offsets = line->offsets;
for (index = (bot + top) >> 1; bot < top; index = (bot + top) >> 1) {
if (offset < offsets[index])
top = index;
/* offset should be already verified to be in range */
else if (index == line->length - 1 ||
(offset >= offsets[index] && offset < offsets[index + 1]))
break;
else
bot = index + 1;
}
return (index);
}
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,482 @@
/*
* Copyright (C) 2012-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#include <lightning.h>
#include <lightning/jit_private.h>
#if __WORDSIZE == 32
# define MININT 0x80000000
# define INT_FMT "%d"
# define DEC_FMT "%d"
# define HEX_FMT "0x%x"
#else
# define MININT 0x8000000000000000
# define INT_FMT "%d"
# define DEC_FMT "%ld"
# define HEX_FMT "0x%lx"
#endif
#define print_chr(value) fputc(value, print_stream)
#define print_hex(value) \
do { \
if (value < 0 && value != MININT) \
fprintf(print_stream, "-" HEX_FMT, (jit_uword_t)-value); \
else \
fprintf(print_stream, HEX_FMT, (jit_uword_t)value); \
} while (0)
#define print_dec(value) fprintf(print_stream, DEC_FMT, value)
#define print_int(value) fprintf(print_stream, INT_FMT, value)
#define print_flt(value) fprintf(print_stream, "%g", value)
#define print_str(value) fprintf(print_stream, "%s", value)
#define print_ptr(value) fprintf(print_stream, "%p", value)
#define print_reg(value) \
do { \
if ((value) & jit_regno_patch) \
print_chr('?'); \
print_str(_rvs[jit_regno(value)].name); \
} while (0)
#define print_arg(value) \
do { \
print_chr('#'); \
if (value) \
print_dec((value)->v.w); \
else \
print_chr('?'); \
} while (0)
/*
* Initialization
*/
#include "jit_names.c"
/*
* Initialization
*/
static FILE *print_stream;
/*
* Implementation
*/
void
jit_init_print(void)
{
if (!print_stream)
print_stream = stderr;
}
void
_jit_print(jit_state_t *_jit)
{
jit_node_t *node;
if ((node = _jitc->head)) {
jit_print_node(node);
for (node = node->next; node; node = node->next) {
print_chr('\n');
jit_print_node(node);
}
print_chr('\n');
}
}
void
_jit_print_node(jit_state_t *_jit, jit_node_t *node)
{
jit_block_t *block;
jit_int32_t value;
jit_int32_t offset;
if (node->code == jit_code_label ||
node->code == jit_code_prolog || node->code == jit_code_epilog) {
print_chr('L');
print_dec(node->v.w);
print_chr(':');
block = _jitc->blocks.ptr + node->v.w;
for (offset = 0; offset < _jitc->reglen; offset++) {
if (jit_regset_tstbit(&block->reglive, offset)) {
print_chr(' ');
print_reg(offset);
}
}
if (node->code == jit_code_prolog ||
node->code == jit_code_epilog) {
print_str(" /* ");
print_str(code_name[node->code]);
print_str(" */");
}
return;
}
value = jit_classify(node->code) &
(jit_cc_a0_int|jit_cc_a0_flt|jit_cc_a0_dbl|jit_cc_a0_jmp|
jit_cc_a0_reg|jit_cc_a0_rlh|jit_cc_a0_arg|
jit_cc_a1_reg|jit_cc_a1_rlh|jit_cc_a1_int|
jit_cc_a1_flt|jit_cc_a1_dbl|jit_cc_a1_arg|
jit_cc_a2_reg|jit_cc_a2_int|jit_cc_a2_flt|jit_cc_a2_dbl|jit_cc_a2_rlh);
if (!(node->flag & jit_flag_synth) && ((value & jit_cc_a0_jmp) ||
node->code == jit_code_finishr ||
node->code == jit_code_finishi))
print_str(" ");
else
print_chr('\t');
if (node->flag & jit_flag_synth)
print_str(" \\__ ");
print_str(code_name[node->code]);
switch (node->code) {
r:
print_chr(' '); print_reg(node->u.w); return;
w:
print_chr(' '); print_hex(node->u.w); return;
f:
print_chr(' ');
if (node->flag & jit_flag_data)
print_flt(*(jit_float32_t *)node->u.n->u.w);
else
print_flt(node->u.f);
return;
d:
print_chr(' ');
if (node->flag & jit_flag_data)
print_flt(*(jit_float64_t *)node->u.n->u.w);
else
print_flt(node->u.d);
return;
n:
print_chr(' ');
if (!(node->flag & jit_flag_node))
print_ptr(node->u.p);
else {
print_chr('L');
print_dec(node->u.n->v.w);
}
return;
a:
print_chr(' '); print_arg(node); return;
r_r:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_reg(node->v.w); return;
r_w:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_hex(node->v.w); return;
r_f:
print_chr(' '); print_reg(node->u.w);
print_chr(' ');
if (node->flag & jit_flag_data)
print_flt(*(jit_float32_t *)node->v.n->u.w);
else
print_flt(node->v.f);
return;
r_d:
print_chr(' '); print_reg(node->u.w);
print_chr(' ');
if (node->flag & jit_flag_data)
print_flt(*(jit_float64_t *)node->v.n->u.w);
else
print_flt(node->v.d);
return;
r_a:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_arg(node->v.n);
return;
w_r:
print_chr(' '); print_hex(node->u.w);
print_chr(' '); print_reg(node->v.w); return;
w_w:
print_chr(' '); print_hex(node->u.w);
print_chr(' '); print_hex(node->v.w); return;
w_a:
print_chr(' '); print_hex(node->u.w);
print_chr(' '); print_arg(node->v.n);
return;
f_a:
print_chr(' ');
if (node->flag & jit_flag_data)
print_flt(*(jit_float32_t *)node->u.n->u.w);
else
print_flt(node->u.f);
print_chr(' '); print_arg(node->v.n);
return;
d_a:
print_chr(' ');
if (node->flag & jit_flag_data)
print_flt(*(jit_float64_t *)node->u.n->u.w);
else
print_flt(node->u.d);
print_chr(' '); print_arg(node->v.n);
return;
r_r_r:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_reg(node->v.w);
print_chr(' '); print_reg(node->w.w); return;
r_r_w:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_reg(node->v.w);
print_chr(' '); print_hex(node->w.w); return;
r_w_w:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_hex(node->v.w);
print_chr(' ');
if (node->code == jit_code_movi_ww_d)
print_hex(node->w.w);
else
print_dec(node->w.w); return;
w_r_w:
print_chr(' '); print_hex(node->u.w);
print_chr(' '); print_reg(node->v.w);
print_chr(' '); print_dec(node->w.w); return;
q_r_r:
print_str(" ("); print_reg(node->u.q.l);
print_chr(' '); print_reg(node->u.q.h);
print_str(") "); print_reg(node->v.w);
print_chr(' '); print_reg(node->w.w); return;
q_r_w:
print_str(" ("); print_reg(node->u.q.l);
print_chr(' '); print_reg(node->u.q.h);
print_str(") "); print_reg(node->v.w);
print_chr(' '); print_hex(node->w.w); return;
r_r_q:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_reg(node->v.w);
print_str(" ("); print_reg(node->w.q.l);
print_chr(' '); print_reg(node->w.q.h);
print_str(") "); return;
r_w_q:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_hex(node->v.w);
print_str(" ("); print_reg(node->w.q.l);
print_chr(' '); print_reg(node->w.q.h);
print_str(") "); return;
r_r_iq:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_reg(node->v.w);
print_str(" ("); print_int(node->w.q.l);
print_chr(' '); print_int(node->w.q.h);
print_str(") "); return;
r_w_iq:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_hex(node->v.w);
print_str(" ("); print_int(node->w.q.l);
print_chr(' '); print_int(node->w.q.h);
print_str(") "); return;
r_q_r:
print_chr(' '); print_reg(node->u.w);
print_str(" ("); print_reg(node->v.q.l);
print_chr(' '); print_reg(node->v.q.h);
print_str(") "); print_reg(node->w.w);
return;
r_r_f:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_reg(node->v.w);
print_chr(' ');
if (node->flag & jit_flag_data)
print_flt(*(jit_float32_t *)node->w.n->u.w);
else
print_flt(node->w.f);
return;
r_q_f:
print_chr(' '); print_reg(node->u.w);
print_str(" ("); print_reg(node->v.q.l);
print_chr(' '); print_reg(node->v.q.h);
print_str(") ");
if (node->flag & jit_flag_data)
print_flt(*(jit_float32_t *)node->w.n->u.w);
else
print_flt(node->w.f);
return;
r_r_d:
print_chr(' '); print_reg(node->u.w);
print_chr(' '); print_reg(node->v.w);
print_chr(' ');
if (node->flag & jit_flag_data)
print_flt(*(jit_float64_t *)node->w.n->u.w);
else
print_flt(node->w.d);
return;
r_q_d:
print_chr(' '); print_reg(node->u.w);
print_str(" ("); print_reg(node->v.q.l);
print_chr(' '); print_reg(node->v.q.h);
print_str(") ");
if (node->flag & jit_flag_data)
print_flt(*(jit_float64_t *)node->w.n->u.w);
else
print_flt(node->w.d);
return;
w_r_r:
print_chr(' '); print_hex(node->u.w);
print_chr(' '); print_reg(node->v.w);
print_chr(' '); print_reg(node->w.w); return;
n_r_r:
print_chr(' ');
if (!(node->flag & jit_flag_node))
print_ptr(node->u.p);
else {
print_chr('L');
print_dec(node->u.n->v.w);
}
print_chr(' '); print_reg(node->v.w);
print_chr(' '); print_reg(node->w.w); return;
n_r_w:
print_chr(' ');
if (!(node->flag & jit_flag_node))
print_ptr(node->u.p);
else {
print_chr('L');
print_dec(node->u.n->v.w);
}
print_chr(' '); print_reg(node->v.w);
print_chr(' '); print_hex(node->w.w); return;
n_r_f:
print_chr(' ');
if (!(node->flag & jit_flag_node))
print_ptr(node->u.p);
else{
print_chr('L');
print_dec(node->u.n->v.w);
}
print_chr(' '); print_reg(node->v.w);
print_chr(' ');
if (node->flag & jit_flag_data)
print_flt(*(jit_float32_t *)node->w.n->u.w);
else
print_flt(node->w.f);
return;
n_r_d:
print_chr(' ');
if (!(node->flag & jit_flag_node))
print_ptr(node->u.p);
else {
print_chr('L');
print_dec(node->u.n->v.w);
}
print_chr(' '); print_reg(node->v.w);
print_chr(' ');
if (node->flag & jit_flag_data)
print_flt(*(jit_float64_t *)node->w.n->u.w);
else
print_flt(node->w.d);
return;
case jit_code_name:
print_chr(' ');
if (node->v.p && _jitc->emit)
print_str((char *)node->v.n->u.p);
break;
case jit_code_note:
print_chr(' ');
if (node->v.p && _jitc->emit)
print_str((char *)node->v.n->u.p);
if (node->v.p && _jitc->emit && node->w.w)
print_chr(':');
if (node->w.w)
print_dec(node->w.w);
break;
case jit_code_data:
case jit_code_label:
case jit_code_ellipsis:
case jit_code_prolog: case jit_code_epilog:
case jit_code_ret: case jit_code_prepare:
break;
case jit_code_save: case jit_code_load:
goto r;
default:
switch (value) {
case jit_cc_a0_reg:
case jit_cc_a0_reg|jit_cc_a0_chg:
case jit_cc_a0_reg|jit_cc_a0_jmp:
goto r;
case jit_cc_a0_int:
goto w;
case jit_cc_a0_flt:
goto f;
case jit_cc_a0_dbl:
goto d;
case jit_cc_a0_jmp:
goto n;
case jit_cc_a0_int|jit_cc_a0_arg:
goto a;
case jit_cc_a0_reg|jit_cc_a1_reg:
goto r_r;
case jit_cc_a0_reg|jit_cc_a1_int:
goto r_w;
case jit_cc_a0_reg|jit_cc_a1_flt:
goto r_f;
case jit_cc_a0_reg|jit_cc_a1_dbl:
goto r_d;
case jit_cc_a0_reg|jit_cc_a1_arg:
goto r_a;
case jit_cc_a0_int|jit_cc_a1_reg:
goto w_r;
case jit_cc_a0_int|jit_cc_a1_int:
goto w_w;
case jit_cc_a0_int|jit_cc_a1_arg:
goto w_a;
case jit_cc_a0_flt|jit_cc_a1_arg:
goto f_a;
case jit_cc_a0_dbl|jit_cc_a1_arg:
goto d_a;
case jit_cc_a0_reg|jit_cc_a1_reg|jit_cc_a2_reg:
goto r_r_r;
case jit_cc_a0_reg|jit_cc_a1_reg|jit_cc_a2_int:
goto r_r_w;
case jit_cc_a0_reg|jit_cc_a1_int|jit_cc_a2_int:
goto r_w_w;
case jit_cc_a0_int|jit_cc_a1_reg|jit_cc_a2_int:
goto w_r_w;
case jit_cc_a0_reg|jit_cc_a0_rlh|
jit_cc_a1_reg|jit_cc_a2_reg:
goto q_r_r;
case jit_cc_a0_reg|jit_cc_a0_rlh|
jit_cc_a1_reg|jit_cc_a2_int:
goto q_r_w;
case jit_cc_a0_reg|jit_cc_a1_reg|
jit_cc_a2_reg|jit_cc_a2_rlh:
goto r_r_q;
case jit_cc_a0_reg|jit_cc_a1_int|
jit_cc_a2_reg|jit_cc_a2_rlh:
goto r_w_q;
case jit_cc_a0_reg|jit_cc_a1_reg|jit_cc_a2_rlh:
goto r_r_iq;
case jit_cc_a0_reg|jit_cc_a1_int|jit_cc_a2_rlh:
goto r_w_iq;
case jit_cc_a0_reg|jit_cc_a1_reg|jit_cc_a2_flt:
goto r_r_f;
case jit_cc_a0_reg|jit_cc_a1_reg|jit_cc_a2_dbl:
goto r_r_d;
case jit_cc_a0_int|jit_cc_a1_reg|jit_cc_a2_reg:
goto w_r_r;
case jit_cc_a0_jmp|jit_cc_a1_reg|jit_cc_a2_reg:
goto n_r_r;
case jit_cc_a0_jmp|jit_cc_a1_reg|jit_cc_a2_int:
goto n_r_w;
case jit_cc_a0_jmp|jit_cc_a1_reg|jit_cc_a2_flt:
goto n_r_f;
case jit_cc_a0_jmp|jit_cc_a1_reg|jit_cc_a2_dbl:
goto n_r_d;
case jit_cc_a0_reg|jit_cc_a1_reg|jit_cc_a1_rlh|jit_cc_a2_reg:
goto r_q_r;
case jit_cc_a0_reg|jit_cc_a1_reg|jit_cc_a1_rlh|jit_cc_a2_flt:
goto r_q_f;
case jit_cc_a0_reg|jit_cc_a1_reg|jit_cc_a1_rlh|jit_cc_a2_dbl:
goto r_q_d;
default:
abort();
}
break;
}
}
@@ -0,0 +1,189 @@
/*
* Copyright (C) 2015-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#include <lightning.h>
#include <lightning/jit_private.h>
#if PROTO
# define free_synth_list(node) _free_synth_list(_jit,node)
static jit_node_t *_free_synth_list(jit_state_t*,jit_node_t*);
#define rewind_prolog() _rewind_prolog(_jit)
static void _rewind_prolog(jit_state_t*);
#define rewind_prepare() _rewind_prepare(_jit)
static void _rewind_prepare(jit_state_t*);
#endif
#if CODE
/*
* Implementation
*/
static jit_node_t *
_free_synth_list(jit_state_t *_jit, jit_node_t *node)
{
jit_node_t *next;
next = node->next;
free_node(node);
for (node = next; node && (node->flag & jit_flag_synth); node = next) {
next = node->next;
free_node(node);
}
return (next);
}
static void
_rewind_prolog(jit_state_t *_jit)
{
jit_node_t *node;
jit_node_t *next;
_jitc->function->self.size = stack_framesize;
#if __arm__
assert(jit_cpu.abi);
_jitc->function->alist = NULL;
#elif __mips__
_jitc->function->alist = NULL;
#endif
_jitc->function->self.argi =
_jitc->function->self.argf = _jitc->function->self.argn = 0;
_jitc->tail = _jitc->function->prolog;
node = _jitc->tail->next;
_jitc->tail->next = (jit_node_t *)0;
_jitc->tail->link = (jit_node_t *)0;
for (; node; node = next) {
next = node->next;
switch (node->code) {
case jit_code_arg_c: case jit_code_arg_s:
case jit_code_arg_i: case jit_code_arg_l:
node->next = (jit_node_t *)0;
jit_make_arg(node, node->code);
break;
case jit_code_arg_f:
node->next = (jit_node_t *)0;
jit_make_arg_f(node);
break;
case jit_code_arg_d:
node->next = (jit_node_t *)0;
jit_make_arg_d(node);
break;
case jit_code_getarg_c:
jit_getarg_c(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_getarg_uc:
jit_getarg_uc(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_getarg_s:
jit_getarg_s(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_getarg_us:
jit_getarg_us(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_getarg_i:
jit_getarg_i(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_getarg_f:
jit_getarg_f(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_getarg_d:
jit_getarg_d(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_putargr:
jit_putargr(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_putargi:
jit_putargi(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_putargr_f:
jit_putargr_f(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_putargi_f:
jit_putargi_f(node->u.f, node->v.n);
next = free_synth_list(node);
break;
case jit_code_putargr_d:
jit_putargr_d(node->u.w, node->v.n);
next = free_synth_list(node);
break;
case jit_code_putargi_d:
jit_putargi_d(node->u.d, node->v.n);
next = free_synth_list(node);
break;
default:
node->next = (jit_node_t *)0;
link_node(node);
break;
}
}
}
static void
_rewind_prepare(jit_state_t *_jit)
{
jit_node_t *node;
jit_node_t *next;
_jitc->function->call.argi =
_jitc->function->call.argf =
_jitc->function->call.size = 0;
_jitc->tail = _jitc->prepare;
node = _jitc->tail->next;
_jitc->tail->next = (jit_node_t *)0;
_jitc->tail->link = (jit_node_t *)0;
for (; node; node = next) {
next = node->next;
switch (node->code) {
case jit_code_pushargr:
jit_pushargr(node->u.w);
next = free_synth_list(node);
break;
case jit_code_pushargi:
jit_pushargi(node->u.w);
next = free_synth_list(node);
break;
case jit_code_pushargr_f:
jit_pushargr_f(node->u.w);
next = free_synth_list(node);
break;
case jit_code_pushargi_f:
jit_pushargi_f(node->u.f);
next = free_synth_list(node);
break;
case jit_code_pushargr_d:
jit_pushargr_d(node->u.w);
next = free_synth_list(node);
break;
case jit_code_pushargi_d:
jit_pushargi_d(node->u.d);
next = free_synth_list(node);
break;
default:
node->next = (jit_node_t *)0;
link_node(node);
break;
}
}
}
#endif
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,527 @@
#if __WORDSIZE == 64
#define JIT_INSTR_MAX 116
0, /* data */
0, /* live */
4, /* align */
0, /* save */
0, /* load */
4, /* skip */
0, /* #name */
0, /* #note */
0, /* label */
112, /* prolog */
0, /* ellipsis */
0, /* va_push */
0, /* allocai */
0, /* allocar */
0, /* arg_c */
0, /* arg_s */
0, /* arg_i */
0, /* arg_l */
0, /* getarg_c */
0, /* getarg_uc */
0, /* getarg_s */
0, /* getarg_us */
0, /* getarg_i */
0, /* getarg_ui */
0, /* getarg_l */
0, /* putargr_c */
0, /* putargi_c */
0, /* putargr_uc */
0, /* putargi_uc */
0, /* putargr_s */
0, /* putargi_s */
0, /* putargr_us */
0, /* putargi_us */
0, /* putargr_i */
0, /* putargi_i */
0, /* putargr_ui */
0, /* putargi_ui */
0, /* putargr_l */
0, /* putargi_l */
4, /* va_start */
8, /* va_arg */
8, /* va_arg_d */
0, /* va_end */
4, /* addr */
16, /* addi */
12, /* addcr */
24, /* addci */
28, /* addxr */
28, /* addxi */
4, /* subr */
16, /* subi */
12, /* subcr */
24, /* subci */
28, /* subxr */
28, /* subxi */
20, /* rsbi */
4, /* mulr */
16, /* muli */
12, /* qmulr */
20, /* qmuli */
12, /* qmulr_u */
20, /* qmuli_u */
4, /* divr */
16, /* divi */
4, /* divr_u */
16, /* divi_u */
20, /* qdivr */
16, /* qdivi */
20, /* qdivr_u */
16, /* qdivi_u */
4, /* remr */
16, /* remi */
4, /* remr_u */
16, /* remi_u */
4, /* andr */
16, /* andi */
4, /* orr */
16, /* ori */
4, /* xorr */
16, /* xori */
4, /* lshr */
4, /* lshi */
4, /* rshr */
4, /* rshi */
4, /* rshr_u */
4, /* rshi_u */
4, /* negr */
4, /* negi */
4, /* comr */
4, /* comi */
4, /* ltr */
4, /* lti */
4, /* ltr_u */
4, /* lti_u */
8, /* ler */
12, /* lei */
8, /* ler_u */
12, /* lei_u */
12, /* eqr */
12, /* eqi */
8, /* ger */
12, /* gei */
8, /* ger_u */
12, /* gei_u */
4, /* gtr */
8, /* gti */
4, /* gtr_u */
8, /* gti_u */
8, /* ner */
8, /* nei */
4, /* movr */
12, /* movi */
12, /* movnr */
12, /* movzr */
28, /* casr */
40, /* casi */
8, /* extr_c */
4, /* exti_c */
4, /* extr_uc */
4, /* exti_uc */
8, /* extr_s */
4, /* exti_s */
8, /* extr_us */
8, /* exti_us */
4, /* extr_i */
4, /* exti_i */
8, /* extr_ui */
12, /* exti_ui */
20, /* bswapr_us */
8, /* bswapi_us */
52, /* bswapr_ui */
8, /* bswapi_ui */
116, /* bswapr_ul */
12, /* bswapi_ul */
20, /* htonr_us */
8, /* htoni_us */
52, /* htonr_ui */
8, /* htoni_ui */
116, /* htonr_ul */
12, /* htoni_ul */
4, /* ldr_c */
16, /* ldi_c */
4, /* ldr_uc */
16, /* ldi_uc */
4, /* ldr_s */
16, /* ldi_s */
4, /* ldr_us */
16, /* ldi_us */
4, /* ldr_i */
16, /* ldi_i */
4, /* ldr_ui */
16, /* ldi_ui */
4, /* ldr_l */
16, /* ldi_l */
8, /* ldxr_c */
16, /* ldxi_c */
8, /* ldxr_uc */
16, /* ldxi_uc */
8, /* ldxr_s */
16, /* ldxi_s */
8, /* ldxr_us */
16, /* ldxi_us */
8, /* ldxr_i */
16, /* ldxi_i */
8, /* ldxr_ui */
16, /* ldxi_ui */
8, /* ldxr_l */
16, /* ldxi_l */
4, /* str_c */
16, /* sti_c */
4, /* str_s */
16, /* sti_s */
4, /* str_i */
16, /* sti_i */
4, /* str_l */
16, /* sti_l */
8, /* stxr_c */
16, /* stxi_c */
8, /* stxr_s */
16, /* stxi_s */
8, /* stxr_i */
16, /* stxi_i */
8, /* stxr_l */
16, /* stxi_l */
4, /* bltr */
8, /* blti */
4, /* bltr_u */
8, /* blti_u */
4, /* bler */
8, /* blei */
4, /* bler_u */
8, /* blei_u */
4, /* beqr */
16, /* beqi */
4, /* bger */
8, /* bgei */
4, /* bger_u */
8, /* bgei_u */
4, /* bgtr */
8, /* bgti */
4, /* bgtr_u */
8, /* bgti_u */
4, /* bner */
16, /* bnei */
8, /* bmsr */
12, /* bmsi */
8, /* bmcr */
12, /* bmci */
32, /* boaddr */
36, /* boaddi */
16, /* boaddr_u */
20, /* boaddi_u */
32, /* bxaddr */
36, /* bxaddi */
16, /* bxaddr_u */
20, /* bxaddi_u */
32, /* bosubr */
36, /* bosubi */
16, /* bosubr_u */
20, /* bosubi_u */
32, /* bxsubr */
36, /* bxsubi */
16, /* bxsubr_u */
20, /* bxsubi_u */
4, /* jmpr */
16, /* jmpi */
4, /* callr */
16, /* calli */
0, /* prepare */
0, /* pushargr_c */
0, /* pushargi_c */
0, /* pushargr_uc */
0, /* pushargi_uc */
0, /* pushargr_s */
0, /* pushargi_s */
0, /* pushargr_us */
0, /* pushargi_us */
0, /* pushargr_i */
0, /* pushargi_i */
0, /* pushargr_ui */
0, /* pushargi_ui */
0, /* pushargr_l */
0, /* pushargi_l */
0, /* finishr */
0, /* finishi */
0, /* ret */
0, /* retr_c */
0, /* reti_c */
0, /* retr_uc */
0, /* reti_uc */
0, /* retr_s */
0, /* reti_s */
0, /* retr_us */
0, /* reti_us */
0, /* retr_i */
0, /* reti_i */
0, /* retr_ui */
0, /* reti_ui */
0, /* retr_l */
0, /* reti_l */
0, /* retval_c */
0, /* retval_uc */
0, /* retval_s */
0, /* retval_us */
0, /* retval_i */
0, /* retval_ui */
0, /* retval_l */
112, /* epilog */
0, /* arg_f */
0, /* getarg_f */
0, /* putargr_f */
0, /* putargi_f */
4, /* addr_f */
12, /* addi_f */
4, /* subr_f */
12, /* subi_f */
12, /* rsbi_f */
4, /* mulr_f */
12, /* muli_f */
4, /* divr_f */
12, /* divi_f */
4, /* negr_f */
0, /* negi_f */
4, /* absr_f */
0, /* absi_f */
4, /* sqrtr_f */
0, /* sqrti_f */
4, /* ltr_f */
12, /* lti_f */
4, /* ler_f */
12, /* lei_f */
4, /* eqr_f */
12, /* eqi_f */
4, /* ger_f */
12, /* gei_f */
4, /* gtr_f */
12, /* gti_f */
8, /* ner_f */
16, /* nei_f */
28, /* unltr_f */
36, /* unlti_f */
28, /* unler_f */
36, /* unlei_f */
28, /* uneqr_f */
36, /* uneqi_f */
28, /* unger_f */
36, /* ungei_f */
28, /* ungtr_f */
36, /* ungti_f */
40, /* ltgtr_f */
48, /* ltgti_f */
28, /* ordr_f */
36, /* ordi_f */
20, /* unordr_f */
28, /* unordi_f */
4, /* truncr_f_i */
4, /* truncr_f_l */
4, /* extr_f */
4, /* extr_d_f */
4, /* movr_f */
8, /* movi_f */
4, /* ldr_f */
16, /* ldi_f */
8, /* ldxr_f */
16, /* ldxi_f */
4, /* str_f */
16, /* sti_f */
8, /* stxr_f */
16, /* stxi_f */
8, /* bltr_f */
16, /* blti_f */
8, /* bler_f */
16, /* blei_f */
8, /* beqr_f */
16, /* beqi_f */
8, /* bger_f */
16, /* bgei_f */
8, /* bgtr_f */
16, /* bgti_f */
8, /* bner_f */
16, /* bnei_f */
32, /* bunltr_f */
40, /* bunlti_f */
32, /* bunler_f */
40, /* bunlei_f */
32, /* buneqr_f */
40, /* buneqi_f */
32, /* bunger_f */
40, /* bungei_f */
32, /* bungtr_f */
40, /* bungti_f */
44, /* bltgtr_f */
52, /* bltgti_f */
32, /* bordr_f */
40, /* bordi_f */
24, /* bunordr_f */
32, /* bunordi_f */
0, /* pushargr_f */
0, /* pushargi_f */
0, /* retr_f */
0, /* reti_f */
0, /* retval_f */
0, /* arg_d */
0, /* getarg_d */
0, /* putargr_d */
0, /* putargi_d */
4, /* addr_d */
20, /* addi_d */
4, /* subr_d */
20, /* subi_d */
20, /* rsbi_d */
4, /* mulr_d */
20, /* muli_d */
4, /* divr_d */
20, /* divi_d */
4, /* negr_d */
0, /* negi_d */
4, /* absr_d */
0, /* absi_d */
4, /* sqrtr_d */
0, /* sqrti_d */
4, /* ltr_d */
20, /* lti_d */
4, /* ler_d */
20, /* lei_d */
4, /* eqr_d */
20, /* eqi_d */
4, /* ger_d */
20, /* gei_d */
4, /* gtr_d */
20, /* gti_d */
8, /* ner_d */
24, /* nei_d */
28, /* unltr_d */
44, /* unlti_d */
28, /* unler_d */
44, /* unlei_d */
28, /* uneqr_d */
44, /* uneqi_d */
28, /* unger_d */
44, /* ungei_d */
28, /* ungtr_d */
44, /* ungti_d */
40, /* ltgtr_d */
56, /* ltgti_d */
28, /* ordr_d */
44, /* ordi_d */
20, /* unordr_d */
36, /* unordi_d */
4, /* truncr_d_i */
4, /* truncr_d_l */
4, /* extr_d */
4, /* extr_f_d */
4, /* movr_d */
16, /* movi_d */
4, /* ldr_d */
16, /* ldi_d */
8, /* ldxr_d */
16, /* ldxi_d */
4, /* str_d */
16, /* sti_d */
8, /* stxr_d */
16, /* stxi_d */
8, /* bltr_d */
24, /* blti_d */
8, /* bler_d */
24, /* blei_d */
8, /* beqr_d */
24, /* beqi_d */
8, /* bger_d */
24, /* bgei_d */
8, /* bgtr_d */
24, /* bgti_d */
8, /* bner_d */
24, /* bnei_d */
32, /* bunltr_d */
48, /* bunlti_d */
32, /* bunler_d */
48, /* bunlei_d */
32, /* buneqr_d */
48, /* buneqi_d */
32, /* bunger_d */
48, /* bungei_d */
32, /* bungtr_d */
48, /* bungti_d */
44, /* bltgtr_d */
60, /* bltgti_d */
32, /* bordr_d */
48, /* bordi_d */
24, /* bunordr_d */
40, /* bunordi_d */
0, /* pushargr_d */
0, /* pushargi_d */
0, /* retr_d */
0, /* reti_d */
0, /* retval_d */
4, /* movr_w_f */
8, /* movi_w_f */
0, /* movr_ww_d */
0, /* movi_ww_d */
4, /* movr_w_d */
16, /* movi_w_d */
4, /* movr_f_w */
4, /* movi_f_w */
0, /* movr_d_ww */
0, /* movi_d_ww */
4, /* movr_d_w */
12, /* movi_d_w */
84, /* clor */
4, /* cloi */
64, /* clzr */
4, /* clzi */
56, /* ctor */
4, /* ctoi */
36, /* ctzr */
4, /* ctzi */
68, /* rbitr */
12, /* rbiti */
64, /* popcntr */
4, /* popcnti */
20, /* lrotr */
12, /* lroti */
20, /* rrotr */
12, /* rroti */
8, /* extr */
4, /* exti */
20, /* extr_u */
4, /* exti_u */
40, /* depr */
20, /* depi */
56, /* qlshr */
8, /* qlshi */
56, /* qlshr_u */
8, /* qlshi_u */
56, /* qrshr */
8, /* qrshi */
56, /* qrshr_u */
8, /* qrshi_u */
24, /* unldr */
44, /* unldi */
24, /* unldr_u */
44, /* unldi_u */
20, /* unstr */
56, /* unsti */
4, /* unldr_x */
16, /* unldi_x */
4, /* unstr_x */
20, /* unsti_x */
4, /* fmar_f */
0, /* fmai_f */
4, /* fmsr_f */
0, /* fmsi_f */
4, /* fmar_d */
0, /* fmai_d */
4, /* fmsr_d */
0, /* fmsi_d */
4, /* fnmar_f */
0, /* fnmai_f */
4, /* fnmsr_f */
0, /* fnmsi_f */
4, /* fnmar_d */
0, /* fnmai_d */
4, /* fnmsr_d */
0, /* fnmsi_d */
#endif /* __WORDSIZE */
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
+163
View File
@@ -0,0 +1,163 @@
/*
* Copyright (C) 2013-2023 Free Software Foundation, Inc.
*
* This file is part of GNU lightning.
*
* GNU lightning is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation; either version 3, or (at your option)
* any later version.
*
* GNU lightning is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
* License for more details.
*
* Authors:
* Paulo Cesar Pereira de Andrade
*/
#include <lightning.h>
#include <lightning/jit_private.h>
#if GET_JIT_SIZE
# include <stdio.h>
#endif
/*
* Initialization
*/
static jit_int16_t _szs[jit_code_last_code] = {
#if GET_JIT_SIZE
# define JIT_INSTR_MAX 1024
#else
# if defined(__i386__) || defined(__x86_64__)
# include "jit_x86-sz.c"
# elif defined(__mips__)
# include "jit_mips-sz.c"
# elif defined(__arm__)
# include "jit_arm-sz.c"
# elif defined(__powerpc__)
# include "jit_ppc-sz.c"
# elif defined(__sparc__)
# include "jit_sparc-sz.c"
# elif defined(__ia64__)
# include "jit_ia64-sz.c"
# elif defined(__hppa__)
# include "jit_hppa-sz.c"
# elif defined(__aarch64__)
# include "jit_aarch64-sz.c"
# elif defined(__s390__) || defined(__s390x__)
# include "jit_s390-sz.c"
# elif defined(__alpha__)
# include "jit_alpha-sz.c"
# elif defined(__riscv)
# include "jit_riscv-sz.c"
# elif defined(__loongarch__)
# include "jit_loongarch-sz.c"
# endif
#endif
};
/*
* Implementation
*/
void
jit_init_size(void)
{
#if DEBUG
# if !GET_JIT_SIZE
jit_word_t offset;
for (offset = 0; offset < jit_size(_szs); offset++)
if (_szs[offset] != 0)
return;
/* Ensure data was collected */
abort();
# endif
#endif
}
#if GET_JIT_SIZE
void
_jit_size_prepare(jit_state_t *_jit)
{
_jitc->cptr = _jit->code.ptr;
_jitc->size = _jit->pc.w;
}
void
_jit_size_collect(jit_state_t *_jit, jit_node_t *node)
{
jit_word_t length;
if (_jitc->cptr == _jit->code.ptr) {
length = _jit->pc.w - _jitc->size;
if (_szs[node->code] < length)
_szs[node->code] = length;
}
}
#else
jit_word_t
_jit_get_size(jit_state_t *_jit)
{
jit_word_t size;
jit_node_t *node;
# if __riscv && __WORDSIZE == 64
jit_word_t extra = 0;
# endif
for (size = JIT_INSTR_MAX, node = _jitc->head; node; node = node->next) {
# if __riscv && __WORDSIZE == 64
/* Get estimative of extra memory for constants at end of code. */
switch (node->code) {
case jit_code_movi:
case jit_code_movi_f:
case jit_code_movi_d:
case jit_code_jmpi:
case jit_code_calli:
extra += sizeof(jit_word_t);
default:
break;
}
# endif
switch (node->code) {
/* The instructions are special because they can be arbitrarily long. */
case jit_code_align:
case jit_code_skip:
size += node->u.w;
break;
default:
size += _szs[node->code];
}
}
# if __riscv && __WORDSIZE == 64
/* Heuristically only 20% of constants are unique. */
size += extra / 5;
# endif
return size;
}
#endif
jit_word_t
jit_get_max_instr(void)
{
return (JIT_INSTR_MAX >= 144 ? JIT_INSTR_MAX : 144);
}
void
jit_finish_size(void)
{
#if GET_JIT_SIZE
FILE *fp;
int offset;
/* Define a single path */
fp = fopen(JIT_SIZE_PATH, "a");
assert(fp);
for (offset = 0; offset < jit_size(_szs); offset++)
fprintf(fp, "%d %d\n", offset, _szs[offset]);
fclose(fp);
#endif
}
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
+5 -16
View File
@@ -1,15 +1,4 @@
/build-aux
+*
*.o
*.lo
*.la
.libs/
.deps/
*/.libs/
*/.deps/
autom4te.cache
aclocal.m4
depcomp
@@ -31,14 +20,14 @@ missing
size
stamp-h1
test-driver
check/.deps
doc/.deps
lib/.deps
m4/libtool.m4
m4/lt~obsolete.m4
m4/ltoptions.m4
m4/ltsugar.m4
m4/ltversion.m4
doc/mdate-sh
doc/texinfo.tex
lightning.pc
include/lightning.h
build-aux/
+12
View File
@@ -0,0 +1,12 @@
; DO NOT EDIT (unless you know what you are doing)
;
; This subdirectory is a git "subrepo", and this file is maintained by the
; git-subrepo command. See https://github.com/git-commands/git-subrepo#readme
;
[subrepo]
remote = https://git.savannah.gnu.org/git/lightning.git
branch = master
commit = b0b8eb5e856c0d29053dc842e1919a2eb58c8cda
parent = 9f797430963d9cf0fcef7d963466f9cac7026de2
method = merge
cmdver = 0.4.1
+13 -74
View File
@@ -1,64 +1,3 @@
2022-08-12 Marc Nieper-Wißkirchen <marc@nieper-wisskirchen.de>
Document jit_align.
* doc/body.texi: Add documentation for jit_align.
2022-05-14 Paulo Andrade <pcpa@gnu.org>
* include/lightning.h.in: Reorder jit_mov{n,z}r in instruction list.
* lib/jit_alpha.c, lib/jit_alpha-cpu.c, lib/jit_hppa.c,
lib/jit_hppa-cpu.c, lib/jit_ia64.c, lib/jit_ia64-cpu.c,
lib/jit_riscv.c, lib/jit_riscv-cpu.c, lib/jit_s390.c,
lib/jit_s390-cpu.c, lib/jit_sparc.c, lib/jit_sparc-cpu.c:
Implement fallback jit_mov{n,z}r. These are a somewhat cheap
implementation, but should be reviewed for the arches that already
have a proper conditional move.
* lib/jit_arm-sz.c, lib/jit_mips-sz.c: Add missing maximum size
estimative and reorder.
* lib/jit_aarch64-sz.c, lib/jit_x86-sz.c, lib/jit_ppc-sz.c:
Reorder entry to match definition order.
* lib/jit_aarch64-sz.c, lib/jit_alpha-sz.c, lib/jit_hppa-sz.c,
lib/jit_ia64-sz.c, lib/jit_riscv-sz.c, lib/jit_s390-sz.c,
lib/jit_sparc-sz.c: Add heuristic value, basically the sum of
the cost of a movr + beqr.
* lib/jit_names.c: Add entries for debug output of mov{n,z}r.
* lib/lightning.c: Use proper bitmask in jit_classify.
2021-04-03 Marc Nieper-Wißkirchen <marc@nieper-wisskirchen.de>
* check/Makefile.am: Add test for the live instruction.
* check/live.ok: New file.
* check/live.tst: New file.
* doc/body.texi: Add documentation for the live instruction and
for jit_get_reg/jit_get_unreg. Fix menu entries.
* include/lightning.h.in (jit_get_reg, jit_unget_reg): Expose the
macros in the public header file.
* include/lightning/jit_private.h (jit_get_reg, jit_unget_reg):
Remove the macros from the private header file.
2021-04-03 Marc Nieper-Wißkirchen <marc@nieper-wisskirchen.de>
* Makefile.am, check/Makefile.am, doc/Makefile.am,
lib/Makefile.am: Include $(top_builddir)/include in include paths
for the autoconf-generated header file lightning.h.
2021-04-03 Marc Nieper-Wißkirchen <marc@nieper-wisskirchen.de>
* doc/.gitignore: Add version.texi to list of ignored files.
* doc/version.texi: Remove file from version control.
2020-18-04 Paulo Andrade <pcpa@gnu.org>
* lib/jit_x86-cpu.c, lib/jit_x86.c: Implement %rip relative
calls and jumps on x86_64. Currently very conservative, assuming
a jit block can be larger than 2G, so, if a jump or call is in
the same jit generation, but target is unknown, use an indirect
branch (could have an option to assume a jit code block is
never larger than 2G). Also a deoptimization is that now does
not always generate ip relative jmpi; previously implicitly
assumed jmpi would never be larger than 2G. Overall still an
optimization.
2020-23-01 Paulo Andrade <pcpa@gnu.org>
* lib/lightning.c: Add a proper fix to the condition of considering
@@ -87,7 +26,7 @@
to the set of registers to scan for live range, what might
consume a lot of cpu time, doing nothing.
2019-09-16 Marc Nieper-Wißkirchen <marc@nieper-wisskirchen.de>
2019-09-16 Marc Nieper-WiÃkirchen <marc@nieper-wisskirchen.de>
* include/lightning/jit_x86.h, lib/jit_x86.c: Correct x86_64
backend, made %r12 a callee-save register as dictated by the
@@ -126,7 +65,7 @@
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=925129
* THANKS: update.
2019-08-29 Marc Nieper-Wißkirchen <marc@nieper-wisskirchen.de>
2019-08-29 Marc Nieper-WiÃkirchen <marc@nieper-wisskirchen.de>
* include/lightning/jit_private.h: Move definition of offsetof
from the public header file here.
@@ -1476,7 +1415,7 @@
* include/lightning/jit_arm.h: Correct wrong jit_f macro
definition.
* include/lightning/jit_ia64.h, include/lightning/jit_ppc.h:
* include/lightning/jit_ia64.h, include/lightning/jit_ppc.h:
Correct wrong jit_r macro definition.
* lib/jit_x86-x87.c, lib/jit_x86.c: Actually use the
@@ -1945,7 +1884,7 @@
divr_f and divrd_d implementation.
* check/lightning.c: Add __ia64__ preprocessor define
on Itanium.
on Itanium.
* check/alu.inc, check/clobber.tst, check/float.tst: Define
several macros conditionally to __ia64__. This is required
@@ -3052,7 +2991,7 @@
* include/lightning/jit_x86.h: Correct typo in macro name.
* lib/jit_arm.c, lib/jit_arm-cpu.c, lib/jit_mips.c,
lib/jit_mips-cpu.c, lib/jit_ppc.c, lib/jit_ppc-cpu.c,
lib/jit_mips-cpu.c, lib/jit_ppc.c, lib/jit_ppc-cpu.c,
lib/jit_x86.c, lib/jit_x86-cpu.c: Correct wrong code to get
current jit function pointer.
@@ -3286,7 +3225,7 @@
* lightning/i386/core.h (jit_ldr_c, jit_ldxr_c, jit_ldr_s,
jit_ldxr_s): Move...
* lightning/i386/core-32.h: ... here.
* lightning/i386/core-64.h (jit_ldr_c, jit_ldxr_c, jit_ldr_s):
* lightning/i386/core-64.h (jit_ldr_c, jit_ldxr_c, jit_ldr_s,
Use movsbq and movswq.
2010-08-10 Paulo César Pereira de Andrade <pcpa@mandriva.com.br>
@@ -3367,11 +3306,11 @@
* lightning/ppc/funcs.h (jit_flush_code): modified the computation
of start/end. The pointer arithmetic was done without casting. It
prevented compilation with recent gcc versions.
prevented compilation with recent gcc versions.
* lightning/ppc/core.h (jit_pushr_i): The offset for the store was
incorrect. Should have been 4 bytes below SP (not above).
* lightning/ppc/core.h (jit_popr_i): The offset for the load was
incorrect. Should have been 0 (not +8).
* lightning/ppc/core.h (jit_popr_i): The offset for the load was
incorrect. Should have been 0 (not +8).
2008-06-17 Paolo Bonzini <bonzini@gnu.org>
@@ -3650,7 +3589,7 @@
* lightning/i386/fp-32.h: ... here.
* lightning/i386/fp-64.h: Write the code.
* lightning/sparc/fp.h: Fix jit_extr_{f_d,d_f} register order.
2006-11-22 Paolo Bonzini <bonzini@gnu.org>
* lightning/i386/asm-i386.h: Move x86-64 instructions...
@@ -3864,7 +3803,7 @@
2006-01-23 Paolo Bonzini <bonzini@gnu.org>
* configure.ac: Fix comments in config.h.in.
2005-11-25 Paolo Bonzini <bonzini@gnu.org>
* lightning/sparc/fp.h: Fix header comment.
@@ -4184,7 +4123,7 @@
* lightning/ppc/funcs.h: correctly align stack pointer
No changelogs for the assemblers (lightning directory) until 1.0
2003-03-27 Paolo Bonzini <bonzini@gnu.org>
* tests/printf2.c: new test
@@ -4196,7 +4135,7 @@ No changelogs for the assemblers (lightning directory) until 1.0
2001-01-19 Paolo Bonzini <bonzini@gnu.org>
* configure.in: support cross-assembling
* disass/bfd.h, disass/dis-asm.h, disass/dis-buf.c,
disass/i386-dis.c, disass/i386.h, disass/ppc-dis.c,
disass/ppc.h, disass/ppc-opc.c, disass/sparc-dis.c,
+1 -5
View File
@@ -17,22 +17,18 @@
ACLOCAL_AMFLAGS = -I m4
SUBDIRS = \
gnulib-lib \
check \
doc \
include \
lib
EXTRA_DIST = m4/gnulib-cache.m4
pkgconfiglibdir = $(libdir)/pkgconfig
pkgconfiglib_DATA = lightning.pc
if get_jit_size
JIT_SIZE_PATH = "$(top_builddir)/jit_$(cpu)-sz.c"
AM_CPPFLAGS=-DGET_JIT_SIZE=1 -DJIT_SIZE_PATH='$(JIT_SIZE_PATH)'
AM_CFLAGS = -I$(top_builddir)/include -I$(top_srcdir)/include \
-D_GNU_SOURCE $(LIGHTNING_CFLAGS)
AM_CFLAGS = -I$(top_srcdir)/include -D_GNU_SOURCE $(LIGHTNING_CFLAGS)
noinst_PROGRAMS = size
size_LDADD = $(top_builddir)/lib/liblightning.la -lm $(SHLIB)
-2
View File
@@ -1,5 +1,3 @@
GNU lightning is a library to aid in making portable programs
that compile assembly code at run time. For more information,
look at the info documentation.
For help building lightning, see README-hacking.
+22
View File
@@ -0,0 +1,22 @@
0
1
1
1
0
1
1
1
0
1
1
0
1
1
1
0
1
1
1
0
1
1
+118
View File
@@ -0,0 +1,118 @@
.data 32
dfmt:
.c "%1.0f\n"
ifmt:
.c "%d\n"
.code
jmpi main
#define def_test_double(a, b, c) \
name test_double_##a##_##b##_##c \
test_double_##a##_##b##_##c: \
prolog \
arg_d $d0 \
arg_d $d1 \
getarg_d %b $d0 \
getarg_d %c $d1 \
subr_d %a %b %c \
retr_d %a \
epilog
#define test_double(a, b, c, x, y) \
prepare \
pushargi_d x \
pushargi_d y \
finishi test_double_##a##_##b##_##c \
retval_d %f0 \
prepare \
pushargi dfmt \
ellipsis \
pushargr_d %f0 \
finishi @printf
#define def_test_int(a, b, c) \
name test_int_##a##_##b##_##c \
test_int_##a##_##b##_##c: \
prolog \
arg $i0 \
arg $i1 \
getarg %b $i0 \
getarg %c $i1 \
subr %a %b %c \
retr %a \
epilog
#define test_int(a, b, c, x, y) \
prepare \
pushargi x \
pushargi y \
finishi test_int_##a##_##b##_##c \
retval %r0 \
prepare \
pushargi ifmt \
ellipsis \
pushargr %r0 \
finishi @printf
def_test_double(f0, f0, f0)
def_test_double(f0, f0, f1)
def_test_double(f0, f1, f0)
def_test_double(f0, f1, f2)
def_test_double(f3, f3, f3)
def_test_double(f3, f3, f1)
def_test_double(f3, f1, f3)
def_test_double(f3, f1, f2)
def_test_double(f3, f0, f0)
def_test_double(f3, f0, f3)
def_test_double(f3, f3, f0)
def_test_int(r0, r0, r0)
def_test_int(r0, r0, r1)
def_test_int(r0, r1, r0)
def_test_int(r0, r1, r2)
def_test_int(v0, v0, v0)
def_test_int(v0, v0, r1)
def_test_int(v0, r1, v0)
def_test_int(v0, r1, r2)
def_test_int(v0, r0, r0)
def_test_int(v0, r0, v0)
def_test_int(v0, v0, r0)
name main
main:
prolog
test_double(f0, f0, f0, 3.0, 2.0)
test_double(f0, f0, f1, 3.0, 2.0)
test_double(f0, f1, f0, 3.0, 2.0)
test_double(f0, f1, f2, 3.0, 2.0)
test_double(f3, f3, f3, 3.0, 2.0)
test_double(f3, f3, f1, 3.0, 2.0)
test_double(f3, f1, f3, 3.0, 2.0)
test_double(f3, f1, f2, 3.0, 2.0)
test_double(f3, f0, f0, 3.0, 2.0)
test_double(f3, f0, f3, 3.0, 2.0)
test_double(f3, f3, f0, 3.0, 2.0)
test_int(r0, r0, r0, 3, 2)
test_int(r0, r0, r1, 3, 2)
test_int(r0, r1, r0, 3, 2)
test_int(r0, r1, r2, 3, 2)
test_int(v0, v0, v0, 3, 2)
test_int(v0, v0, r1, 3, 2)
test_int(v0, r1, v0, 3, 2)
test_int(v0, r1, r2, 3, 2)
test_int(v0, r0, r0, 3, 2)
test_int(v0, r0, v0, 3, 2)
test_int(v0, v0, r0, 3, 2)
ret
epilog
+318
View File
@@ -0,0 +1,318 @@
#
# Copyright 2012-2019 Free Software Foundation, Inc.
#
# This file is part of GNU lightning.
#
# GNU lightning is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 3, or (at your option)
# any later version.
#
# GNU lightning is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
# License for more details.
#
AM_CFLAGS = -I$(top_srcdir)/include -D_GNU_SOURCE
check_PROGRAMS = lightning ccall self setcode nodata ctramp carg cva_list
lightning_LDADD = $(top_builddir)/lib/liblightning.la -lm $(SHLIB)
lightning_SOURCES = lightning.c
ccall_LDADD = $(top_builddir)/lib/liblightning.la -lm $(SHLIB)
ccall_SOURCES = ccall.c
self_LDADD = $(top_builddir)/lib/liblightning.la -lm $(SHLIB)
self_SOURCES = self.c
setcode_LDADD = $(top_builddir)/lib/liblightning.la -lm $(SHLIB)
setcode_SOURCES = setcode.c
nodata_LDADD = $(top_builddir)/lib/liblightning.la -lm $(SHLIB)
nodata_SOURCES = nodata.c
ctramp_LDADD = $(top_builddir)/lib/liblightning.la -lm $(SHLIB)
ctramp_SOURCES = ctramp.c
carg_LDADD = $(top_builddir)/lib/liblightning.la -lm $(SHLIB)
carg_SOURCES = carg.c
cva_list_LDADD = $(top_builddir)/lib/liblightning.la -lm $(SHLIB)
cva_list_SOURCES = cva_list.c
$(top_builddir)/lib/liblightning.la:
cd $(top_builddir)/lib; $(MAKE) $(AM_MAKEFLAGS) liblightning.la
EXTRA_DIST = \
3to2.tst 3to2.ok \
add.tst add.ok \
align.tst align.ok \
allocai.tst allocai.ok \
allocar.tst allocar.ok \
bp.tst bp.ok \
divi.tst divi.ok \
fib.tst fib.ok \
rpn.tst rpn.ok \
ldst.inc \
ldstr.tst ldstr.ok \
ldsti.tst ldsti.ok \
ldstxr.tst ldstxr.ok \
ldstxi.tst ldstxi.ok \
ldstr-c.tst ldstr-c.ok \
ldstxr-c.tst ldstxr-c.ok \
ldstxi-c.tst ldstxi-c.ok \
cvt.tst cvt.ok \
hton.tst hton.ok \
branch.tst branch.ok \
alu.inc \
alu_add.tst alu_add.ok \
alux_add.tst alux_add.ok \
alu_sub.tst alu_sub.ok \
alux_sub.tst alux_sub.ok \
alu_rsb.tst alu_rsb.ok \
alu_mul.tst alu_mul.ok \
alu_div.tst alu_div.ok \
alu_rem.tst alu_rem.ok \
alu_and.tst alu_and.ok \
alu_or.tst alu_or.ok \
alu_xor.tst alu_xor.ok \
alu_lsh.tst alu_lsh.ok \
alu_rsh.tst alu_rsh.ok \
alu_com.tst alu_com.ok \
alu_neg.tst alu_neg.ok \
fop_abs.tst fop_abs.ok \
fop_sqrt.tst fop_sqrt.ok \
varargs.tst varargs.ok \
stack.tst stack.ok \
clobber.tst clobber.ok \
carry.tst carry.ok \
call.tst call.ok \
float.tst float.ok \
jmpr.tst jmpr.ok \
put.tst put.ok \
qalu.inc \
qalu_mul.tst qalu_mul.ok \
qalu_div.tst qalu_div.ok \
range.tst range.ok \
ranger.tst ranger.ok \
ret.tst ret.ok \
tramp.tst tramp.ok \
va_list.tst va_list.ok \
check.sh \
check.x87.sh \
check.arm.sh check.swf.sh \
check.arm.swf.sh \
check.arm4.swf.sh \
check.nodata.sh \
check.x87.nodata.sh \
run-test all.tst
base_TESTS = \
3to2 add align allocai \
allocar bp divi fib rpn \
ldstr ldsti \
ldstxr ldstxi \
ldstr-c ldstxr-c ldstxi-c \
cvt hton branch \
alu_add alux_add \
alu_sub alux_sub alu_rsb \
alu_mul alu_div alu_rem \
alu_and alu_or alu_xor \
alu_lsh alu_rsh \
alu_com alu_neg \
fop_abs fop_sqrt \
varargs stack \
clobber carry call \
float jmpr put \
qalu_mul qalu_div \
range ranger ret tramp \
va_list
$(base_TESTS): check.sh
$(LN_S) $(srcdir)/check.sh $@
TESTS = $(base_TESTS)
if test_x86_x87
#x87_TESTS = $(addsuffix .x87, $(base_TESTS))
x87_TESTS = \
3to2.x87 add.x87 allocai.x87 \
allocar.x87 bp.x87 divi.x87 fib.x87 \
rpn.x87 ldstr.x87 ldsti.x87 \
ldstxr.x87 ldstxi.x87 \
ldstr-c.x87 ldstxr-c.x87 ldstxi-c.x87 \
cvt.x87 branch.x87 \
alu_add.x87 alux_add.x87 \
alu_sub.x87 alux_sub.x87 alu_rsb.x87 \
alu_mul.x87 alu_div.x87 alu_rem.x87 \
alu_and.x87 alu_or.x87 alu_xor.x87 \
alu_lsh.x87 alu_rsh.x87 \
alu_com.x87 alu_neg.x87 \
fop_abs.x87 fop_sqrt.x87 \
varargs.x87 stack.x87 \
clobber.x87 carry.x87 call.x87 \
float.x87 jmpr.x87 put.x87 \
va_list.x87
$(x87_TESTS): check.x87.sh
$(LN_S) $(srcdir)/check.x87.sh $@
TESTS += $(x87_TESTS)
#x87_nodata_TESTS = $(addsuffix .x87.nodata, $(base_TESTS))
x87_nodata_TESTS = \
3to2.x87.nodata add.x87.nodata allocai.x87.nodata \
allocar.x87.nodata bp.x87.nodata divi.x87.nodata fib.x87.nodata \
rpn.x87.nodata ldstr.x87.nodata ldsti.x87.nodata \
ldstxr.x87.nodata ldstxi.x87.nodata \
ldstr-c.x87.nodata ldstxr-c.x87.nodata ldstxi-c.x87.nodata \
cvt.x87.nodata branch.x87.nodata \
alu_add.x87.nodata alux_add.x87.nodata \
alu_sub.x87.nodata alux_sub.x87.nodata alu_rsb.x87.nodata \
alu_mul.x87.nodata alu_div.x87.nodata alu_rem.x87.nodata \
alu_and.x87.nodata alu_or.x87.nodata alu_xor.x87.nodata \
alu_lsh.x87.nodata alu_rsh.x87.nodata \
alu_com.x87.nodata alu_neg.x87.nodata \
fop_abs.x87.nodata fop_sqrt.x87.nodata \
varargs.x87.nodata stack.x87.nodata \
clobber.x87.nodata carry.x87.nodata call.x87.nodata \
float.x87.nodata jmpr.x87.nodata put.x87.nodata \
va_list.x87.nodata
$(x87_nodata_TESTS): check.x87.nodata.sh
$(LN_S) $(srcdir)/check.x87.nodata.sh $@
TESTS += $(x87_nodata_TESTS)
endif
if test_arm_arm
#arm_TESTS = $(addsuffix .arm, $(base_TESTS))
arm_TESTS = \
3to2.arm add.arm align.arm allocai.arm \
allocar.arm bp.arm divi.arm fib.arm \
rpn.arm ldstr.arm ldsti.arm \
ldstxr.arm ldstxi.arm \
ldstr-c.arm ldstxr-c.arm ldstxi-c.arm \
cvt.arm hton.arm branch.arm \
alu_add.arm alux_add.arm \
alu_sub.arm alux_sub.arm alu_rsb.arm \
alu_mul.arm alu_div.arm alu_rem.arm \
alu_and.arm alu_or.arm alu_xor.arm \
alu_lsh.arm alu_rsh.arm \
alu_com.arm alu_neg.arm \
fop_abs.arm fop_sqrt.arm \
varargs.arm stack.arm \
clobber.arm carry.arm call.arm \
float.arm jmpr.arm tramp.arm range.arm \
ranger.arm put.arm va_list.arm
$(arm_TESTS): check.arm.sh
$(LN_S) $(srcdir)/check.arm.sh $@
TESTS += $(arm_TESTS)
endif
if test_arm_swf
#swf_TESTS = $(addsuffix .swf, $(base_TESTS))
swf_TESTS = \
3to2.swf add.swf allocai.swf \
allocar.swf bp.swf divi.swf fib.swf \
rpn.swf ldstr.swf ldsti.swf \
ldstxr.swf ldstxi.swf \
ldstr-c.swf ldstxr-c.swf ldstxi-c.swf \
cvt.swf hton.swf branch.swf \
alu_add.swf alux_add.swf \
alu_sub.swf alux_sub.swf alu_rsb.swf \
alu_mul.swf alu_div.swf alu_rem.swf \
alu_and.swf alu_or.swf alu_xor.swf \
alu_lsh.swf alu_rsh.swf \
alu_com.swf alu_neg.swf \
fop_abs.swf fop_sqrt.swf \
varargs.swf stack.swf \
clobber.swf carry.swf call.swf \
float.swf jmpr.swf tramp.swf range.swf \
ranger.swf put.swf va_list.swf
$(swf_TESTS): check.swf.sh
$(LN_S) $(srcdir)/check.swf.sh $@
TESTS += $(swf_TESTS)
if test_arm_arm
#arm_swf_TESTS = $(addsuffix .arm.swf, $(base_TESTS))
arm_swf_TESTS = \
3to2.arm.swf add.arm.swf allocai.arm.swf \
allocar.arm.swf bp.arm.swf divi.arm.swf fib.arm.swf \
rpn.arm.swf ldstr.arm.swf ldsti.arm.swf \
ldstxr.arm.swf ldstxi.arm.swf \
ldstr-c.arm.swf ldstxr-c.arm.swf ldstxi-c.arm.swf \
cvt.arm.swf hton.arm.swf branch.arm.swf \
alu_add.arm.swf alux_add.arm.swf \
alu_sub.arm.swf alux_sub.arm.swf alu_rsb.arm.swf \
alu_mul.arm.swf alu_div.arm.swf alu_rem.arm.swf \
alu_and.arm.swf alu_or.arm.swf alu_xor.arm.swf \
alu_lsh.arm.swf alu_rsh.arm.swf \
alu_com.arm.swf alu_neg.arm.swf \
fop_abs.arm.swf fop_sqrt.arm.swf \
varargs.arm.swf stack.arm.swf \
clobber.arm.swf carry.arm.swf call.arm.swf \
float.arm.swf jmpr.arm.swf tramp.arm.swf range.arm.swf \
ranger.arm.swf put.arm.swf va_list.arm.swf
$(arm_swf_TESTS): check.arm.swf.sh
$(LN_S) $(srcdir)/check.arm.swf.sh $@
TESTS += $(arm_swf_TESTS)
endif
if test_arm_arm
#arm4_swf_TESTS = $(addsuffix .arm4.swf, $(base_TESTS))
arm4_swf_TESTS = \
3to2.arm4.swf add.arm4.swf allocai.arm4.swf \
allocar.arm4.swf bp.arm4.swf divi.arm4.swf fib.arm4.swf \
rpn.arm4.swf ldstr.arm4.swf ldsti.arm4.swf \
ldstxr.arm4.swf ldstxi.arm4.swf \
ldstr-c.arm4.swf ldstxr-c.arm4.swf ldstxi-c.arm4.swf \
cvt.arm4.swf hton.arm4.swf branch.arm4.swf \
alu_add.arm4.swf alux_add.arm4.swf \
alu_sub.arm4.swf alux_sub.arm4.swf alu_rsb.arm4.swf \
alu_mul.arm4.swf alu_div.arm4.swf alu_rem.arm4.swf \
alu_and.arm4.swf alu_or.arm4.swf alu_xor.arm4.swf \
alu_lsh.arm4.swf alu_rsh.arm4.swf \
alu_com.arm4.swf alu_neg.arm4.swf \
fop_abs.arm4.swf fop_sqrt.arm4.swf \
varargs.arm4.swf stack.arm4.swf \
clobber.arm4.swf carry.arm4.swf call.arm4.swf \
float.arm4.swf jmpr.arm4.swf tramp.arm4.swf \
range.arm4.swf ranger.arm4.swf put.arm4.swf \
va_list.arm4.swf
$(arm4_swf_TESTS): check.arm4.swf.sh
$(LN_S) $(srcdir)/check.arm4.swf.sh $@
TESTS += $(arm4_swf_TESTS)
endif
endif
if test_nodata
#nodata_TESTS = $(addsuffix .nodata, $(base_TESTS))
nodata_TESTS = \
3to2.nodata add.nodata allocai.nodata \
allocar.nodata bp.nodata divi.nodata fib.nodata \
rpn.nodata ldstr.nodata ldsti.nodata \
ldstxr.nodata ldstxi.nodata \
ldstr-c.nodata ldstxr-c.nodata ldstxi-c.nodata \
cvt.nodata branch.nodata \
alu_add.nodata alux_add.nodata \
alu_sub.nodata alux_sub.nodata alu_rsb.nodata \
alu_mul.nodata alu_div.nodata alu_rem.nodata \
alu_and.nodata alu_or.nodata alu_xor.nodata \
alu_lsh.nodata alu_rsh.nodata \
alu_com.nodata alu_neg.nodata \
fop_abs.nodata fop_sqrt.nodata \
varargs.nodata stack.nodata \
clobber.nodata carry.nodata call.nodata \
float.nodata jmpr.nodata tramp.nodata \
range.nodata ranger.nodata put.nodata \
va_list.nodata
$(nodata_TESTS): check.nodata.sh
$(LN_S) $(srcdir)/check.nodata.sh $@
TESTS += $(nodata_TESTS)
endif
TESTS += ccall self setcode nodata ctramp carg cva_list
CLEANFILES = $(TESTS)
#TESTS_ENVIRONMENT=$(srcdir)/run-test;
debug: lightning
$(LIBTOOL) --mode=execute gdb lightning
+1
View File
@@ -0,0 +1 @@
5 + 4 = 9
Loaded 100 of 279 files, more files were not shown because too many files have changed in this diff. Show more