diff --git a/lib/luajit/.travis.yml b/lib/luajit/.travis.yml index f1f11bbc22..c6fcc550fc 100644 --- a/lib/luajit/.travis.yml +++ b/lib/luajit/.travis.yml @@ -5,4 +5,6 @@ script: - nix-build -A test-O2 - nix-build -A test-O1 - nix-build -A test-nojit + - nix-build -A test-capi + - nix-build -A test-libraptorjit - nix-build -A check-generated-code --arg check true diff --git a/lib/luajit/COPYRIGHT b/lib/luajit/COPYRIGHT index 17a037c14e..58b5b96e68 100644 --- a/lib/luajit/COPYRIGHT +++ b/lib/luajit/COPYRIGHT @@ -6,9 +6,9 @@ Copyright is retained by the individual authors and contributors. [ RaptorJIT includes code from LuaJIT 2.1 which has the following statements: ] =============================================================================== -LuaJIT -- a Just-In-Time Compiler for Lua. http://luajit.org/ +LuaJIT -- a Just-In-Time Compiler for Lua. https://luajit.org/ -Copyright (C) 2005-2017 Mike Pall. All rights reserved. +Copyright (C) 2005-2022 Mike Pall. All rights reserved. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -28,7 +28,7 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -[ MIT license: http://www.opensource.org/licenses/mit-license.php ] +[ MIT license: https://www.opensource.org/licenses/mit-license.php ] =============================================================================== [ LuaJIT includes code from Lua 5.1/5.2, which has this license statement: ] @@ -58,6 +58,6 @@ THE SOFTWARE. This is a version (aka dlmalloc) of malloc/free/realloc written by Doug Lea and released to the public domain, as explained at -http://creativecommons.org/licenses/publicdomain +https://creativecommons.org/licenses/publicdomain =============================================================================== diff --git a/lib/luajit/Makefile b/lib/luajit/Makefile index 277bfa3a90..9d38e99bf0 100644 --- a/lib/luajit/Makefile +++ b/lib/luajit/Makefile @@ -10,7 +10,7 @@ # For MSVC, please follow the instructions given in src/msvcbuild.bat. # For MinGW and Cygwin, cd to src and run make with the Makefile there. # -# Copyright (C) 2005-2017 Mike Pall. See Copyright Notice in luajit.h +# Copyright (C) 2005-2022 Mike Pall. See Copyright Notice in luajit.h ############################################################################## MAJVER= 1 @@ -33,10 +33,12 @@ DPREFIX= $(DESTDIR)$(PREFIX) INSTALL_BIN= $(DPREFIX)/bin INSTALL_LIB= $(DPREFIX)/$(MULTILIB) INSTALL_SHARE= $(DPREFIX)/share -INSTALL_INC= $(DPREFIX)/include/raptorjit-$(MAJVER).$(MINVER) +INSTALL_DEFINC= $(DPREFIX)/include/raptorjit-$(MAJVER).$(MINVER) +INSTALL_INC= $(INSTALL_DEFINC) INSTALL_LJLIBD= $(INSTALL_SHARE)/raptorjit-$(VERSION) INSTALL_JITLIB= $(INSTALL_LJLIBD)/jit +INSTALL_PKGCONFIG= $(INSTALL_LIB)/pkgconfig INSTALL_TNAME= raptorjit-$(VERSION) INSTALL_TSYMNAME= raptorjit @@ -47,6 +49,7 @@ INSTALL_SONAME= $(INSTALL_SOSHORT2).$(MINVER).$(RELVER) INSTALL_DYLIBSHORT1= libraptorjit-$(ABIVER).dylib INSTALL_DYLIBSHORT2= libraptorjit-$(ABIVER).$(MAJVER).dylib INSTALL_DYLIBNAME= libraptorjit-$(ABIVER).$(MAJVER).$(MINVER).$(RELVER).dylib +INSTALL_PCNAME= raptorjit.pc INSTALL_STATIC= $(INSTALL_LIB)/$(INSTALL_ANAME) INSTALL_DYN= $(INSTALL_LIB)/$(INSTALL_SONAME) @@ -66,11 +69,17 @@ SYMLINK= ln -sf INSTALL_X= install -m 0755 INSTALL_F= install -m 0644 UNINSTALL= $(RM) -LDCONFIG= ldconfig -n +LDCONFIG= ldconfig -n 2>/dev/null +SED_PC= sed -e "s|^prefix=.*|prefix=$(PREFIX)|" \ + -e "s|^multilib=.*|multilib=$(MULTILIB)|" +ifneq ($(INSTALL_DEFINC),$(INSTALL_INC)) + SED_PC+= -e "s|^includedir=.*|includedir=$(INSTALL_INC)|" +endif FILE_T= raptorjit FILE_A= libraptorjit.a FILE_SO= libraptorjit.so +FILE_PC= raptorjit.pc FILES_INC= lua.h lualib.h lauxlib.h luaconf.h lua.hpp luajit.h FILES_JITLIB= bc.lua bcsave.lua vmdef.lua @@ -108,9 +117,12 @@ install: $(INSTALL_DEP) $(RM) $(INSTALL_DYN) $(INSTALL_SHORT1) $(INSTALL_SHORT2) cd src && test -f $(FILE_SO) && \ $(INSTALL_X) $(FILE_SO) $(INSTALL_DYN) && \ - $(LDCONFIG) $(INSTALL_LIB) && \ + ( $(LDCONFIG) $(INSTALL_LIB) || : ) && \ $(SYMLINK) $(INSTALL_SONAME) $(INSTALL_SHORT1) && \ $(SYMLINK) $(INSTALL_SONAME) $(INSTALL_SHORT2) || : + cd etc && $(SED_PC) $(FILE_PC) > $(FILE_PC).tmp && \ + $(INSTALL_F) -D $(FILE_PC).tmp $(INSTALL_PC) && \ + $(RM) $(FILE_PC).tmp cd src && $(INSTALL_F) $(FILES_INC) $(INSTALL_INC) cd src/jit && $(INSTALL_F) $(FILES_JITLIB) $(INSTALL_JITLIB) $(SYMLINK) $(INSTALL_TNAME) $(INSTALL_TSYM) diff --git a/lib/luajit/PROFESSIONAL-SUPPORT.md b/lib/luajit/PROFESSIONAL-SUPPORT.md new file mode 100644 index 0000000000..30dcd0bccf --- /dev/null +++ b/lib/luajit/PROFESSIONAL-SUPPORT.md @@ -0,0 +1,10 @@ +Professional support is available to help you use RaptorJIT +successfully. You can contact the parties listed below if you need +help to design your application; to understand the compiler and the +tools; to fix bugs and optimize code; to maintain a port to a new +platform; etc. + +Links in alphabetical order with one-sentence summaries: + +- [Snabb Solutions](https://snabb.solutions/) offers consulting and standard support agreements for RaptorJIT and related projects. + diff --git a/lib/luajit/README.md b/lib/luajit/README.md index db0bbe1d9f..d7b0247db5 100644 --- a/lib/luajit/README.md +++ b/lib/luajit/README.md @@ -27,7 +27,7 @@ The most notable technical changes since forking LuaJIT are: support, 32-bit heap support, and non-x86 backends. This is a necessary short-term expedient to make the code maintainable while we bootstrap the project. -- Compiler heursitics tightened to reduce the risk of bytecode +- Compiler heuristics tightened to reduce the risk of bytecode blacklisting causing catastrophic performance drops. - Started using `git merge` to accept contributions of both code and development history from other forks. @@ -173,7 +173,7 @@ These are the authoritative optimization resources for processors supported by RaptorJIT. If you are confused by references to CPU details in discussions then these are the places to look for answers. -- [Computer Architecture: A Quantitiave Approach](https://www.amazon.com/Computer-Architecture-Fifth-Quantitative-Approach/dp/012383872X) by Hennessy and Patterson. +- [Computer Architecture: A Quantitative Approach](https://www.amazon.com/Computer-Architecture-Fifth-Quantitative-Approach/dp/012383872X) by Hennessy and Patterson. - [Intel Architectures Optimization Reference Manual](http://www.intel.com/content/www/us/en/architecture-and-technology/64-ia-32-architectures-optimization-manual.html). - Agner Fog's [software optimization resources](http://www.agner.org/optimize/): - [Instruction latency and throughput tables](http://www.agner.org/optimize/instruction_tables.pdf). @@ -191,7 +191,7 @@ Here are some borrowed words to put this branch into context: > Optimal code is not optimal to maintain. _[Vyacheslav Egorov](https://www.youtube.com/watch?v=EaLboOUG9VQ)_ -> If a programmer is indispensible, get rid of him as quickly as possible. _[Gerald M. Weinberg](https://www.amazon.com/Psychology-Computer-Programming-Silver-Anniversary/dp/0932633420)_ +> If a programmer is indispensable, get rid of him as quickly as possible. _[Gerald M. Weinberg](https://www.amazon.com/Psychology-Computer-Programming-Silver-Anniversary/dp/0932633420)_ > If a system is to serve the creative spirit, it > must be entirely comprehensible to a single individual. _[Dan diff --git a/lib/luajit/default.nix b/lib/luajit/default.nix index d7e52f1290..5bf90a8d05 100644 --- a/lib/luajit/default.nix +++ b/lib/luajit/default.nix @@ -18,6 +18,8 @@ let raptorjit-assert = raptorjit.overrideAttrs( old: { NIX_CFLAGS_COMPILE = " -DLUA_USE_ASSERT"; }); test = name: args: (callPackage ./test.nix { inherit name args; raptorjit = raptorjit-assert; }); + test-capi = callPackage ./test-capi.nix { inherit pkgs raptorjit; }; + test-libraptorjit = callPackage ./test-libraptorjit.nix { inherit pkgs raptorjit; }; check-generated-code = (callPackage ./check-generated-code.nix { inherit raptorjit; }); nowarnings = raptorjit.overrideAttrs( old: { NIX_CFLAGS_COMPILE = "-Werror"; }); @@ -26,10 +28,13 @@ in # Build RaptorJIT and run multiple test suites. { raptorjit = raptorjit; + raptorjit-assert = raptorjit-assert; test-O3 = test "O3" "-O3"; test-O2 = test "O2" "-O2"; test-O1 = test "O1" "-O1"; test-nojit = test "nojit" "-joff"; + test-capi = test-capi; + test-libraptorjit = test-libraptorjit; # Test that generated bytecode is compatible test-bytecode-compat = pkgs.runCommand "test-bytecode-compat" { buildInputs = [ raptorjit ]; } diff --git a/lib/luajit/doc/bluequad-print.css b/lib/luajit/doc/bluequad-print.css index 62e1c16590..a49d309ff1 100644 --- a/lib/luajit/doc/bluequad-print.css +++ b/lib/luajit/doc/bluequad-print.css @@ -1,4 +1,4 @@ -/* Copyright (C) 2004-2017 Mike Pall. +/* Copyright (C) 2004-2022 Mike Pall. * * You are welcome to use the general ideas of this design for your own sites. * But please do not steal the stylesheet, the layout or the color scheme. diff --git a/lib/luajit/doc/bluequad.css b/lib/luajit/doc/bluequad.css index be2c4bf2d5..4c1a9082e8 100644 --- a/lib/luajit/doc/bluequad.css +++ b/lib/luajit/doc/bluequad.css @@ -1,4 +1,4 @@ -/* Copyright (C) 2004-2017 Mike Pall. +/* Copyright (C) 2004-2022 Mike Pall. * * You are welcome to use the general ideas of this design for your own sites. * But please do not steal the stylesheet, the layout or the color scheme. diff --git a/lib/luajit/doc/changes.html b/lib/luajit/doc/changes.html deleted file mode 100644 index 44e03293c3..0000000000 --- a/lib/luajit/doc/changes.html +++ /dev/null @@ -1,815 +0,0 @@ - - - -LuaJIT Change History - - - - - - - - - -
-Lua -
- - -
-

-This is a list of changes between the released versions of LuaJIT.
-The current stable version is LuaJIT 2.0.4.
-

-

-Please check the -» Online Change History -to see whether newer versions are available. -

- -
-

LuaJIT 2.1.0-beta2 — 2016-03-03

- - -

LuaJIT 2.1.0-beta1 — 2015-08-25

-

-This is a brief summary of the major changes in LuaJIT 2.1 compared to 2.0. -Please take a look at the commit history for more details. -

- -
- -
-

LuaJIT 2.0.4 — 2015-05-14

- - -

LuaJIT 2.0.3 — 2014-03-12

- - -

LuaJIT 2.0.2 — 2013-06-03

- - -

LuaJIT 2.0.1 — 2013-02-19

- - -

LuaJIT 2.0.0 — 2012-11-08

- - -

LuaJIT 2.0.0-beta11 — 2012-10-16

- - -

LuaJIT 2.0.0-beta10 — 2012-05-09

- - -

LuaJIT 2.0.0-beta9 — 2011-12-14

- - -

LuaJIT 2.0.0-beta8 — 2011-06-23

- - -

LuaJIT 2.0.0-beta7 — 2011-05-05

- - -

LuaJIT 2.0.0-beta6 — 2011-02-11

- - -

LuaJIT 2.0.0-beta5 — 2010-08-24

- - -

LuaJIT 2.0.0-beta4 — 2010-03-28

- - -

LuaJIT 2.0.0-beta3 — 2010-03-07

- - -

LuaJIT 2.0.0-beta2 — 2009-11-09

- - -

LuaJIT 2.0.0-beta1 — 2009-10-31

- -
-
-
- - - diff --git a/lib/luajit/doc/contact.html b/lib/luajit/doc/contact.html index 5e07bded58..ef44e9dea2 100644 --- a/lib/luajit/doc/contact.html +++ b/lib/luajit/doc/contact.html @@ -1,17 +1,16 @@ - + Contact - - - + +
-Lua +Lua

If you want to report bugs, propose fixes or suggest enhancements, please use the -GitHub issue tracker. +» GitHub issue tracker.

Please send general questions to the -» LuaJIT mailing list. +» LuaJIT mailing list.

You can also send any questions you have directly to me: @@ -88,10 +82,17 @@

Contact

+

+Note: I cannot reply to GMail, Google Workplace, Outlook or Office365 +mail addresses, since they prefer to mindlessly filter out mails sent +from small domains using independent mail servers, such as mine. If you +don't like that, please complain to Google or Microsoft, not me. +

+

Copyright

All documentation is -Copyright © 2005-2017 Mike Pall. +Copyright © 2005-2022 Mike Pall.

@@ -99,7 +100,7 @@

Copyright