Commit Graph

3193 Commits

Author SHA1 Message Date
dzaima
92f40ddbe2 mask.singeli def renames
more bits of renames
2025-02-03 02:13:39 +02:00
dzaima
b6578e43a1 renames of the rest of base.singeli 2025-02-03 02:13:39 +02:00
dzaima
189ffa7d1f bitops.singeli renames 2025-02-03 02:12:58 +02:00
dzaima
f409ee8729 fix generic arch 2025-02-03 02:11:00 +02:00
dzaima
a6266b2168 remove unnecessary defs 2025-02-03 02:11:00 +02:00
dzaima
490285f1ca andAllZero → and_bit_none 2025-02-03 02:11:00 +02:00
dzaima
10ec04a76e (load|store)Low → (load|store)_low 2025-02-03 02:11:00 +02:00
dzaima
ad79ef71cf more Singeli mask op renames 2025-02-03 02:11:00 +02:00
dzaima
6f8b08bb1f oneVal/oneType/allSame → one_val/one_type/all_same 2025-02-03 02:11:00 +02:00
dzaima
a3e33366df exportT → export_tab
also remove exportN as it's unused
2025-02-03 02:11:00 +02:00
dzaima
70e2694f88 more Singeli NEON cleanup 2025-02-03 02:10:47 +02:00
dzaima
b899180166 any_num → any_int where applicable 2025-02-02 23:08:41 +02:00
dzaima
936300a492 any(Int|Num) → any_(int|num) 2025-02-02 23:08:41 +02:00
dzaima
0357d57171 various Singeli NEON cleanup things 2025-02-02 23:08:41 +02:00
dzaima
f3e7f4032c get rid of custom NEON rev
was non-compatibly overridden in places anyways
2025-02-02 23:08:41 +02:00
dzaima
6c7a444cd7 more consistent NEON naming 2025-02-02 23:08:41 +02:00
dzaima
e3b30e5db7 (hom|top)Mask → (hom|top)_to_int 2025-02-02 23:08:41 +02:00
dzaima
e9e1574d28 rearrange initial Singeli base defs 2025-02-02 23:08:41 +02:00
dzaima
426c1b4bf8 (bit|top|hom)(Any|All) → (any|all)_(bit|top|hom) 2025-02-02 23:08:41 +02:00
dzaima
c4afe7b329 (bit|top|hom)Blend → blend_(bit|top|hom) 2025-02-02 23:08:02 +02:00
dzaima
d506691690 fix 𝕨⍋𝕩 issues around NaNs 2025-02-01 20:55:36 +02:00
dzaima
9be5bf45b4 fix signed offset having unsigned type 2025-02-01 20:55:36 +02:00
dzaima
d06200445b MAYBE_UNUSED 2025-02-01 20:55:36 +02:00
dzaima
dcbceccff8 fix integer wrapping in grade sum check 2025-01-24 03:49:25 +02:00
dzaima
204ec21a7c more compact vector width check definitions 2025-01-23 03:21:55 +02:00
dzaima
5f19f15556 NEON (hom|bit)(Any|All) improvements 2025-01-23 03:20:52 +02:00
dzaima
196cc07454 better isCallable 2025-01-17 21:51:46 +02:00
dzaima
8b0d0399e4 fix various F⌾(G⊸Specialized)x 2025-01-16 22:16:49 +02:00
dzaima
517300e567 Windows: static-method-only .c files to .h 2025-01-16 22:06:20 +02:00
vylsaz
7d928a3221 Use OsStr for path on both Windows and non-Windows systems 2025-01-16 22:06:20 +02:00
vylsaz
24bd6735bc Windows: use _wfullpath for realpath 2025-01-16 22:06:20 +02:00
vylsaz
e12ca55ee0 Windows: use utf16 for file functions 2025-01-16 22:06:20 +02:00
vylsaz
40609b2f5f Windows: sh: revert to using calloc() in reading threads 2025-01-16 22:06:20 +02:00
vylsaz
67c2850e38 Windows: sh using utf16; simply argument quoting 2025-01-16 22:06:20 +02:00
vylsaz
580f4a3a19 Windows: utf-16 util 2025-01-16 22:06:19 +02:00
dzaima
a02f195555 make native inverse bindings for ⋆⁼x & w⋆⁼x 2024-12-18 13:29:32 +02:00
dzaima
1822602c34 cleanup from clang's --analyze 2024-12-18 13:03:48 +02:00
dzaima
d1a9669e76 fix •math.LCM on arrays 2024-12-13 07:40:43 +02:00
dzaima
5ecd1858ef fix 1⌾(⟨0⟩⊸⊏)⟨0⟩ 2024-12-07 06:54:07 +02:00
dzaima
86c7b47771 make •FFI properly error on non-list 𝕩 2024-12-04 00:14:00 +02:00
dzaima
162e6ff387 decG more
found automatically via awful hack via GUARANTEED
2024-12-04 00:10:52 +02:00
dzaima
7a5f42a7f0 cleanup
that build.bqn TODO has been completed for a while
2024-12-03 18:38:48 +02:00
dzaima
81abc80863 fast highrank⊸⊏˘ table 2024-12-02 21:57:44 +02:00
dzaima
7509d0c238 don't shadow types 2024-11-30 20:26:54 +02:00
dzaima
d988a620fd native F⌾(a⊸⥊) 2024-11-26 18:08:15 +02:00
dzaima
58f96abe8c fix error message on missing absolute base path 2024-11-23 06:19:39 +02:00
dzaima
79cffc5011 don't use deprecated syntax 2024-11-22 12:48:59 +02:00
dzaima
92641f26ba squeeze fns haven't been AVX2-specific for a while 2024-11-22 12:48:59 +02:00
dzaima
7df2f9ba4f a couple renames & simplifications 2024-11-22 00:44:03 +02:00
dzaima
f0223b8baf properly add 1<<31 2024-11-21 23:04:02 +02:00
Marshall Lochbaum
33ae8744f5 Fast skip ahead for blocks of equal values in i8 and i16 /⁼ 2024-11-20 09:35:22 -05:00
Marshall Lochbaum
7baddcabc2 Better sum versus runs test for /⁼: account for per-element cost of run-based 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
342cadfc00 Check for or handle argument length >2⋆31 in /⁼ 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
194e8c3f22 Update /⁼ implementation comments 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
0bbb335893 Do general i8 and i16 /⁼ counts to i16 buffer, plus overflow list 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
fb5ee179cb Squeeze for slash_im generic case instead of converting individual elements to numbers 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
96b198f643 Condition all the i8 to i32 /⁼ optimization on SINGELI_SIMD, for simplicity 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
e6940e73d0 Fast /⁼ of sorted arguments using semi-sparse representation 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
11117fcc67 Version of count_i32_i32 without large blocks 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
3b103aadd0 Run-based i32 /⁼ (leaving out sum-based) 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
4aea668a6c Allow i16 /⁼ to jump to Singeli code after range checking 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
926e59483d More precise sparse check for i8 /⁼ result: previously stopped at 65 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
e24d0bac63 Extend SIMD counting to i16 in addition to i8 2024-11-17 15:29:36 -05:00
Marshall Lochbaum
e681f3c09a Run-based 1-byte /⁼ implementation 2024-11-17 15:29:36 -05:00
dzaima
092ba4167a fix talloc_realloc in VERIFY_TAIL 2024-11-17 22:18:33 +02:00
dzaima
0a4925e84f move compile_commands.json to build/ 2024-11-14 22:45:43 +02:00
dzaima
b72fe465a2 fix /⁼1e4⥊1‿2 on NEON 2024-11-14 22:45:43 +02:00
dzaima
cbac419b4a fix ⍷2‿0⥊x 2024-11-06 22:34:55 +02:00
dzaima
d47cedb165 some cleanup 2024-11-06 22:32:05 +02:00
Marshall Lochbaum
db16b8fa6e Fix dropped high bit in ⊣˝˘ due to signed rather than unsigned saturating pack 2024-11-06 14:52:18 -05:00
Marshall Lochbaum
67d3fe3f81 Missing SSSE3 requirement for some uninterleave implementations 2024-11-06 14:51:16 -05:00
Marshall Lochbaum
15df6afc7d Implementation comments for transpose with short height/width 2024-11-05 22:04:23 -05:00
Marshall Lochbaum
e75b63831f Clean up dispatching for the various transpose kernel methods 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
2d75c6c535 And manually vectorize uninterleave 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
32ad2e9953 Manually vectorized interleave function 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
980e4b2248 Short-height version of 16x16 i8 transpose kernel, using overlapped writes 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
abb96cb18a Fixed-height transposes, more or less reverse of fixed-width 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
0ab2e485ca Width-4 transpose with shuffles 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
8bc37098dc Modular kernel transpose for odd*2 (so, just 6) 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
091f08c6cc Extend modular permutation transpose to any element size 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
780bfdfa0b Kernel transpose with overreading and skipped writes, for short rows 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
b6e418ed5b Fix modular permutation example in comment 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
d7b508ff3b Move select_cells_single (atom⊸⊏˘) to select.c and use for any singleton index 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
0bdc43cc0f Even number handling for modular permutation ⊣˝˘ 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
4c55eab740 Fast ⊣˝˘ for power-of-two widths, 4- and 8-byte elements 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
8d9d946ec5 Fast ⊣˝˘ with pack for power-of-two widths, 1- and 2-byte elements 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
aefd2a4abd Fast 1-byte small odd width transpose with blends and modular permutation 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
5bdee886cc Extend kernel transpose from AVX2 only to SSE2, NEON 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
6e4859e17f Extend select_rows_byte to any architecture with (shuffle and) blend 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
4669418f1c Extend modular permutation ⊣˝˘ to multi-byte element types 2024-11-05 21:48:54 -05:00
Marshall Lochbaum
9997c52e4c Initial 1-byte ⊣˝˘ with blends and modular permutation 2024-11-05 21:48:54 -05:00
dzaima
0c6e32a24c fix si_select_cells_bit_lt64 signature 2024-10-23 21:53:48 +03:00
dzaima
bd6effe7ab restore dropped comment 2024-10-23 21:37:56 +03:00
Marshall Lochbaum
7ac7297617 More simplifications to Singeli vector utilities 2024-10-21 21:44:21 -04:00
Marshall Lochbaum
8099945068 Use vec_select from Singeli select includes 2024-10-21 18:53:03 -04:00
Marshall Lochbaum
25724b6b3e More NEON functionality moved to neon_intrin/select 2024-10-21 18:53:03 -04:00
Marshall Lochbaum
fa43ffd882 Alias vec_shuffle to shuf 2024-10-21 18:53:03 -04:00
Marshall Lochbaum
27af1c0558 Use Singeli select include for x86 blend, byteshift, zip 2024-10-21 18:53:03 -04:00
Marshall Lochbaum
6140290813 Use Singeli select includes for shuffling 2024-10-14 10:24:07 -04:00
dzaima
52f318e755 EACH_FILLS tests 2024-10-14 05:09:03 +03:00
dzaima
1e00aa71c9 atomEqualF & atomEEqual cleanup 2024-10-10 04:12:07 +03:00
dzaima
503bddced5 bring back atomEqualF fast path 2024-10-10 04:00:43 +03:00
dzaima
61e5ca2767 move function/modifier native ID into their respective structs 2024-10-10 03:46:47 +03:00
dzaima
4885ca1c62 fix rtwrap decompose 2024-10-10 03:46:47 +03:00
dzaima
4e071cf170 disable |, ⌊, ⌈, <, > wrapping for RT_VERIFY
boring arith, and native versions have differences around NaNs
2024-10-10 03:46:47 +03:00
dzaima
6bd47b067e split apart def_decompose 2024-10-10 02:38:17 +03:00
dzaima
b095811da5 remove dead TIi(t_funBI,visit) = 2024-10-10 02:38:17 +03:00
dzaima
3d4a31ae6f access function/modifier runtime ID through macro 2024-10-10 02:38:17 +03:00
dzaima
d4b36b3017 access function/modifier native ID through macro 2024-10-10 02:38:17 +03:00
dzaima
ddb0e09d08 remove unused helper 2024-10-10 02:35:32 +03:00
dzaima
0f12b66fdb move purity separation to the proper place 2024-10-10 02:35:32 +03:00
dzaima
03fc22662b add •internal.Properties for better build parameter detecting 2024-10-10 01:33:17 +03:00
dzaima
3ed6241609 don't attempt to use BMI2 on x86-32 2024-10-09 03:31:20 +03:00
dzaima
72e46f24bd fix silent truncation of requested memory amount in 32-bit builds 2024-10-09 03:31:20 +03:00
dzaima
d640931c02 i64 → ux for bucket indices 2024-10-09 03:31:20 +03:00
dzaima
9371fa0fbc make PROPER_FILLS customizable 2024-10-09 02:49:31 +03:00
dzaima
d5d495ecd2 mention v/V naming in src/README.md 2024-10-09 02:42:17 +03:00
dzaima
183f64c1f9 make ⟨⟩≡∾⟨⟩ under PROPER_FILLS 2024-10-09 02:42:17 +03:00
dzaima
03f2f29f3b use tagu64 in more cases where it should be
and make misused tag() an error
2024-10-09 02:42:17 +03:00
dzaima
0eb7f2e5f4 make ⊢¨ attempt to squeeze generic arrays in PROPER_FILLS
also make it not segfault on an input without a fill
2024-10-09 02:42:17 +03:00
dzaima
f33e1e0dcc allZeroes & allOnes variants which set result flags 2024-10-09 02:42:17 +03:00
dzaima
002d58e057 better withFill slow path copying 2024-10-09 02:42:17 +03:00
dzaima
b2bfa06a4c allBit cleanup in cells.c 2024-10-09 02:42:17 +03:00
dzaima
1eee4d7450 mark input of ∊𝕩 as fl_asc|fl_dsc if it's all same 2024-10-09 01:48:23 +03:00
dzaima
7326348c79 fast ⍷𝕩 & ∊𝕩 on fl_asc+fl_dsc 𝕩 2024-10-09 01:48:23 +03:00
dzaima
b9b0c619db more flag utils 2024-10-09 01:48:23 +03:00
dzaima
12cc7af83d fast path for squeeze target determining on sorted input 2024-10-09 01:48:23 +03:00
dzaima
72cdb0d5fb mark reshape_one as ascending & descending 2024-10-09 01:48:23 +03:00
dzaima
4b38a8cf6b no need to unroll ≢x size checking 2024-10-09 01:48:23 +03:00
dzaima
0d238f2b88 mark ↕n with fl_squoze 2024-10-09 01:48:23 +03:00
dzaima
fc617b6e32 don't try sorting sorted arrays 2024-10-09 01:16:23 +03:00
dzaima
85c5fb659d more clang-friendly multi-input homMask 2024-10-07 02:49:58 +03:00
dzaima
cf19280c54 fix reliance on signed wrapping in replicate 2024-10-03 20:33:02 +03:00
dzaima
7774d8ba5e slightly better number asFill 2024-09-28 18:48:53 +03:00
dzaima
9504f10406 fix test/precompiled.bqn 2024-09-26 03:25:10 +03:00
dzaima
9ca48a55bc better range checking 2024-09-26 03:12:25 +03:00
dzaima
00a9dc03be fast path for FFI array range checking 2024-09-26 02:45:38 +03:00
dzaima
2da0c2d0b1 fix FFI_CHECKS=0 2024-09-26 02:34:16 +03:00
dzaima
989970f7fd fix ∾2‿2⥊<0‿0⥊⟨⟩ 2024-09-22 01:42:26 +03:00
dzaima
e6d3821d52 FFI: invalid character array argument detection 2024-09-22 01:37:13 +03:00
dzaima
4eb632a48d TO_GET helper 2024-09-21 21:26:02 +03:00
dzaima
10671c446d move print_vmStack to DEBUG_VM-only 2024-09-21 21:26:02 +03:00
dzaima
6f7e82e52b include JIT heap in used heap measurements 2024-09-21 21:26:02 +03:00
dzaima
5192a1d466 fix x⊸≍˘list & ≍⟜x˘list on non-atom x 2024-09-16 00:41:17 +03:00
dzaima
92be360412 use "at ..." stacktrace display for empty name 2024-09-15 23:22:11 +03:00
dzaima
1709fbd2f6 new precompiled bytecode generator 2024-09-15 20:11:52 +03:00
dzaima
f2efa657b7 start of cc.bqn/precompiled format refactor 2024-09-15 20:02:04 +03:00
dzaima
452a117818 print precompiled source name & line number in stacktraces 2024-09-14 18:21:23 +03:00
dzaima
0c88263659 don't copy i32slice bytecode in compileAll 2024-09-14 17:16:57 +03:00
dzaima
51ab5db2c8 move interleave_cells to cells.c 2024-09-14 16:18:54 +03:00
dzaima
884d61476f fix flags of take_head 2024-09-14 16:15:11 +03:00
dzaima
f3c63d3887 use reshape_one for c¨ 2024-09-13 22:11:40 +03:00
dzaima
fff96b9475 fix ≍˘ error checking, start of generalizing to join_cells 2024-09-13 22:07:35 +03:00
dzaima
1679d957e8 more checks in arr_* functions 2024-09-13 21:52:18 +03:00
dzaima
ca7410e623 remove unneeded include 2024-09-13 21:14:44 +03:00
dzaima
215a3cad3b fix interleave_cells generic path 2024-09-13 19:39:08 +03:00
dzaima
6c7e6c411a use CMP_AA_IMM 2024-09-13 19:35:59 +03:00
dzaima
b7c3815d4a copy fallback instead of slice in take_head 2024-09-13 19:10:46 +03:00
dzaima
bd6d40a4fa outline GC steps 2024-09-13 18:48:09 +03:00
dzaima
66f37aa299 allow hitting exactly the memory limit 2024-09-13 18:29:06 +03:00
dzaima
574653f3fb improve clangd of various files in src/opt/ 2024-09-13 18:18:29 +03:00
dzaima
64adbbf37e in-place ¯n↓ / n↑ / n⥊ 2024-09-13 17:41:56 +03:00
dzaima
704986d36c reinit_portion 2024-09-13 17:41:48 +03:00
dzaima
4464fced30 print object type in tailFail 2024-09-13 05:10:48 +03:00
dzaima
1b13defe54 rearrange sfns.c a bit 2024-09-12 16:24:32 +03:00
dzaima
8fd897690f move customizeShape into stuff.h 2024-09-12 06:47:06 +03:00
dzaima
27b7c0746c full interleave_cells
needed to make all rank-1 inputs work on non-Singeli builds, but beneficial in general anyway
2024-09-12 06:17:32 +03:00
dzaima
f19a8effc4 suppress warning 2024-09-12 05:49:42 +03:00
dzaima
e9cf8ac330 fix try_interleave_cells on copying TO_BPTR 2024-09-12 05:40:11 +03:00
dzaima
c0e3a3711f fast scalar≍˘arr & arr≍˘scalar & different-type arr≍˘arr 2024-09-12 05:38:34 +03:00
dzaima
da29b285dd better ARR_BPTR_NEVER 2024-09-12 05:18:52 +03:00
dzaima
41785cb4bf Singeli const¨⌾(m⊸/)b 2024-09-10 01:45:56 +03:00
dzaima
02573fa4eb fatal{msg} 2024-09-10 01:45:18 +03:00
dzaima
75c1b74ce1 ARR_BPTR_NEVER 2024-09-09 17:55:26 +03:00
dzaima
03fbb17246 fix broken arr_bptr path in transpose_noshape 2024-09-09 17:55:26 +03:00
dzaima
153850921b actually, hanyv?_ptr shouldn't be a thing 2024-09-09 17:55:26 +03:00
dzaima
4cf8e10b95 fillarr_ptr → fillarrv_ptr 2024-09-09 17:55:26 +03:00
dzaima
af6c618158 use new harr/hslice _ptr functions 2024-09-09 17:55:26 +03:00
dzaima
15401e8dfb h(arr|any|slice)v?_ptr 2024-09-09 17:55:26 +03:00
dzaima
8fafbcde65 fix toConstant
was broken in fork_uc1 before too
2024-09-09 17:55:26 +03:00
dzaima
c2adbd4a3b move toConstant to builtins.h 2024-09-09 17:55:26 +03:00
dzaima
b69f65081d vector → list 2024-09-09 17:55:26 +03:00
dzaima
b62e7cd820 fix generic arch build 2024-09-02 00:04:32 +03:00
dzaima
858dd5bc99 fix bitwiden aarch64 check 2024-08-31 18:28:40 +03:00
dzaima
c8e0bf653b fast path for ∊allEqual 2024-08-27 20:20:52 +03:00
dzaima
0106f04495 make getPageSize return ux 2024-08-27 20:20:34 +03:00
dzaima
559ccae9cc fix select_rows_direct 2024-08-23 04:24:42 +03:00
dzaima
79b0bda0d3 fix •file.MapBytes 2024-08-23 04:20:44 +03:00
dzaima
09bdeb7fd8 more usz overflow checking 2024-08-23 03:59:57 +03:00
dzaima
06689960a5 native ≍⁼⍟k 𝕩 2024-08-23 02:44:49 +03:00
dzaima
5ef4fe828b use customizeShape in transpose 2024-08-23 02:21:59 +03:00
dzaima
6ead1baa11 native ≍⁼ 2024-08-23 02:21:48 +03:00
Marshall Lochbaum
56cb10d6e5 Min/max scan that can skip unused argument vectors sometimes 2024-08-20 15:26:07 -04:00
dzaima
d185d32d9e remove debug include 2024-08-20 17:22:10 +03:00
dzaima
357eb1a27a expanded comment of supported things in the native compiler 2024-08-20 00:17:29 +03:00
dzaima
a654bd88d2 fix aarch64 build 2024-08-17 20:13:38 +03:00
dzaima
0467e1c894 use *arrv_ptr more 2024-08-15 17:36:43 +03:00
dzaima
597fe07838 another incG 2024-08-15 17:36:43 +03:00
dzaima
37a3694df7 restore usage of bitarr_ptr where appropriate 2024-08-15 17:36:43 +03:00
dzaima
5098781ffc replace all bitarr_ptr usages with bitany_ptr 2024-08-15 17:36:43 +03:00
dzaima
88de336516 introduce bitany_ptr
+ more general typed arr pointer getting functions
2024-08-15 17:36:43 +03:00
dzaima
00a64101e9 better bitp_set
apparently gcc & clang aren't smart enough to notice the unnecessary
intermediate u64
2024-08-15 06:00:07 +03:00
dzaima
3b2b9bba1a AVX-512 bitwiden 2024-08-14 23:44:08 +03:00
dzaima
67626d1e49 a couple more AVX-512 defs 2024-08-14 23:44:08 +03:00
dzaima
6b72139d75 include avx512 in base 2024-08-14 22:13:24 +03:00
dzaima
ab4d3565df more --replxx-read-only 2024-08-14 22:10:45 +03:00
dzaima
60380e6270 fix out-of-bounds indexing in factors 2024-08-14 22:10:45 +03:00
Marshall Lochbaum
b2566c8f3a NEON k/bool support 2024-08-14 14:51:01 -04:00
Marshall Lochbaum
b801c7c186 Move to dedicated k/bool loops for k=5,7 and at least SSSE3 2024-08-14 14:51:01 -04:00
Marshall Lochbaum
b2758d355c k/bool cleanup and implementation comments 2024-08-14 14:51:01 -04:00
Marshall Lochbaum
bf69705c82 Factor (8×k)/bool as bit-replicate, then byte-replicate 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
fc1265b3f2 Enable (non-boolean) constrep on SSSE3 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
048529740b SSE2 k/bool where k divides 8 implementations 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
ee27717c97 SSE2 odd/bool implementation using [4]u32 shuffles 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
36e9ca5814 Extend odd/bool SSSE3 code to support AVX2 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
2be022921e Combine generic and SSSE3 general-case odd/bool, so SSSE3 uses mask unpacking 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
3e5dbdbf8d Dedicated generic k/bool for divisors of 8; factor; remove pdep emulation 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
13ec029d9f Get odd k/bool carry by shifting in the unified register, not after masking 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
1621c7d07c Generic-arch k/bool algorithm for odd k with mask unpacking 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
7d7d36b354 Extend SSSE3 k/bool to k<32 using pairwise swaps 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
696a23af9e Mask off last k/bool vector properly 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
1a4cada0cb AVX2 support in rep_const_bool_ssse3_div8 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
b4d84041bc Extend odd k/bool SSSE3 algorithm to k<16, factor even k≤32 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
a439a0a430 SSSE3 k/bool for 2≤k≤8, k≠6 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
a4b6d8d827 SSSE3 3/bool, faster than BMI2 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
7f6c401eb3 Generic-architecture k/bool for small 8<k 2024-08-14 10:30:26 -04:00
Marshall Lochbaum
0602927b17 Move pdep-based k/bool code to Singeli 2024-08-14 10:30:26 -04:00
dzaima
de5bebb239 fix bitnarrow on aarch64 2024-08-14 16:41:58 +03:00
dzaima
565a0a8458 inline zeroPadToCellBits0 2024-08-14 15:21:42 +03:00
dzaima
fc800ee191 remove debug include 2024-08-14 15:06:43 +03:00
dzaima
ef1ea4ad0f make gcc not complain about break
funky
2024-08-14 05:25:13 +03:00
dzaima
2ca2c52c16 use direct bitwiden & bitnarrow in select-rows 2024-08-14 05:18:13 +03:00
dzaima
d95a792230 add bitwiden & bitnarrow to header 2024-08-14 05:18:13 +03:00
dzaima
d0f30bd717 extract direct pointer version of bitnarrow 2024-08-14 05:18:13 +03:00
dzaima
d676663f45 better unaligned load option for bitwiden 2024-08-14 05:18:13 +03:00
dzaima
6e8c6d2e10 extract direct pointer version of bitwiden 2024-08-14 05:18:13 +03:00
dzaima
7eb2b97e29 use COPY_TO_FROM in cpyU16Bits & cpyU8Bits 2024-08-14 05:18:13 +03:00
dzaima
c445f24aae COPY_TO_FROM 2024-08-14 05:18:13 +03:00
dzaima
9b515c3fad reverse pointer arguments of copy.singeli exports 2024-08-14 05:18:13 +03:00
dzaima
6d7648c947 more things that could be select-rows'd 2024-08-14 05:18:13 +03:00
dzaima
f6c52ef3b3 disable Singeli bitwiden on SSE2 2024-08-14 05:18:13 +03:00
dzaima
f356ba0f36 more definitions in base.singeli 2024-08-14 05:18:13 +03:00
dzaima
3fc92eceaa include util/tup in base.singeli 2024-08-14 05:18:13 +03:00
dzaima
a9460da19c more missing NEON comments 2024-08-14 05:18:13 +03:00
dzaima
eccbac37ab aarch64 8→n bitnarrow 2024-08-14 05:18:13 +03:00
dzaima
c72ed51149 Singeli n→8 bitwiden 2024-08-14 05:18:13 +03:00
dzaima
f36cefc9ac more Singeli utils 2024-08-14 05:18:13 +03:00
dzaima
5748833060 fast inds⊸⊏˘bits for ≤8-bit input & output cells 2024-08-14 05:18:13 +03:00
dzaima
920a89f019 native ⋈⁼ & ⌾⋈
plus some more undo & under tests
2024-08-14 05:18:13 +03:00
dzaima
ae0d392d43 tyarrv_free 2024-08-14 05:02:24 +03:00
dzaima
46b63125bc ARBITRARY & GUARANTEED 2024-08-14 05:02:24 +03:00
dzaima
2c36a3e399 fix ⟨1‿2⟩⊸⊏˘ mat 2024-08-09 00:36:23 +03:00
dzaima
3716162e69 use q_fbit more 2024-08-09 00:32:27 +03:00
dzaima
e0facc54f8 minor src/README.md cleanup 2024-08-09 00:32:27 +03:00
dzaima
8e49fc04bb --replxx-read-only 2024-08-09 00:32:27 +03:00
dzaima
ced082cc82 use custom valgrind pdep/pext everywhere 2024-08-09 00:32:27 +03:00
dzaima
d1469df96b fix out-of-bounds load on empty replxx line
`chars[0] == ')'` was branching on empty data; not UB due to custom heap
usage and the code that does run is harmless, but still hit under
valgrind
2024-08-09 00:32:27 +03:00
dzaima
bdb5781ef7 make bitp_get & bitp_set load/store u8 instead of u64 2024-08-09 00:32:27 +03:00
dzaima
64b69700c5 include last power of two in fast-path ⌽˘ 2024-08-09 00:32:27 +03:00
dzaima
bc81b26a03 use fast path for inds⊸⊏˘el_B and ⌽˘el_B 2024-07-29 01:51:59 +03:00
dzaima
6900ae4b68 fix ⌽˘ 0‿10⥊2 and (↕0)⊸⊏˘ 10‿10⥊2 2024-07-29 00:45:01 +03:00
dzaima
52f36c61c0 fix 0‿1⊸⊏˘3‿1⥊2; accept any non-empty array x in select_rows_typed→select_rows_direct 2024-07-29 00:25:09 +03:00
dzaima
3a722b552f ⌽⎉1 x via (⌽↕¯1⊑≢x)⊸⊏⎉1 x 2024-07-28 22:24:34 +03:00
dzaima
081b928cb4 fix zip_halves being weird 2024-07-28 05:10:46 +03:00
dzaima
ffc250eb0e clearer aarch64 zip_halves mzip usage 2024-07-28 04:02:54 +03:00
dzaima
39f4a66ae0 cleanup 2024-07-28 03:55:22 +03:00
dzaima
bd3789963c these are actually good 2024-07-28 02:52:58 +03:00
dzaima
6f25e76e5d tune NEON inds⊸⊏˘f64arr 2024-07-28 02:47:12 +03:00
dzaima
d1d8e8be03 fix assertion on F⌾(⟨⟩⊸⊏) x 2024-07-26 23:25:26 +03:00
dzaima
42b8420af6 ignore unused label warning 2024-07-26 23:13:08 +03:00
dzaima
93fca7c628 fix overflow in index widening 2024-07-26 22:17:49 +03:00
dzaima
7cc1031f70 use outside-of-loop index widening on aarch64
slower as-is due to reduced supported ranges, but that's not an inherent restriction
2024-07-26 22:17:49 +03:00
dzaima
a486e87451 select-cells comments 2024-07-26 22:17:49 +03:00
dzaima
69ca524251 widen inds outside select-cells loops 2024-07-26 22:17:49 +03:00
dzaima
fce7567349 widen bits in bits⊸⊏˘mat to i8 2024-07-26 22:16:23 +03:00
dzaima
90646563a0 don't use zip method for select-cells 2024-07-26 22:16:23 +03:00
dzaima
4a874710c7 allow unhandled types for select_rows 2024-07-26 22:16:23 +03:00
dzaima
478c389c4b fast inds⊸⊏˘ mat 2024-07-26 22:16:23 +03:00
dzaima
0d7bf86182 baseline inds⊸⊏˘ mat 2024-07-26 22:16:23 +03:00
dzaima
f7dd900b3a faster 𝕨⊏𝕩, incl. aarch64 support 2024-07-26 00:01:54 +03:00
dzaima
cda5fd8595 make native compiler not error in debug builds 2024-07-26 00:01:54 +03:00
dzaima
3689e6105c support 2-modifiers in native compiler 2024-07-26 00:01:54 +03:00
dzaima
b7f7eda1ff more cells.h comments 2024-07-26 00:01:54 +03:00
dzaima
d6483a93d3 x86 unzip & unzip128 2024-07-26 00:01:54 +03:00
dzaima
2ed06e0db6 get_range Singeli binding 2024-07-26 00:01:54 +03:00
dzaima
2ca488dd66 aarch64 bool128 select 2024-07-26 00:01:54 +03:00
dzaima
0d5e77766a build select.singeli everywhere 2024-07-26 00:01:54 +03:00
dzaima
f1f4f1734e extract m_tyslice 2024-07-26 00:01:54 +03:00
dzaima
b99d5f23d5 extract bitsel to a function table 2024-07-26 00:01:54 +03:00
dzaima
2b323817ca make 𝕨⊏𝕩 error messages not differ across types 2024-07-26 00:01:54 +03:00
dzaima
e757b690dd mention src/singeli/ in src/README.md 2024-07-26 00:01:54 +03:00
dzaima
c274c35b1e Singeli @for_blocks 2024-07-26 00:01:54 +03:00
dzaima
079d3ffe91 better aarch64 homMask{[16]u8,[16]u8} 2024-07-26 00:01:54 +03:00
dzaima
0b69fa84cd NEON comparisons to 0 2024-07-26 00:01:54 +03:00
dzaima
c0573d602c don't error on non-vector types checked by genchk 2024-07-26 00:01:54 +03:00
dzaima
a9fbd0301d fix ∾˝⎉k refcounting 2024-07-15 00:56:02 +03:00
dzaima
3e9af0a910 fast-path for n•rand.Range 1 2024-07-15 00:56:02 +03:00
dzaima
2dd3798228 more Singeli cleanup 2024-07-15 00:56:02 +03:00
dzaima
2436c45f1d Singeli ceil_log2 for compile-time numbers 2024-07-15 00:52:00 +03:00
dzaima
66a8529d88 remove redundant parentheses in Singeli destructuring 2024-07-15 00:52:00 +03:00
dzaima
ed2198c06a disable tail calls in bqn_fmt & bqn_repr
far from performance-critical, but helpful for stack traces
2024-07-15 00:52:00 +03:00
dzaima
f79e4c6d0a make /(m?zip(128)?|pack)(Lo|Hi)/ not have Lo/Hi as part of name
instead being an optional 3rg arg
2024-07-15 00:52:00 +03:00
dzaima
a671ec9462 aarch64 bittab 2024-07-13 00:10:34 +03:00
dzaima
6dbe76727f update offset for stacktraces on FLDG 2024-07-13 00:10:34 +03:00
dzaima
838639e610 fix gcc-9 build 2024-07-10 03:54:44 +03:00
dzaima
7aab7ceb8b cleanup 2024-07-10 03:44:05 +03:00
dzaima
2bc1ba9f4a fix aarch64 squeeze 2024-07-10 03:43:58 +03:00
dzaima
52d1e61fe0 don't bother early-exiting on masked iteration 2024-07-10 03:24:10 +03:00
dzaima
2fdd72f1c4 faster <SSE4.1 integer accumulating in squeeze 2024-07-10 03:18:17 +03:00
dzaima
a45925b0c6 fix SSE2 squeeze 2024-07-10 03:18:17 +03:00
dzaima
f941245b34 avoid needing two final folds on x86 2024-07-10 03:18:17 +03:00
dzaima
40a5c40bda faster squeeze 2024-07-10 03:18:17 +03:00
dzaima
d66be091be shufps Singeli mapping 2024-07-10 00:55:43 +03:00
dzaima
e96948cb64 Singeli zip128 2024-07-10 00:55:43 +03:00
dzaima
a8af920dc9 •internal.PureKeep 2024-07-10 00:55:43 +03:00
dzaima
01b1ee3637 make ⊢¨ more consistent with other PureIdentFn¨
incl. making ⊢¨ not leak xf under EACH_FILLS
2024-07-10 00:55:43 +03:00
dzaima
826179c83d •internal utility for getting & setting object flags 2024-07-08 22:53:29 +03:00
dzaima
352f22f8f6 don't vectorize tiny loop
could theoretically maybe be beneficial for functions with a hilarious
number of arguments, but whatever. Improves perf on few-argument
functions from not unrolling/vectorizing.
2024-07-08 04:25:27 +03:00
dzaima
3e24442011 use ux in base cmp 2024-07-08 04:25:27 +03:00
Marshall Lochbaum
201fe1e57c Extend fold_rows to any rank, as long as stride is 1 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
48d77e722f Extend ˝ to ´ conversion (for singleton cells) to any rank 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
46704defb6 Convert list⊸↑˘ to a single ↑ call, likewise ↓ and ⌽ 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
ce98efc525 Transform atom⊸⌽⎉k into a single high-rank ⌽ call 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
3b49294145 Specialize ApdMut to reshape if there's only one append 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
76a40491e9 Remove some rank restrictions from for_cells_SA 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
4450d36187 Better handling for «˘ and »˘ trivial cases 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
d89a6da2da Evaluate monadic «» on a length-1 argument by reshaping the fill 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
6eca24ce0a Special code for ∾˝˘ and fold-cells of empty 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
9d5caad9a9 Compute Insert identity natively 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
5d4391a3fd Combine monadic ˘ with outer ˘ or ⎉ 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
a19b5401f7 Fast cases for monadic rank with cell length ≤1 2024-07-05 17:44:42 -04:00
Marshall Lochbaum
8766810db8 Rank-agnostic select_cells 2024-07-04 12:04:00 -04:00
Marshall Lochbaum
ab15eaeeeb Length-1 reverse is a no-op 2024-07-04 12:04:00 -04:00
dzaima
2ce983041c fix shared •HashMap value list 2024-06-30 14:06:05 +03:00
dzaima
47b5d7d832 fix harmless copy-paste error 2024-06-29 04:38:44 +03:00
dzaima
0319be27ea fix bad error message on /⁼3‿3⥊0 2024-06-29 02:59:15 +03:00
dzaima
7eb60d4ec1 correct ElType comment 2024-06-29 02:33:46 +03:00
dzaima
6824b9a747 fix another unaligned load 2024-06-26 06:09:30 +03:00
dzaima
7474e51642 rename mask_of in spaced.singeli
otherwise confusable with maskOf in mask.singeli
2024-06-26 05:39:48 +03:00
dzaima
452065adaf add magic incantation to make optimizer happy 2024-06-26 05:30:09 +03:00
Marshall Lochbaum
e365ecf7dc Fix F`˘ on rank 0 2024-06-25 22:31:47 -04:00
Marshall Lochbaum
ace6105bf6 Fixes for ∧˝˘ and ∨˝˘ on long rows 2024-06-25 22:30:56 -04:00
dzaima
b6bf3f2da6 suppress clang ubsan warning
it's a true warning of actual UB and could conceivably be taken advantage of by a compiler, but is not currently so keep things pretty for now
2024-06-26 03:36:02 +03:00
dzaima
024ab669d5 fix ∧˝˘0‿8⥊0 running comparison functions on length-0 inputs 2024-06-26 03:09:43 +03:00
dzaima
6c110a29ee use loadu_* & storeu_* for unaligned loads/stores 2024-06-26 03:09:43 +03:00
dzaima
ace06e96ae document CMP_* non-zero length requirement 2024-06-26 03:09:43 +03:00
dzaima
7e15dfe104 make loadu_*/storeu_* take void* 2024-06-26 03:03:57 +03:00
Marshall Lochbaum
e952e4ca3e Disable F´˘ special code when cell rank isn't 1 2024-06-23 17:06:37 -04:00
Marshall Lochbaum
5758853ccb Can't call fold-rows special code with reduction length 0 2024-06-23 10:00:44 -04:00
Marshall Lochbaum
5f1c677d48 Support ∧∨ synonyms in fold_rows_bit 2024-06-20 11:05:59 -04:00