Skip to content

Commit

Permalink
Merge branch 'stdlib-js:develop' into snrm2-wasm
Browse files Browse the repository at this point in the history
  • Loading branch information
aman-095 authored Oct 22, 2024
2 parents 30c1021 + 3409af0 commit 637273a
Show file tree
Hide file tree
Showing 103 changed files with 17,427 additions and 148 deletions.
8 changes: 4 additions & 4 deletions lib/node_modules/@stdlib/blas/base/drot-wasm/docs/repl.txt
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@
Number of indexed elements.

x: Float64Array
Input array.
First input array.

strideX: integer
Index increment for `x`.
Expand Down Expand Up @@ -300,9 +300,9 @@
Reallocates the underlying WebAssembly memory instance to a specified number
of bytes.

WebAssembly memory can only **grow**, not shrink. Hence, if provided a
number of bytes which is less than or equal to the size of the current
memory, the function does nothing.
WebAssembly memory can only *grow*, not shrink. Hence, if provided a number
of bytes which is less than or equal to the size of the current memory, the
function does nothing.

When non-shared memory is resized, the underlying the `ArrayBuffer` is
detached, consequently invalidating any associated typed array views. Before
Expand Down
15 changes: 10 additions & 5 deletions lib/node_modules/@stdlib/blas/base/drot-wasm/docs/types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,9 @@ interface ModuleConstructor {
* var viewX = zeros( N, dtype );
* var viewY = zeros( N, dtype );
* mod.read( xptr, viewX );
* mod.read( yptr, viewY );
* // viewX => <Float64Array>[ 1.0, 1.0, 1.0, 1.0, 1.0 ]
*
* mod.read( yptr, viewY );
* // viewY => <Float64Array>[ -1.0, -2.0, -3.0, -4.0, -5.0 ]
*/
new( mem: Memory ): Module; // newable
Expand Down Expand Up @@ -134,8 +135,9 @@ interface ModuleConstructor {
* var viewX = zeros( N, dtype );
* var viewY = zeros( N, dtype );
* mod.read( xptr, viewX );
* mod.read( yptr, viewY );
* // viewX => <Float64Array>[ 1.0, 1.0, 1.0, 1.0, 1.0 ]
*
* mod.read( yptr, viewY );
* // viewY => <Float64Array>[ -1.0, -2.0, -3.0, -4.0, -5.0 ]
*/
( mem: Memory ): Module; // callable
Expand Down Expand Up @@ -202,8 +204,9 @@ interface Module extends ModuleWrapper {
* var viewX = zeros( N, dtype );
* var viewY = zeros( N, dtype );
* mod.read( xptr, viewX );
* mod.read( yptr, viewY );
* // viewX => <Float64Array>[ 1.0, 1.0, 1.0, 1.0, 1.0 ]
*
* mod.read( yptr, viewY );
* // viewY => <Float64Array>[ -1.0, -2.0, -3.0, -4.0, -5.0 ]
*/
main( N: number, xptr: number, strideX: number, yptr: number, strideY: number, c: number, s: number ): number;
Expand Down Expand Up @@ -267,8 +270,9 @@ interface Module extends ModuleWrapper {
* var viewX = zeros( N, dtype );
* var viewY = zeros( N, dtype );
* mod.read( xptr, viewX );
* mod.read( yptr, viewY );
* // viewX => <Float64Array>[ 1.0, 1.0, 1.0, 1.0, 1.0 ]
*
* mod.read( yptr, viewY );
* // viewY => <Float64Array>[ -1.0, -2.0, -3.0, -4.0, -5.0 ]
*/
ndarray( N: number, xptr: number, strideX: number, offsetX: number, yptr: number, strideY: number, offsetY: number, c: number, s: number ): number;
Expand Down Expand Up @@ -379,8 +383,9 @@ interface Routine extends ModuleWrapper {
* var viewX = zeros( N, dtype );
* var viewY = zeros( N, dtype );
* mod.read( xptr, viewX );
* mod.read( yptr, viewY );
* // viewX => <Float64Array>[ 1.0, 1.0, 1.0, 1.0, 1.0 ]
*
* mod.read( yptr, viewY );
* // viewY => <Float64Array>[ -1.0, -2.0, -3.0, -4.0, -5.0 ]
*/
Module: ModuleConstructor;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ setReadOnly( Routine.prototype, 'ndarray', function drot( N, x, strideX, offsetX
// Perform computation by calling the corresponding parent method:
Module.prototype.ndarray.call( this, N, p0.ptr, p0.stride, p0.offset, p1.ptr, p1.stride, p1.offset, c, s ); // eslint-disable-line max-len

// If the output arrays data had to be copied to module memory, copy the results to the provided output arrays...
// If output array data had to be copied to module memory, copy the results to the provided output arrays...
if ( p0.copy ) {
readDataView( N, this.view, p0.stride*p0.BYTES_PER_ELEMENT, p0.ptr, x, strideX, offsetX, true ); // eslint-disable-line max-len
}
Expand Down
2 changes: 1 addition & 1 deletion lib/node_modules/@stdlib/blas/base/drot-wasm/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@stdlib/blas/base/drot-wasm",
"version": "0.0.0",
"description": "Applies a plane rotation.",
"description": "Apply a plane rotation.",
"license": "Apache-2.0",
"author": {
"name": "The Stdlib Authors",
Expand Down
Loading

0 comments on commit 637273a

Please sign in to comment.