numbl 0.1.7 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/binding.gyp +59 -3
- package/dist-cli/cli.js +22538 -7936
- package/dist-lib/lib.js +34682 -20852
- package/dist-lib/numbl-core/executeCode.d.ts +13 -0
- package/dist-lib/numbl-core/fileIOAdapter.d.ts +2 -0
- package/dist-lib/numbl-core/helpers/reduction-helpers.d.ts +7 -2
- package/dist-lib/numbl-core/interpreter/builtins/datetime.d.ts +39 -0
- package/dist-lib/numbl-core/interpreter/builtins/index.d.ts +1 -0
- package/dist-lib/numbl-core/interpreter/builtins/time-system.d.ts +1 -0
- package/dist-lib/numbl-core/interpreter/builtins/types.d.ts +96 -5
- package/dist-lib/numbl-core/interpreter/interpreter.d.ts +41 -3
- package/dist-lib/numbl-core/interpreter/types.d.ts +1 -1
- package/dist-lib/numbl-core/jit/c/abi.d.ts +90 -0
- package/dist-lib/numbl-core/jit/c/assemble.d.ts +56 -0
- package/dist-lib/numbl-core/jit/c/classify.d.ts +70 -0
- package/dist-lib/numbl-core/jit/c/compile.d.ts +37 -0
- package/dist-lib/numbl-core/jit/c/context.d.ts +152 -0
- package/dist-lib/numbl-core/jit/c/emit/assign.d.ts +20 -0
- package/dist-lib/numbl-core/jit/c/emit/complexScalar.d.ts +18 -0
- package/dist-lib/numbl-core/jit/c/emit/fused.d.ts +42 -0
- package/dist-lib/numbl-core/jit/c/emit/helpers.d.ts +40 -0
- package/dist-lib/numbl-core/jit/c/emit/index.d.ts +14 -0
- package/dist-lib/numbl-core/jit/c/emit/scalar.d.ts +23 -0
- package/dist-lib/numbl-core/jit/c/emit/stmt.d.ts +25 -0
- package/dist-lib/numbl-core/jit/c/emit/tensor.d.ts +127 -0
- package/dist-lib/numbl-core/jit/c/emit/userCall.d.ts +58 -0
- package/dist-lib/numbl-core/jit/c/epilogue.d.ts +26 -0
- package/dist-lib/numbl-core/jit/c/feasibility.d.ts +44 -0
- package/dist-lib/numbl-core/jit/c/prelude.d.ts +37 -0
- package/dist-lib/numbl-core/jit/c/visit.d.ts +63 -0
- package/dist-lib/numbl-core/jit/e1/complexKernelEmit.d.ts +46 -0
- package/dist-lib/numbl-core/jit/e1/hash.d.ts +10 -0
- package/dist-lib/numbl-core/jit/e1/install.d.ts +13 -0
- package/dist-lib/numbl-core/jit/e1/kernelEmit.d.ts +54 -0
- package/dist-lib/numbl-core/jit/e1/multiReductionKernel.d.ts +66 -0
- package/dist-lib/numbl-core/jit/e1/openmpFlag.d.ts +13 -0
- package/dist-lib/numbl-core/jit/e1/scalarFnKernel.d.ts +44 -0
- package/dist-lib/numbl-core/jit/e2/assignKernel.d.ts +34 -0
- package/dist-lib/numbl-core/jit/e2/astToJitExpr.d.ts +25 -0
- package/dist-lib/numbl-core/jit/e2/cache.d.ts +80 -0
- package/dist-lib/numbl-core/jit/e2/chainKernelEmit.d.ts +55 -0
- package/dist-lib/numbl-core/jit/e2/classify.d.ts +119 -0
- package/dist-lib/numbl-core/jit/e2/compileFn.d.ts +16 -0
- package/dist-lib/numbl-core/jit/e2/complexChainKernelEmit.d.ts +79 -0
- package/dist-lib/numbl-core/jit/e2/emitShared.d.ts +71 -0
- package/dist-lib/numbl-core/jit/e2/install.d.ts +11 -0
- package/dist-lib/numbl-core/jit/e2/liveness.d.ts +29 -0
- package/dist-lib/numbl-core/jit/e2/loopKernel.d.ts +49 -0
- package/dist-lib/numbl-core/jit/e2/loopKernelEmit.d.ts +75 -0
- package/dist-lib/numbl-core/jit/e2/multiReductionDriver.d.ts +24 -0
- package/dist-lib/numbl-core/jit/e2/reductionKernelEmit.d.ts +72 -0
- package/dist-lib/numbl-core/jit/e2/scalarFnDriver.d.ts +29 -0
- package/dist-lib/numbl-core/jit/fusedChainHelpers.d.ts +65 -0
- package/dist-lib/numbl-core/jit/fusedScalarEmit.d.ts +69 -0
- package/dist-lib/numbl-core/jit/fusion.d.ts +71 -0
- package/dist-lib/numbl-core/jit/fusionOps.d.ts +25 -0
- package/dist-lib/numbl-core/jit/heavyOps.d.ts +15 -0
- package/dist-lib/numbl-core/{interpreter/jit → jit}/index.d.ts +2 -2
- package/dist-lib/numbl-core/jit/jitBailSafety.d.ts +41 -0
- package/dist-lib/numbl-core/{interpreter/jit → jit}/jitLoop.d.ts +2 -2
- package/dist-lib/numbl-core/{interpreter/jit → jit}/jitLoopAnalysis.d.ts +6 -1
- package/dist-lib/numbl-core/jit/jitLower.d.ts +122 -0
- package/dist-lib/numbl-core/jit/jitLowerExpr.d.ts +27 -0
- package/dist-lib/numbl-core/jit/jitLowerStmt.d.ts +9 -0
- package/dist-lib/numbl-core/{interpreter/jit → jit}/jitLowerTypes.d.ts +7 -3
- package/dist-lib/numbl-core/jit/jitTopLevel.d.ts +22 -0
- package/dist-lib/numbl-core/{interpreter/jit → jit}/jitTypes.d.ts +133 -1
- package/dist-lib/numbl-core/{interpreter/jit → jit/js}/jitCodegen.d.ts +2 -2
- package/dist-lib/numbl-core/{interpreter/jit → jit/js}/jitCodegenHoist.d.ts +19 -1
- package/dist-lib/numbl-core/{interpreter/jit → jit/js}/jitHelpers.d.ts +15 -3
- package/dist-lib/numbl-core/{interpreter/jit → jit/js}/jitHelpersIndex.d.ts +7 -0
- package/dist-lib/numbl-core/jit/js/jitHelpersTensor.d.ts +34 -0
- package/dist-lib/numbl-core/jit/js/jsFusedCodegen.d.ts +17 -0
- package/dist-lib/numbl-core/jit/js/jsMultiReduction.d.ts +70 -0
- package/dist-lib/numbl-core/jit/scalarEmit.d.ts +58 -0
- package/dist-lib/numbl-core/lexer/types.d.ts +2 -1
- package/dist-lib/numbl-core/native/lapack-bridge.d.ts +39 -1
- package/dist-lib/numbl-core/ops/bessel.d.ts +18 -0
- package/dist-lib/numbl-core/ops/comparison.d.ts +11 -0
- package/dist-lib/numbl-core/ops/complexBinaryElemwise.d.ts +10 -0
- package/dist-lib/numbl-core/ops/complexUnaryElemwise.d.ts +8 -0
- package/dist-lib/numbl-core/ops/dispatch.d.ts +26 -0
- package/dist-lib/numbl-core/ops/index.d.ts +8 -0
- package/dist-lib/numbl-core/ops/opCodes.d.ts +70 -0
- package/dist-lib/numbl-core/ops/realBinaryElemwise.d.ts +8 -0
- package/dist-lib/numbl-core/ops/realUnaryElemwise.d.ts +5 -0
- package/dist-lib/numbl-core/ops/reduce.d.ts +6 -0
- package/dist-lib/numbl-core/parser/types.d.ts +6 -0
- package/dist-lib/numbl-core/runtime/alloc.d.ts +23 -0
- package/dist-lib/numbl-core/runtime/runtime.d.ts +1 -0
- package/dist-lib/numbl-core/version.d.ts +1 -1
- package/native/jit_runtime/jit_runtime.c +261 -0
- package/native/jit_runtime/jit_runtime.h +204 -0
- package/native/numbl_addon.cpp +62 -1
- package/native/ops/bessel.c +572 -0
- package/native/ops/comparison.c +150 -0
- package/native/ops/complex_binary_elemwise.c +192 -0
- package/native/ops/complex_unary_elemwise.c +152 -0
- package/native/ops/numbl_ops.c +66 -0
- package/native/ops/numbl_ops.h +262 -0
- package/native/ops/real_binary_elemwise.c +85 -0
- package/native/ops/real_unary_elemwise.c +104 -0
- package/native/ops/reduce.c +162 -0
- package/native/ops_napi.cpp +320 -0
- package/package.json +8 -9
- package/dist-lib/numbl-core/interpreter/jit/jitHelpersTensor.d.ts +0 -28
- package/dist-lib/numbl-core/interpreter/jit/jitLower.d.ts +0 -23
- /package/dist-lib/numbl-core/{interpreter/jit → jit/js}/jitHelpersComplex.d.ts +0 -0
package/binding.gyp
CHANGED
|
@@ -19,10 +19,20 @@
|
|
|
19
19
|
"native/elemwise.cpp",
|
|
20
20
|
"native/randn.cpp",
|
|
21
21
|
"native/unary_elemwise.cpp",
|
|
22
|
-
"native/lapack_gmres.cpp"
|
|
22
|
+
"native/lapack_gmres.cpp",
|
|
23
|
+
"native/ops/numbl_ops.c",
|
|
24
|
+
"native/ops/real_binary_elemwise.c",
|
|
25
|
+
"native/ops/complex_binary_elemwise.c",
|
|
26
|
+
"native/ops/real_unary_elemwise.c",
|
|
27
|
+
"native/ops/complex_unary_elemwise.c",
|
|
28
|
+
"native/ops/comparison.c",
|
|
29
|
+
"native/ops/reduce.c",
|
|
30
|
+
"native/ops/bessel.c",
|
|
31
|
+
"native/ops_napi.cpp"
|
|
23
32
|
],
|
|
24
33
|
"include_dirs": [
|
|
25
34
|
"<!@(node -p \"require('node-addon-api').include\")",
|
|
35
|
+
"native/ops",
|
|
26
36
|
"<!@(pkg-config --cflags-only-I fftw3 2>/dev/null | sed 's/-I//g' || true)"
|
|
27
37
|
],
|
|
28
38
|
"dependencies": [
|
|
@@ -30,11 +40,57 @@
|
|
|
30
40
|
],
|
|
31
41
|
"defines": [ "NAPI_DISABLE_CPP_EXCEPTIONS" ],
|
|
32
42
|
"libraries": [
|
|
33
|
-
"-
|
|
43
|
+
"-lm",
|
|
34
44
|
"<!@(pkg-config --libs fftw3 2>/dev/null || echo '-lfftw3')",
|
|
35
45
|
"<!@(pkg-config --libs-only-L fftw3 2>/dev/null | sed 's/-L/-Wl,-rpath,/g' || true)"
|
|
36
46
|
],
|
|
37
|
-
"
|
|
47
|
+
"cflags": [ "-O3", "-march=native", "-fopenmp-simd", "-fno-math-errno", "-ffast-math" ],
|
|
48
|
+
"cflags_c": [ "-O3", "-march=native", "-fopenmp-simd", "-fno-math-errno", "-ffast-math" ],
|
|
49
|
+
"cflags_cc": [ "-std=c++17", "-O3", "-march=native", "-fopenmp-simd", "-fno-math-errno", "-ffast-math" ],
|
|
50
|
+
"conditions": [
|
|
51
|
+
['OS=="linux"', {
|
|
52
|
+
"cflags_c": [ "-fopenmp" ],
|
|
53
|
+
"cflags_cc": [ "-fopenmp" ],
|
|
54
|
+
"libraries": [ "-lopenblas", "-lmvec", "-fopenmp" ]
|
|
55
|
+
}],
|
|
56
|
+
['OS=="mac"', {
|
|
57
|
+
# Use Apple's Accelerate framework for BLAS/LAPACK — ships with
|
|
58
|
+
# macOS, so no Homebrew openblas install or keg-only linker path
|
|
59
|
+
# wrangling. The classic Fortran ABI (dgetrf_, etc.) that the
|
|
60
|
+
# native sources declare is provided by Accelerate.
|
|
61
|
+
"libraries": [ "-framework Accelerate" ]
|
|
62
|
+
}]
|
|
63
|
+
]
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"target_name": "numbl_ops",
|
|
67
|
+
"type": "static_library",
|
|
68
|
+
"sources": [
|
|
69
|
+
"native/ops/numbl_ops.c",
|
|
70
|
+
"native/ops/real_binary_elemwise.c",
|
|
71
|
+
"native/ops/complex_binary_elemwise.c",
|
|
72
|
+
"native/ops/real_unary_elemwise.c",
|
|
73
|
+
"native/ops/complex_unary_elemwise.c",
|
|
74
|
+
"native/ops/comparison.c",
|
|
75
|
+
"native/ops/reduce.c",
|
|
76
|
+
"native/ops/bessel.c"
|
|
77
|
+
],
|
|
78
|
+
"include_dirs": [ "native/ops" ],
|
|
79
|
+
"cflags_c": [ "-O3", "-march=native", "-fopenmp-simd", "-fno-math-errno", "-ffast-math", "-fPIC" ],
|
|
80
|
+
"conditions": [
|
|
81
|
+
['OS=="linux"', {
|
|
82
|
+
"cflags_c": [ "-fopenmp" ]
|
|
83
|
+
}]
|
|
84
|
+
]
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
"target_name": "numbl_jit_runtime",
|
|
88
|
+
"type": "static_library",
|
|
89
|
+
"sources": [
|
|
90
|
+
"native/jit_runtime/jit_runtime.c"
|
|
91
|
+
],
|
|
92
|
+
"include_dirs": [ "native/jit_runtime", "native/ops" ],
|
|
93
|
+
"cflags_c": [ "-O3", "-march=native", "-fopenmp-simd", "-fno-math-errno", "-ffast-math", "-fPIC" ]
|
|
38
94
|
}
|
|
39
95
|
]
|
|
40
96
|
}
|