Commit Graph

181 Commits

Author SHA1 Message Date
Mike Pall
07b3cd3cf9 Check for upvalue state transition in IR_UREFO.
Thanks to Peter Cawley. #1085
2023-11-05 16:34:46 +01:00
Mike Pall
9e0437240f FFI: Fix 64 bit shift fold rules.
Thanks to Peter Cawley. #1079
2023-09-11 21:06:25 +02:00
Mike Pall
9bd2404137 Merge branch 'master' into v2.1 2023-09-09 13:42:12 +02:00
Mike Pall
7f9907b4ed Add NaN check to IR_NEWREF.
Thanks to Peter Cawley. #1069
2023-09-09 13:37:31 +02:00
Mike Pall
ef587afb2c Merge branch 'master' into v2.1 2023-08-20 21:33:37 +02:00
Mike Pall
158a284cc9 Bump copyright date. 2023-08-20 21:25:30 +02:00
Mike Pall
a04480e311 Merge branch 'master' into v2.1 2022-12-22 00:52:04 +01:00
Mike Pall
8a5e398c52 Avoid negation of signed integers in C that may hold INT*_MIN.
Reported by minoki.
Recent C compilers 'take advantage' of the undefined behavior.
This completely changes the meaning of expressions like (k == -k).
2022-12-22 00:03:06 +01:00
Mike Pall
1a401622fe Fix assertions.
Reported by ssdr.
2022-04-17 10:56:11 +02:00
Mike Pall
8b8304f16e Fix compiler warning. 2022-03-08 20:05:33 +01:00
Mike Pall
96d6d50320 Revert to trival pow() optimizations to prevent inaccuracies. 2022-03-08 19:44:10 +01:00
Mike Pall
9512d5c1ac Fix pow() optimization inconsistencies. 2022-01-24 14:37:50 +01:00
Mike Pall
5935564c3b Fix FOLD rule for BUFHDR append with intervening buffer use.
Reported by XmiliaH.
2022-01-23 19:13:53 +01:00
Mike Pall
1dddc55ca3 Prevent replay of buffer operation for PHI operands.
Contributed by XmiliaH.
2022-01-16 21:00:24 +01:00
Mike Pall
7306ba78d6 Merge branch 'master' into v2.1 2022-01-15 19:42:30 +01:00
Mike Pall
c4dfb625ba Bump copyright date. 2022-01-15 19:30:54 +01:00
Mike Pall
bc1bdbf620 Fix FOLD rule for BUFHDR append.
Reported by XmiliaH.
2022-01-13 18:33:04 +01:00
Mike Pall
4ccaf348fb Merge branch 'master' into v2.1 2022-01-13 17:51:09 +01:00
Mike Pall
c8bcf1e5fb Fix ABC FOLD rule with constants.
Reported by XmiliaH.
2022-01-13 14:40:11 +01:00
Mike Pall
a91d0d9d3b Merge branch 'master' into v2.1 2021-12-19 18:37:06 +01:00
Mike Pall
e73916d811 Prevent CSE of a REF_BASE operand across IR_RETF.
Reported by XmiliaH.
2021-12-19 18:35:27 +01:00
Mike Pall
8b7ea5c1af Merge branch 'master' into v2.1 2021-12-17 14:17:16 +01:00
Mike Pall
7b994e0ee0 Fix FOLD rule for x-0.
Reported by XmiliaH.
2021-12-17 14:15:40 +01:00
Mike Pall
bb0f241015 Compile table traversals: next(), pairs(), BC_ISNEXT/BC_ITERN.
Sponsored by OpenResty Inc.
2021-09-19 17:49:25 +02:00
Mike Pall
29bc1f04ac String buffers, part 3d: Compile string buffer methods and functions.
Sponsored by fmad.io.
2021-07-19 16:53:30 +02:00
Mike Pall
2182630903 Minor improvements of optimizations. 2021-07-19 16:50:05 +02:00
Mike Pall
02bcbea8b0 String buffers, part 3c: Add IRBUFHDR_WRITE mode.
Sponsored by fmad.io.
2021-07-19 16:46:27 +02:00
Mike Pall
3a0cf69730 String buffers, part 3b: Change IR_BUFHDR op2 mode bits to mode.
Sponsored by fmad.io.
2021-07-19 16:33:13 +02:00
Mike Pall
6df650fe3f String buffers, part 3a: Add IR_TMPREF for passing TValues to helpers.
Sponsored by fmad.io.
2021-07-19 16:23:12 +02:00
Mike Pall
1e66d0f9e6 Merge branch 'master' into v2.1 2021-01-02 21:56:07 +01:00
Mike Pall
f47c864b01 Bump copyright date. 2021-01-02 21:49:41 +01:00
Mike Pall
8ae5170cdc Improve assertions. 2020-06-15 02:52:00 +02:00
Mike Pall
1a4ff13117 Optimize table length computation with hinting.
10x faster on loop with t[#t+1] = x idiom. Also used by table.insert.
2020-05-27 19:20:44 +02:00
Mike Pall
b2307c8ad8 Remove pow() splitting and cleanup backends. 2020-05-23 21:33:01 +02:00
Mike Pall
5655be4546 Cleanup math function compilation and fix inconsistencies. 2020-05-22 04:53:35 +02:00
Mike Pall
03208c8162 Fix math.min()/math.max() inconsistencies. 2020-05-22 03:10:30 +02:00
Mike Pall
87b111f0fe Merge branch 'master' into v2.1 2020-01-20 23:34:21 +01:00
Mike Pall
38a5ed4b43 Bump copyright date. 2020-01-20 23:26:51 +01:00
Mike Pall
e45b04f499 Merge branch 'master' into v2.1 2019-11-10 22:39:40 +01:00
Mike Pall
c4e15b457e Fix narrowing of conversions to U32.
Reported by spacewander.
2019-11-10 22:37:42 +01:00
Mike Pall
4b17a6a2ff Merge branch 'master' into v2.1 2017-11-08 12:53:24 +01:00
Mike Pall
9f0caad0e4 Fix FOLD rule for strength reduction of widening.
Reported by Matthew Burk.
2017-11-08 12:53:05 +01:00
Mike Pall
cf8a5bea89 Add FOLD rules for mixed BAND/BOR with constants. 2017-04-30 23:59:16 +02:00
Mike Pall
c29afcb1a3 Merge branch 'master' into v2.1 2017-03-30 11:38:16 +02:00
Mike Pall
e205ad0c55 FFI: Fix FOLD rules for int64_t comparisons.
Thanks to Peter Cawley.
2017-03-30 11:35:29 +02:00
Mike Pall
4416e885d2 Fix FOLD rules for math.abs() and FP negation.
Broken since SIMD constants were switched to IR_FLOAD REF_NIL.
2017-02-20 02:51:31 +01:00
Mike Pall
71ff7ef8a7 Merge branch 'master' into v2.1 2017-01-17 12:41:05 +01:00
Mike Pall
b93a1dd0c8 Bump copyright date to 2017. 2017-01-17 12:35:03 +01:00
Mike Pall
ec2756ba78 Add missing FOLD rule for 64 bit shift+BAND simplification. 2016-12-08 22:38:35 +01:00
Mike Pall
c98660c8c3 Must preserve J->fold.ins (fins) around call to lj_ir_ksimd(). 2016-07-22 16:35:46 +02:00