@yowasp/yosys 0.51.871 → 0.53.911

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/gen/bundle.js CHANGED
@@ -611,7 +611,7 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
611
611
  const module1 = getCoreModule("yosys.core2.wasm");
612
612
  const module2 = getCoreModule("yosys.core3.wasm");
613
613
  const module3 = getCoreModule("yosys.core4.wasm");
614
- const { cli, fs, io, monotonicClock, wallClock } = imports.runtime;
614
+ const { cli, fs, io, monotonicClock, random, wallClock } = imports.runtime;
615
615
  const {
616
616
  TerminalInput: TerminalInput2,
617
617
  TerminalOutput: TerminalOutput2,
@@ -637,6 +637,7 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
637
637
  OutputStream: OutputStream2
638
638
  } = io;
639
639
  const { now } = monotonicClock;
640
+ const { getRandomBytes } = random;
640
641
  const { now: now$1 } = wallClock;
641
642
  let gen = function* init() {
642
643
  let exports0;
@@ -4657,7 +4658,17 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
4657
4658
  }
4658
4659
  }
4659
4660
  }
4660
- function trampoline37(arg0) {
4661
+ function trampoline37(arg0, arg1) {
4662
+ const ret = getRandomBytes(BigInt.asUintN(64, arg0));
4663
+ var val0 = ret;
4664
+ var len0 = val0.byteLength;
4665
+ var ptr0 = realloc0(0, 0, 1, len0 * 1);
4666
+ var src0 = new Uint8Array(val0.buffer || val0, val0.byteOffset, len0 * 1);
4667
+ new Uint8Array(memory0.buffer, ptr0, len0 * 1).set(src0);
4668
+ dataView(memory0).setInt32(arg1 + 4, len0, true);
4669
+ dataView(memory0).setInt32(arg1 + 0, ptr0, true);
4670
+ }
4671
+ function trampoline38(arg0) {
4661
4672
  const ret = getDirectories();
4662
4673
  var vec3 = ret;
4663
4674
  var len3 = vec3.length;
@@ -4688,7 +4699,7 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
4688
4699
  const captureTable3 = /* @__PURE__ */ new Map();
4689
4700
  let captureCnt3 = 0;
4690
4701
  handleTables[3] = handleTable3;
4691
- function trampoline38(arg0) {
4702
+ function trampoline39(arg0) {
4692
4703
  const ret = getTerminalStdin();
4693
4704
  var variant1 = ret;
4694
4705
  if (variant1 === null || variant1 === void 0) {
@@ -4712,7 +4723,7 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
4712
4723
  const captureTable4 = /* @__PURE__ */ new Map();
4713
4724
  let captureCnt4 = 0;
4714
4725
  handleTables[4] = handleTable4;
4715
- function trampoline39(arg0) {
4726
+ function trampoline40(arg0) {
4716
4727
  const ret = getTerminalStdout();
4717
4728
  var variant1 = ret;
4718
4729
  if (variant1 === null || variant1 === void 0) {
@@ -4732,7 +4743,7 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
4732
4743
  dataView(memory0).setInt32(arg0 + 4, handle0, true);
4733
4744
  }
4734
4745
  }
4735
- function trampoline40(arg0) {
4746
+ function trampoline41(arg0) {
4736
4747
  const ret = getTerminalStderr();
4737
4748
  var variant1 = ret;
4738
4749
  if (variant1 === null || variant1 === void 0) {
@@ -4849,27 +4860,29 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
4849
4860
  ({ exports: exports0 } = yield instantiateCore(yield module2));
4850
4861
  ({ exports: exports1 } = yield instantiateCore(yield module0, {
4851
4862
  wasi_snapshot_preview1: {
4852
- args_get: exports0["29"],
4853
- args_sizes_get: exports0["30"],
4854
- clock_time_get: exports0["33"],
4855
- environ_get: exports0["31"],
4856
- environ_sizes_get: exports0["32"],
4857
- fd_close: exports0["34"],
4858
- fd_fdstat_get: exports0["35"],
4859
- fd_fdstat_set_flags: exports0["36"],
4860
- fd_prestat_dir_name: exports0["38"],
4861
- fd_prestat_get: exports0["37"],
4862
- fd_read: exports0["39"],
4863
- fd_readdir: exports0["40"],
4864
- fd_renumber: exports0["41"],
4865
- fd_seek: exports0["42"],
4866
- fd_write: exports0["43"],
4867
- path_create_directory: exports0["44"],
4868
- path_filestat_get: exports0["45"],
4869
- path_open: exports0["46"],
4870
- path_remove_directory: exports0["47"],
4871
- path_unlink_file: exports0["48"],
4872
- proc_exit: exports0["49"]
4863
+ args_get: exports0["30"],
4864
+ args_sizes_get: exports0["31"],
4865
+ clock_time_get: exports0["34"],
4866
+ environ_get: exports0["32"],
4867
+ environ_sizes_get: exports0["33"],
4868
+ fd_close: exports0["35"],
4869
+ fd_fdstat_get: exports0["36"],
4870
+ fd_fdstat_set_flags: exports0["37"],
4871
+ fd_filestat_get: exports0["38"],
4872
+ fd_prestat_dir_name: exports0["40"],
4873
+ fd_prestat_get: exports0["39"],
4874
+ fd_read: exports0["41"],
4875
+ fd_readdir: exports0["42"],
4876
+ fd_renumber: exports0["43"],
4877
+ fd_seek: exports0["44"],
4878
+ fd_write: exports0["45"],
4879
+ path_create_directory: exports0["46"],
4880
+ path_filestat_get: exports0["47"],
4881
+ path_open: exports0["48"],
4882
+ path_remove_directory: exports0["49"],
4883
+ path_unlink_file: exports0["50"],
4884
+ proc_exit: exports0["51"],
4885
+ random_get: exports0["52"]
4873
4886
  }
4874
4887
  }));
4875
4888
  ({ exports: exports2 } = yield instantiateCore(yield module1, {
@@ -4902,13 +4915,13 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
4902
4915
  "[resource-drop]terminal-output": trampoline8
4903
4916
  },
4904
4917
  "wasi:cli/terminal-stderr@0.2.0": {
4905
- "get-terminal-stderr": exports0["28"]
4918
+ "get-terminal-stderr": exports0["29"]
4906
4919
  },
4907
4920
  "wasi:cli/terminal-stdin@0.2.0": {
4908
- "get-terminal-stdin": exports0["26"]
4921
+ "get-terminal-stdin": exports0["27"]
4909
4922
  },
4910
4923
  "wasi:cli/terminal-stdout@0.2.0": {
4911
- "get-terminal-stdout": exports0["27"]
4924
+ "get-terminal-stdout": exports0["28"]
4912
4925
  },
4913
4926
  "wasi:clocks/monotonic-clock@0.2.0": {
4914
4927
  now: trampoline0
@@ -4917,7 +4930,7 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
4917
4930
  now: exports0["2"]
4918
4931
  },
4919
4932
  "wasi:filesystem/preopens@0.2.0": {
4920
- "get-directories": exports0["25"]
4933
+ "get-directories": exports0["26"]
4921
4934
  },
4922
4935
  "wasi:filesystem/types@0.2.0": {
4923
4936
  "[method]descriptor.append-via-stream": exports0["5"],
@@ -4951,6 +4964,9 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
4951
4964
  "[method]output-stream.write": exports0["22"],
4952
4965
  "[resource-drop]input-stream": trampoline4,
4953
4966
  "[resource-drop]output-stream": trampoline2
4967
+ },
4968
+ "wasi:random/random@0.2.0": {
4969
+ "get-random-bytes": exports0["25"]
4954
4970
  }
4955
4971
  }));
4956
4972
  memory0 = exports1.memory;
@@ -4980,30 +4996,33 @@ function instantiate(getCoreModule, imports, instantiateCore = WebAssembly.insta
4980
4996
  "26": trampoline38,
4981
4997
  "27": trampoline39,
4982
4998
  "28": trampoline40,
4983
- "29": exports2.args_get,
4999
+ "29": trampoline41,
4984
5000
  "3": trampoline15,
4985
- "30": exports2.args_sizes_get,
4986
- "31": exports2.environ_get,
4987
- "32": exports2.environ_sizes_get,
4988
- "33": exports2.clock_time_get,
4989
- "34": exports2.fd_close,
4990
- "35": exports2.fd_fdstat_get,
4991
- "36": exports2.fd_fdstat_set_flags,
4992
- "37": exports2.fd_prestat_get,
4993
- "38": exports2.fd_prestat_dir_name,
4994
- "39": exports2.fd_read,
5001
+ "30": exports2.args_get,
5002
+ "31": exports2.args_sizes_get,
5003
+ "32": exports2.environ_get,
5004
+ "33": exports2.environ_sizes_get,
5005
+ "34": exports2.clock_time_get,
5006
+ "35": exports2.fd_close,
5007
+ "36": exports2.fd_fdstat_get,
5008
+ "37": exports2.fd_fdstat_set_flags,
5009
+ "38": exports2.fd_filestat_get,
5010
+ "39": exports2.fd_prestat_get,
4995
5011
  "4": trampoline16,
4996
- "40": exports2.fd_readdir,
4997
- "41": exports2.fd_renumber,
4998
- "42": exports2.fd_seek,
4999
- "43": exports2.fd_write,
5000
- "44": exports2.path_create_directory,
5001
- "45": exports2.path_filestat_get,
5002
- "46": exports2.path_open,
5003
- "47": exports2.path_remove_directory,
5004
- "48": exports2.path_unlink_file,
5005
- "49": exports2.proc_exit,
5012
+ "40": exports2.fd_prestat_dir_name,
5013
+ "41": exports2.fd_read,
5014
+ "42": exports2.fd_readdir,
5015
+ "43": exports2.fd_renumber,
5016
+ "44": exports2.fd_seek,
5017
+ "45": exports2.fd_write,
5018
+ "46": exports2.path_create_directory,
5019
+ "47": exports2.path_filestat_get,
5020
+ "48": exports2.path_open,
5021
+ "49": exports2.path_remove_directory,
5006
5022
  "5": trampoline17,
5023
+ "50": exports2.path_unlink_file,
5024
+ "51": exports2.proc_exit,
5025
+ "52": exports2.random_get,
5007
5026
  "6": trampoline18,
5008
5027
  "7": trampoline19,
5009
5028
  "8": trampoline20,