@typeberry/lib 0.4.0-1ad1b89 → 0.4.0-2473e55

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.
Files changed (4) hide show
  1. package/index.cjs +1 -73
  2. package/index.d.ts +3 -478
  3. package/index.js +1 -73
  4. package/package.json +1 -1
package/index.cjs CHANGED
@@ -17718,79 +17718,7 @@ class DebuggerAdapter {
17718
17718
 
17719
17719
  var index$4 = /*#__PURE__*/Object.freeze({
17720
17720
  __proto__: null,
17721
- AccumulationStateUpdate: AccumulationStateUpdate,
17722
- ArgsDecoder: ArgsDecoder,
17723
- get ArgumentType () { return ArgumentType; },
17724
- BasicBlocks: BasicBlocks,
17725
- CURRENT_SERVICE_ID: CURRENT_SERVICE_ID,
17726
- get EjectError () { return EjectError; },
17727
- ExtendedWitdthImmediateDecoder: ExtendedWitdthImmediateDecoder,
17728
- get ForgetPreimageError () { return ForgetPreimageError; },
17729
- HostCallMemory: HostCallMemory,
17730
- HostCallRegisters: HostCallRegisters,
17731
- HostCallResult: HostCallResult,
17732
- ImmediateDecoder: ImmediateDecoder,
17733
- InsufficientFundsError: InsufficientFundsError,
17734
- MachineInstance: MachineInstance,
17735
- Mask: Mask,
17736
- get MemoryOperation () { return MemoryOperation; },
17737
- MemorySegment: MemorySegment,
17738
- NO_OF_REGISTERS: NO_OF_REGISTERS$1,
17739
- get NewServiceError () { return NewServiceError; },
17740
- NibblesDecoder: NibblesDecoder,
17741
- NoMachineError: NoMachineError,
17742
- OK: OK,
17743
- get PagesError () { return PagesError; },
17744
- PartiallyUpdatedState: PartiallyUpdatedState,
17745
- get PeekPokeError () { return PeekPokeError; },
17746
- PendingTransfer: PendingTransfer,
17747
- get PreimageStatusKind () { return PreimageStatusKind; },
17748
- Program: Program,
17749
- ProgramDecoder: ProgramDecoder,
17750
- get ProvidePreimageError () { return ProvidePreimageError; },
17751
- Pvm: DebuggerAdapter,
17752
- Registers: Registers,
17753
- get RequestPreimageError () { return RequestPreimageError; },
17754
- Result: Result$1,
17755
- SERVICE_ID_BYTES: SERVICE_ID_BYTES,
17756
- SegmentExportError: SegmentExportError,
17757
- SpiMemory: SpiMemory,
17758
- SpiProgram: SpiProgram,
17759
- TRANSFER_MEMO_BYTES: TRANSFER_MEMO_BYTES,
17760
- get TransferError () { return TransferError; },
17761
- UnprivilegedError: UnprivilegedError,
17762
- get UpdatePrivilegesError () { return UpdatePrivilegesError; },
17763
- WithDebug: WithDebug,
17764
- get ZeroVoidError () { return ZeroVoidError; },
17765
- asOpaqueType: asOpaqueType,
17766
- assertEmpty: assertEmpty,
17767
- assertNever: assertNever,
17768
- block: index$m,
17769
- bytes: index$t,
17770
- check: check,
17771
- clampU64ToU32: clampU64ToU32,
17772
- createResults: createResults,
17773
- decodeStandardProgram: decodeStandardProgram,
17774
- emptyRegistersBuffer: emptyRegistersBuffer,
17775
- extractCodeAndMetadata: extractCodeAndMetadata,
17776
- getServiceId: getServiceId,
17777
- getServiceIdOrCurrent: getServiceIdOrCurrent,
17778
- hash: index$p,
17779
- hostCallInfoAccount: codecServiceAccountInfoWithThresholdBalance,
17780
- inspect: inspect,
17781
- instructionArgumentTypeMap: instructionArgumentTypeMap,
17782
- interpreter: index$8,
17783
- isBrowser: isBrowser,
17784
- lazyInspect: lazyInspect,
17785
- measure: measure,
17786
- numbers: index$s,
17787
- resultToString: resultToString,
17788
- seeThrough: seeThrough,
17789
- slotsToPreimageStatus: slotsToPreimageStatus,
17790
- toMemoryOperation: toMemoryOperation,
17791
- tryAsMachineId: tryAsMachineId,
17792
- tryAsProgramCounter: tryAsProgramCounter,
17793
- writeServiceIdAsLeBytes: writeServiceIdAsLeBytes
17721
+ Pvm: DebuggerAdapter
17794
17722
  });
17795
17723
 
17796
17724
  const ENTROPY_BYTES = 32;
package/index.d.ts CHANGED
@@ -14544,8 +14544,6 @@ interface IMemory {
14544
14544
  read(address: U32, result: Uint8Array): Result$2<OK, PageFault$1>;
14545
14545
  }
14546
14546
 
14547
- declare const NO_OF_REGISTERS$1 = 13;
14548
-
14549
14547
  /** Allow to set and get all registers encoded into little-endian bytes. */
14550
14548
  interface IRegisters {
14551
14549
  /**
@@ -15719,38 +15717,6 @@ declare class ImmediateDecoder {
15719
15717
  }
15720
15718
  }
15721
15719
 
15722
- declare class NibblesDecoder {
15723
- private byte = new Int8Array(1);
15724
-
15725
- setByte(byte: number) {
15726
- this.byte[0] = byte;
15727
- }
15728
-
15729
- getHighNibble() {
15730
- return (this.byte[0] & 0xf0) >>> 4;
15731
- }
15732
-
15733
- getLowNibble() {
15734
- return this.byte[0] & 0x0f;
15735
- }
15736
-
15737
- getHighNibbleAsRegisterIndex() {
15738
- return Math.min(this.getHighNibble(), MAX_REGISTER_INDEX);
15739
- }
15740
-
15741
- getLowNibbleAsRegisterIndex() {
15742
- return Math.min(this.getLowNibble(), MAX_REGISTER_INDEX);
15743
- }
15744
-
15745
- getHighNibbleAsLength() {
15746
- return Math.min(this.getHighNibble(), MAX_LENGTH);
15747
- }
15748
-
15749
- getLowNibbleAsLength() {
15750
- return Math.min(this.getLowNibble(), MAX_LENGTH);
15751
- }
15752
- }
15753
-
15754
15720
  type EmptyArgs = {
15755
15721
  type: ArgumentType.NO_ARGUMENTS;
15756
15722
  noOfBytesToSkip: number;
@@ -16089,106 +16055,6 @@ declare class ArgsDecoder {
16089
16055
  }
16090
16056
  }
16091
16057
 
16092
- declare const createResults = () => {
16093
- const results = new Array(ARGUMENT_TYPE_LENGTH) as Results;
16094
-
16095
- results[ArgumentType.NO_ARGUMENTS] = {
16096
- type: ArgumentType.NO_ARGUMENTS,
16097
- noOfBytesToSkip: 1,
16098
- };
16099
-
16100
- results[ArgumentType.ONE_IMMEDIATE] = {
16101
- type: ArgumentType.ONE_IMMEDIATE,
16102
- noOfBytesToSkip: 1,
16103
- immediateDecoder: new ImmediateDecoder(),
16104
- };
16105
-
16106
- results[ArgumentType.TWO_REGISTERS] = {
16107
- type: ArgumentType.TWO_REGISTERS,
16108
- noOfBytesToSkip: 1,
16109
- firstRegisterIndex: 0,
16110
- secondRegisterIndex: 0,
16111
- };
16112
-
16113
- results[ArgumentType.THREE_REGISTERS] = {
16114
- type: ArgumentType.THREE_REGISTERS,
16115
- noOfBytesToSkip: 1,
16116
- firstRegisterIndex: 0,
16117
- secondRegisterIndex: 0,
16118
- thirdRegisterIndex: 0,
16119
- };
16120
-
16121
- results[ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET] = {
16122
- type: ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET,
16123
- noOfBytesToSkip: 1,
16124
- registerIndex: 0,
16125
- immediateDecoder: new ImmediateDecoder(),
16126
- nextPc: 0,
16127
- };
16128
-
16129
- results[ArgumentType.TWO_REGISTERS_ONE_OFFSET] = {
16130
- type: ArgumentType.TWO_REGISTERS_ONE_OFFSET,
16131
- noOfBytesToSkip: 1,
16132
- firstRegisterIndex: 0,
16133
- secondRegisterIndex: 0,
16134
- nextPc: 0,
16135
- };
16136
-
16137
- results[ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE] = {
16138
- type: ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE,
16139
- noOfBytesToSkip: 1,
16140
- firstRegisterIndex: 0,
16141
- secondRegisterIndex: 0,
16142
- immediateDecoder: new ImmediateDecoder(),
16143
- };
16144
-
16145
- results[ArgumentType.ONE_REGISTER_ONE_IMMEDIATE] = {
16146
- type: ArgumentType.ONE_REGISTER_ONE_IMMEDIATE,
16147
- noOfBytesToSkip: 1,
16148
- registerIndex: 0,
16149
- immediateDecoder: new ImmediateDecoder(),
16150
- };
16151
-
16152
- results[ArgumentType.ONE_REGISTER_TWO_IMMEDIATES] = {
16153
- type: ArgumentType.ONE_REGISTER_TWO_IMMEDIATES,
16154
- noOfBytesToSkip: 1,
16155
- registerIndex: 0,
16156
- firstImmediateDecoder: new ImmediateDecoder(),
16157
- secondImmediateDecoder: new ImmediateDecoder(),
16158
- };
16159
-
16160
- results[ArgumentType.ONE_OFFSET] = {
16161
- type: ArgumentType.ONE_OFFSET,
16162
- noOfBytesToSkip: 1,
16163
- nextPc: 0,
16164
- };
16165
-
16166
- results[ArgumentType.TWO_IMMEDIATES] = {
16167
- type: ArgumentType.TWO_IMMEDIATES,
16168
- noOfBytesToSkip: 1,
16169
- firstImmediateDecoder: new ImmediateDecoder(),
16170
- secondImmediateDecoder: new ImmediateDecoder(),
16171
- };
16172
-
16173
- results[ArgumentType.TWO_REGISTERS_TWO_IMMEDIATES] = {
16174
- type: ArgumentType.TWO_REGISTERS_TWO_IMMEDIATES,
16175
- noOfBytesToSkip: 1,
16176
- firstImmediateDecoder: new ImmediateDecoder(),
16177
- secondImmediateDecoder: new ImmediateDecoder(),
16178
- firstRegisterIndex: 0,
16179
- secondRegisterIndex: 0,
16180
- };
16181
-
16182
- results[ArgumentType.ONE_REGISTER_ONE_EXTENDED_WIDTH_IMMEDIATE] = {
16183
- type: ArgumentType.ONE_REGISTER_ONE_EXTENDED_WIDTH_IMMEDIATE,
16184
- noOfBytesToSkip: 9,
16185
- registerIndex: 0,
16186
- immediateDecoder: new ExtendedWitdthImmediateDecoder(),
16187
- };
16188
-
16189
- return results;
16190
- };
16191
-
16192
16058
  declare enum Instruction {
16193
16059
  TRAP = 0,
16194
16060
  FALLTHROUGH = 1,
@@ -16331,164 +16197,6 @@ declare enum Instruction {
16331
16197
  MIN_U = 230,
16332
16198
  }
16333
16199
 
16334
- declare const instructionArgumentTypeMap = (() => {
16335
- const instructionArgumentTypeMap = new Array<ArgumentType>(HIGHEST_INSTRUCTION_NUMBER + 1);
16336
-
16337
- instructionArgumentTypeMap[Instruction.TRAP] = ArgumentType.NO_ARGUMENTS;
16338
- instructionArgumentTypeMap[Instruction.FALLTHROUGH] = ArgumentType.NO_ARGUMENTS;
16339
-
16340
- instructionArgumentTypeMap[Instruction.ECALLI] = ArgumentType.ONE_IMMEDIATE;
16341
-
16342
- instructionArgumentTypeMap[Instruction.LOAD_IMM_64] = ArgumentType.ONE_REGISTER_ONE_EXTENDED_WIDTH_IMMEDIATE;
16343
-
16344
- instructionArgumentTypeMap[Instruction.STORE_IMM_U8] = ArgumentType.TWO_IMMEDIATES;
16345
- instructionArgumentTypeMap[Instruction.STORE_IMM_U16] = ArgumentType.TWO_IMMEDIATES;
16346
- instructionArgumentTypeMap[Instruction.STORE_IMM_U32] = ArgumentType.TWO_IMMEDIATES;
16347
- instructionArgumentTypeMap[Instruction.STORE_IMM_U64] = ArgumentType.TWO_IMMEDIATES;
16348
-
16349
- instructionArgumentTypeMap[Instruction.JUMP] = ArgumentType.ONE_OFFSET;
16350
-
16351
- instructionArgumentTypeMap[Instruction.JUMP_IND] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16352
- instructionArgumentTypeMap[Instruction.LOAD_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16353
- instructionArgumentTypeMap[Instruction.LOAD_U8] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16354
- instructionArgumentTypeMap[Instruction.LOAD_I8] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16355
- instructionArgumentTypeMap[Instruction.LOAD_U16] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16356
- instructionArgumentTypeMap[Instruction.LOAD_I16] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16357
- instructionArgumentTypeMap[Instruction.LOAD_U32] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16358
- instructionArgumentTypeMap[Instruction.LOAD_I32] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16359
- instructionArgumentTypeMap[Instruction.LOAD_U64] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16360
- instructionArgumentTypeMap[Instruction.STORE_U8] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16361
- instructionArgumentTypeMap[Instruction.STORE_U16] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16362
- instructionArgumentTypeMap[Instruction.STORE_U32] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16363
- instructionArgumentTypeMap[Instruction.STORE_U64] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE;
16364
-
16365
- instructionArgumentTypeMap[Instruction.STORE_IMM_IND_U8] = ArgumentType.ONE_REGISTER_TWO_IMMEDIATES;
16366
- instructionArgumentTypeMap[Instruction.STORE_IMM_IND_U16] = ArgumentType.ONE_REGISTER_TWO_IMMEDIATES;
16367
- instructionArgumentTypeMap[Instruction.STORE_IMM_IND_U32] = ArgumentType.ONE_REGISTER_TWO_IMMEDIATES;
16368
- instructionArgumentTypeMap[Instruction.STORE_IMM_IND_U64] = ArgumentType.ONE_REGISTER_TWO_IMMEDIATES;
16369
-
16370
- instructionArgumentTypeMap[Instruction.LOAD_IMM_JUMP] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16371
- instructionArgumentTypeMap[Instruction.BRANCH_EQ_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16372
- instructionArgumentTypeMap[Instruction.BRANCH_NE_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16373
- instructionArgumentTypeMap[Instruction.BRANCH_LT_U_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16374
- instructionArgumentTypeMap[Instruction.BRANCH_LE_U_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16375
- instructionArgumentTypeMap[Instruction.BRANCH_GE_U_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16376
- instructionArgumentTypeMap[Instruction.BRANCH_GT_U_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16377
- instructionArgumentTypeMap[Instruction.BRANCH_LT_S_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16378
- instructionArgumentTypeMap[Instruction.BRANCH_LE_S_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16379
- instructionArgumentTypeMap[Instruction.BRANCH_GE_S_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16380
- instructionArgumentTypeMap[Instruction.BRANCH_GT_S_IMM] = ArgumentType.ONE_REGISTER_ONE_IMMEDIATE_ONE_OFFSET;
16381
-
16382
- instructionArgumentTypeMap[Instruction.MOVE_REG] = ArgumentType.TWO_REGISTERS;
16383
- instructionArgumentTypeMap[Instruction.SBRK] = ArgumentType.TWO_REGISTERS;
16384
- instructionArgumentTypeMap[Instruction.COUNT_SET_BITS_64] = ArgumentType.TWO_REGISTERS;
16385
- instructionArgumentTypeMap[Instruction.COUNT_SET_BITS_32] = ArgumentType.TWO_REGISTERS;
16386
- instructionArgumentTypeMap[Instruction.LEADING_ZERO_BITS_64] = ArgumentType.TWO_REGISTERS;
16387
- instructionArgumentTypeMap[Instruction.LEADING_ZERO_BITS_32] = ArgumentType.TWO_REGISTERS;
16388
- instructionArgumentTypeMap[Instruction.TRAILING_ZERO_BITS_64] = ArgumentType.TWO_REGISTERS;
16389
- instructionArgumentTypeMap[Instruction.TRAILING_ZERO_BITS_32] = ArgumentType.TWO_REGISTERS;
16390
- instructionArgumentTypeMap[Instruction.SIGN_EXTEND_8] = ArgumentType.TWO_REGISTERS;
16391
- instructionArgumentTypeMap[Instruction.SIGN_EXTEND_16] = ArgumentType.TWO_REGISTERS;
16392
- instructionArgumentTypeMap[Instruction.ZERO_EXTEND_16] = ArgumentType.TWO_REGISTERS;
16393
- instructionArgumentTypeMap[Instruction.REVERSE_BYTES] = ArgumentType.TWO_REGISTERS;
16394
-
16395
- instructionArgumentTypeMap[Instruction.STORE_IND_U8] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16396
- instructionArgumentTypeMap[Instruction.STORE_IND_U16] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16397
- instructionArgumentTypeMap[Instruction.STORE_IND_U32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16398
- instructionArgumentTypeMap[Instruction.STORE_IND_U64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16399
- instructionArgumentTypeMap[Instruction.LOAD_IND_U8] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16400
- instructionArgumentTypeMap[Instruction.LOAD_IND_I8] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16401
- instructionArgumentTypeMap[Instruction.LOAD_IND_U16] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16402
- instructionArgumentTypeMap[Instruction.LOAD_IND_I16] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16403
- instructionArgumentTypeMap[Instruction.LOAD_IND_U32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16404
- instructionArgumentTypeMap[Instruction.LOAD_IND_I32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16405
- instructionArgumentTypeMap[Instruction.LOAD_IND_U64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16406
- instructionArgumentTypeMap[Instruction.ADD_IMM_32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16407
- instructionArgumentTypeMap[Instruction.ADD_IMM_64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16408
- instructionArgumentTypeMap[Instruction.AND_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16409
- instructionArgumentTypeMap[Instruction.XOR_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16410
- instructionArgumentTypeMap[Instruction.OR_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16411
- instructionArgumentTypeMap[Instruction.MUL_IMM_32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16412
- instructionArgumentTypeMap[Instruction.MUL_IMM_64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16413
- instructionArgumentTypeMap[Instruction.SET_LT_U_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16414
- instructionArgumentTypeMap[Instruction.SET_LT_S_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16415
- instructionArgumentTypeMap[Instruction.SHLO_L_IMM_32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16416
- instructionArgumentTypeMap[Instruction.SHLO_R_IMM_32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16417
- instructionArgumentTypeMap[Instruction.SHAR_R_IMM_32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16418
- instructionArgumentTypeMap[Instruction.NEG_ADD_IMM_32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16419
- instructionArgumentTypeMap[Instruction.SHLO_L_IMM_64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16420
- instructionArgumentTypeMap[Instruction.SHLO_R_IMM_64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16421
- instructionArgumentTypeMap[Instruction.SHAR_R_IMM_64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16422
- instructionArgumentTypeMap[Instruction.NEG_ADD_IMM_64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16423
- instructionArgumentTypeMap[Instruction.SET_GT_U_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16424
- instructionArgumentTypeMap[Instruction.SET_GT_S_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16425
- instructionArgumentTypeMap[Instruction.SHLO_L_IMM_ALT_32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16426
- instructionArgumentTypeMap[Instruction.SHLO_R_IMM_ALT_32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16427
- instructionArgumentTypeMap[Instruction.SHAR_R_IMM_ALT_32] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16428
- instructionArgumentTypeMap[Instruction.SHLO_L_IMM_ALT_64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16429
- instructionArgumentTypeMap[Instruction.SHLO_R_IMM_ALT_64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16430
- instructionArgumentTypeMap[Instruction.SHAR_R_IMM_ALT_64] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16431
- instructionArgumentTypeMap[Instruction.CMOV_IZ_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16432
- instructionArgumentTypeMap[Instruction.CMOV_NZ_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16433
- instructionArgumentTypeMap[Instruction.ROT_R_64_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16434
- instructionArgumentTypeMap[Instruction.ROT_R_64_IMM_ALT] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16435
- instructionArgumentTypeMap[Instruction.ROT_R_32_IMM] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16436
- instructionArgumentTypeMap[Instruction.ROT_R_32_IMM_ALT] = ArgumentType.TWO_REGISTERS_ONE_IMMEDIATE;
16437
-
16438
- instructionArgumentTypeMap[Instruction.BRANCH_EQ] = ArgumentType.TWO_REGISTERS_ONE_OFFSET;
16439
- instructionArgumentTypeMap[Instruction.BRANCH_NE] = ArgumentType.TWO_REGISTERS_ONE_OFFSET;
16440
- instructionArgumentTypeMap[Instruction.BRANCH_LT_U] = ArgumentType.TWO_REGISTERS_ONE_OFFSET;
16441
- instructionArgumentTypeMap[Instruction.BRANCH_LT_S] = ArgumentType.TWO_REGISTERS_ONE_OFFSET;
16442
- instructionArgumentTypeMap[Instruction.BRANCH_GE_U] = ArgumentType.TWO_REGISTERS_ONE_OFFSET;
16443
- instructionArgumentTypeMap[Instruction.BRANCH_GE_S] = ArgumentType.TWO_REGISTERS_ONE_OFFSET;
16444
-
16445
- instructionArgumentTypeMap[Instruction.LOAD_IMM_JUMP_IND] = ArgumentType.TWO_REGISTERS_TWO_IMMEDIATES;
16446
-
16447
- instructionArgumentTypeMap[Instruction.ADD_32] = ArgumentType.THREE_REGISTERS;
16448
- instructionArgumentTypeMap[Instruction.ADD_64] = ArgumentType.THREE_REGISTERS;
16449
- instructionArgumentTypeMap[Instruction.SUB_32] = ArgumentType.THREE_REGISTERS;
16450
- instructionArgumentTypeMap[Instruction.SUB_64] = ArgumentType.THREE_REGISTERS;
16451
- instructionArgumentTypeMap[Instruction.AND] = ArgumentType.THREE_REGISTERS;
16452
- instructionArgumentTypeMap[Instruction.XOR] = ArgumentType.THREE_REGISTERS;
16453
- instructionArgumentTypeMap[Instruction.OR] = ArgumentType.THREE_REGISTERS;
16454
- instructionArgumentTypeMap[Instruction.MUL_32] = ArgumentType.THREE_REGISTERS;
16455
- instructionArgumentTypeMap[Instruction.MUL_64] = ArgumentType.THREE_REGISTERS;
16456
- instructionArgumentTypeMap[Instruction.MUL_UPPER_S_S] = ArgumentType.THREE_REGISTERS;
16457
- instructionArgumentTypeMap[Instruction.MUL_UPPER_U_U] = ArgumentType.THREE_REGISTERS;
16458
- instructionArgumentTypeMap[Instruction.MUL_UPPER_S_U] = ArgumentType.THREE_REGISTERS;
16459
- instructionArgumentTypeMap[Instruction.DIV_U_32] = ArgumentType.THREE_REGISTERS;
16460
- instructionArgumentTypeMap[Instruction.DIV_S_32] = ArgumentType.THREE_REGISTERS;
16461
- instructionArgumentTypeMap[Instruction.REM_U_32] = ArgumentType.THREE_REGISTERS;
16462
- instructionArgumentTypeMap[Instruction.REM_S_32] = ArgumentType.THREE_REGISTERS;
16463
- instructionArgumentTypeMap[Instruction.DIV_U_64] = ArgumentType.THREE_REGISTERS;
16464
- instructionArgumentTypeMap[Instruction.DIV_S_64] = ArgumentType.THREE_REGISTERS;
16465
- instructionArgumentTypeMap[Instruction.REM_U_64] = ArgumentType.THREE_REGISTERS;
16466
- instructionArgumentTypeMap[Instruction.REM_S_64] = ArgumentType.THREE_REGISTERS;
16467
- instructionArgumentTypeMap[Instruction.SET_LT_U] = ArgumentType.THREE_REGISTERS;
16468
- instructionArgumentTypeMap[Instruction.SET_LT_S] = ArgumentType.THREE_REGISTERS;
16469
- instructionArgumentTypeMap[Instruction.SHLO_L_32] = ArgumentType.THREE_REGISTERS;
16470
- instructionArgumentTypeMap[Instruction.SHLO_R_32] = ArgumentType.THREE_REGISTERS;
16471
- instructionArgumentTypeMap[Instruction.SHAR_R_32] = ArgumentType.THREE_REGISTERS;
16472
- instructionArgumentTypeMap[Instruction.SHLO_L_64] = ArgumentType.THREE_REGISTERS;
16473
- instructionArgumentTypeMap[Instruction.SHLO_R_64] = ArgumentType.THREE_REGISTERS;
16474
- instructionArgumentTypeMap[Instruction.SHAR_R_64] = ArgumentType.THREE_REGISTERS;
16475
- instructionArgumentTypeMap[Instruction.CMOV_IZ] = ArgumentType.THREE_REGISTERS;
16476
- instructionArgumentTypeMap[Instruction.CMOV_NZ] = ArgumentType.THREE_REGISTERS;
16477
- instructionArgumentTypeMap[Instruction.ROT_L_64] = ArgumentType.THREE_REGISTERS;
16478
- instructionArgumentTypeMap[Instruction.ROT_L_32] = ArgumentType.THREE_REGISTERS;
16479
- instructionArgumentTypeMap[Instruction.ROT_R_64] = ArgumentType.THREE_REGISTERS;
16480
- instructionArgumentTypeMap[Instruction.ROT_R_32] = ArgumentType.THREE_REGISTERS;
16481
- instructionArgumentTypeMap[Instruction.AND_INV] = ArgumentType.THREE_REGISTERS;
16482
- instructionArgumentTypeMap[Instruction.OR_INV] = ArgumentType.THREE_REGISTERS;
16483
- instructionArgumentTypeMap[Instruction.XNOR] = ArgumentType.THREE_REGISTERS;
16484
- instructionArgumentTypeMap[Instruction.MAX] = ArgumentType.THREE_REGISTERS;
16485
- instructionArgumentTypeMap[Instruction.MAX_U] = ArgumentType.THREE_REGISTERS;
16486
- instructionArgumentTypeMap[Instruction.MIN] = ArgumentType.THREE_REGISTERS;
16487
- instructionArgumentTypeMap[Instruction.MIN_U] = ArgumentType.THREE_REGISTERS;
16488
-
16489
- return instructionArgumentTypeMap;
16490
- })();
16491
-
16492
16200
  declare class BasicBlocks {
16493
16201
  private basicBlocks: Set<number> = new Set();
16494
16202
 
@@ -18264,66 +17972,6 @@ declare enum ProgramDecoderError {
18264
17972
  InvalidProgramError = 0,
18265
17973
  }
18266
17974
 
18267
- declare class ProgramDecoder {
18268
- private code: Uint8Array;
18269
- private mask: Mask;
18270
- private jumpTable: JumpTable;
18271
-
18272
- constructor(rawProgram: Uint8Array) {
18273
- const { code, mask, jumpTable, jumpTableItemLength } = this.decodeProgram(rawProgram);
18274
-
18275
- this.code = new Uint8Array(code);
18276
- this.mask = new Mask(mask);
18277
- this.jumpTable = new JumpTable(jumpTableItemLength, jumpTable);
18278
- }
18279
-
18280
- private decodeProgram(program: Uint8Array) {
18281
- const decoder = Decoder.fromBlob(program);
18282
- // number of items in the jump table
18283
- const jumpTableLength = decoder.varU32();
18284
- // how many bytes are used to encode a single item of the jump table
18285
- const jumpTableItemLength = decoder.u8();
18286
- // the length of the code (in bytes).
18287
- const codeLength = decoder.varU32();
18288
-
18289
- const jumpTableLengthInBytes = jumpTableLength * jumpTableItemLength;
18290
- const jumpTable = decoder.bytes(jumpTableLengthInBytes).raw;
18291
-
18292
- const code = decoder.bytes(codeLength).raw;
18293
- const mask = decoder.bitVecFixLen(codeLength);
18294
- decoder.finish();
18295
-
18296
- return {
18297
- mask,
18298
- code,
18299
- jumpTableItemLength,
18300
- jumpTable,
18301
- };
18302
- }
18303
-
18304
- getMask() {
18305
- return this.mask;
18306
- }
18307
-
18308
- getCode() {
18309
- return this.code;
18310
- }
18311
-
18312
- getJumpTable() {
18313
- return this.jumpTable;
18314
- }
18315
-
18316
- /** https://graypaper.fluffylabs.dev/#/68eaa1f/23f400234701?v=0.6.4 */
18317
- static deblob(program: Uint8Array): Result$2<ProgramDecoder, ProgramDecoderError> {
18318
- try {
18319
- return Result.ok(new ProgramDecoder(program));
18320
- } catch (e) {
18321
- logger.error`Invalid program: ${e}`;
18322
- return Result.error(ProgramDecoderError.InvalidProgramError, () => `Program decoder error: ${e}`);
18323
- }
18324
- }
18325
- }
18326
-
18327
17975
  type InterpreterOptions = {
18328
17976
  useSbrkGas?: boolean;
18329
17977
  };
@@ -19606,133 +19254,10 @@ declare class DebuggerAdapter {
19606
19254
  }
19607
19255
  }
19608
19256
 
19609
- type index$4_AccumulationStateUpdate = AccumulationStateUpdate;
19610
- declare const index$4_AccumulationStateUpdate: typeof AccumulationStateUpdate;
19611
- type index$4_Args = Args;
19612
- type index$4_ArgsDecoder = ArgsDecoder;
19613
- declare const index$4_ArgsDecoder: typeof ArgsDecoder;
19614
- type index$4_ArgumentType = ArgumentType;
19615
- declare const index$4_ArgumentType: typeof ArgumentType;
19616
- type index$4_BasicBlocks = BasicBlocks;
19617
- declare const index$4_BasicBlocks: typeof BasicBlocks;
19618
- declare const index$4_CURRENT_SERVICE_ID: typeof CURRENT_SERVICE_ID;
19619
- type index$4_EjectError = EjectError;
19620
- declare const index$4_EjectError: typeof EjectError;
19621
- type index$4_EnumMapping = EnumMapping;
19622
- type index$4_ErrorResult<Error> = ErrorResult<Error>;
19623
- type index$4_ExtendedWitdthImmediateDecoder = ExtendedWitdthImmediateDecoder;
19624
- declare const index$4_ExtendedWitdthImmediateDecoder: typeof ExtendedWitdthImmediateDecoder;
19625
- type index$4_ForgetPreimageError = ForgetPreimageError;
19626
- declare const index$4_ForgetPreimageError: typeof ForgetPreimageError;
19627
- type index$4_HostCallMemory = HostCallMemory;
19628
- declare const index$4_HostCallMemory: typeof HostCallMemory;
19629
- type index$4_HostCallRegisters = HostCallRegisters;
19630
- declare const index$4_HostCallRegisters: typeof HostCallRegisters;
19631
- declare const index$4_HostCallResult: typeof HostCallResult;
19632
- type index$4_ImmediateDecoder = ImmediateDecoder;
19633
- declare const index$4_ImmediateDecoder: typeof ImmediateDecoder;
19634
- type index$4_InsufficientFundsError = InsufficientFundsError;
19635
- declare const index$4_MAX_U32: typeof MAX_U32;
19636
- declare const index$4_MAX_U32_BIG_INT: typeof MAX_U32_BIG_INT;
19637
- type index$4_MachineId = MachineId;
19638
- type index$4_MachineInstance = MachineInstance;
19639
- declare const index$4_MachineInstance: typeof MachineInstance;
19640
- type index$4_MachineResult = MachineResult;
19641
- type index$4_MachineStatus = MachineStatus;
19642
- type index$4_Mask = Mask;
19643
- declare const index$4_Mask: typeof Mask;
19644
- type index$4_MemoryOperation = MemoryOperation;
19645
- declare const index$4_MemoryOperation: typeof MemoryOperation;
19646
- type index$4_MemorySegment = MemorySegment;
19647
- declare const index$4_MemorySegment: typeof MemorySegment;
19648
- type index$4_NewServiceError = NewServiceError;
19649
- declare const index$4_NewServiceError: typeof NewServiceError;
19650
- type index$4_NibblesDecoder = NibblesDecoder;
19651
- declare const index$4_NibblesDecoder: typeof NibblesDecoder;
19652
- type index$4_NoMachineError = NoMachineError;
19653
- type index$4_OK = OK;
19654
- type index$4_OkResult<Ok> = OkResult<Ok>;
19655
- type index$4_Opaque<Type, Token extends string> = Opaque<Type, Token>;
19656
- type index$4_PagesError = PagesError;
19657
- declare const index$4_PagesError: typeof PagesError;
19658
- type index$4_PartialState = PartialState;
19659
- type index$4_PartiallyUpdatedState<T extends StateSlice = StateSlice> = PartiallyUpdatedState<T>;
19660
- declare const index$4_PartiallyUpdatedState: typeof PartiallyUpdatedState;
19661
- type index$4_PeekPokeError = PeekPokeError;
19662
- declare const index$4_PeekPokeError: typeof PeekPokeError;
19663
- type index$4_PendingTransfer = PendingTransfer;
19664
- declare const index$4_PendingTransfer: typeof PendingTransfer;
19665
- type index$4_PreimageStatus = PreimageStatus;
19666
- type index$4_PreimageStatusKind = PreimageStatusKind;
19667
- declare const index$4_PreimageStatusKind: typeof PreimageStatusKind;
19668
- type index$4_Program = Program;
19669
- declare const index$4_Program: typeof Program;
19670
- type index$4_ProgramCounter = ProgramCounter;
19671
- type index$4_ProgramDecoder = ProgramDecoder;
19672
- declare const index$4_ProgramDecoder: typeof ProgramDecoder;
19673
- type index$4_ProvidePreimageError = ProvidePreimageError;
19674
- declare const index$4_ProvidePreimageError: typeof ProvidePreimageError;
19675
- type index$4_RefineExternalities = RefineExternalities;
19676
- type index$4_Registers = Registers;
19677
- declare const index$4_Registers: typeof Registers;
19678
- type index$4_RequestPreimageError = RequestPreimageError;
19679
- declare const index$4_RequestPreimageError: typeof RequestPreimageError;
19680
- type index$4_RichTaggedError<Kind extends string | number, Nested> = RichTaggedError<Kind, Nested>;
19681
- declare const index$4_RichTaggedError: typeof RichTaggedError;
19682
- declare const index$4_SERVICE_ID_BYTES: typeof SERVICE_ID_BYTES;
19683
- type index$4_SegmentExportError = SegmentExportError;
19684
- type index$4_ServiceStateUpdate = ServiceStateUpdate;
19685
- type index$4_SpiMemory = SpiMemory;
19686
- declare const index$4_SpiMemory: typeof SpiMemory;
19687
- type index$4_SpiProgram = SpiProgram;
19688
- declare const index$4_SpiProgram: typeof SpiProgram;
19689
- type index$4_StateSlice = StateSlice;
19690
- type index$4_StringLiteral<Type> = StringLiteral<Type>;
19691
- type index$4_TRANSFER_MEMO_BYTES = TRANSFER_MEMO_BYTES;
19692
- type index$4_TaggedError<Kind, Nested> = TaggedError<Kind, Nested>;
19693
- type index$4_TokenOf<OpaqueType, Type> = TokenOf<OpaqueType, Type>;
19694
- type index$4_TransferError = TransferError;
19695
- declare const index$4_TransferError: typeof TransferError;
19696
- type index$4_Uninstantiable = Uninstantiable;
19697
- type index$4_UnprivilegedError = UnprivilegedError;
19698
- type index$4_UpdatePrivilegesError = UpdatePrivilegesError;
19699
- declare const index$4_UpdatePrivilegesError: typeof UpdatePrivilegesError;
19700
- type index$4_WithDebug = WithDebug;
19701
- declare const index$4_WithDebug: typeof WithDebug;
19702
- type index$4_WithOpaque<Token extends string> = WithOpaque<Token>;
19703
- type index$4_ZeroVoidError = ZeroVoidError;
19704
- declare const index$4_ZeroVoidError: typeof ZeroVoidError;
19705
- declare const index$4___OPAQUE_TYPE__: typeof __OPAQUE_TYPE__;
19706
- declare const index$4_asOpaqueType: typeof asOpaqueType;
19707
- declare const index$4_assertEmpty: typeof assertEmpty;
19708
- declare const index$4_assertNever: typeof assertNever;
19709
- declare const index$4_check: typeof check;
19710
- declare const index$4_clampU64ToU32: typeof clampU64ToU32;
19711
- declare const index$4_createResults: typeof createResults;
19712
- declare const index$4_decodeStandardProgram: typeof decodeStandardProgram;
19713
- declare const index$4_deepCloneMapWithArray: typeof deepCloneMapWithArray;
19714
- declare const index$4_emptyRegistersBuffer: typeof emptyRegistersBuffer;
19715
- declare const index$4_extractCodeAndMetadata: typeof extractCodeAndMetadata;
19716
- declare const index$4_getServiceId: typeof getServiceId;
19717
- declare const index$4_getServiceIdOrCurrent: typeof getServiceIdOrCurrent;
19718
- declare const index$4_inspect: typeof inspect;
19719
- declare const index$4_instructionArgumentTypeMap: typeof instructionArgumentTypeMap;
19720
- declare const index$4_isBrowser: typeof isBrowser;
19721
- declare const index$4_isTaggedError: typeof isTaggedError;
19722
- declare const index$4_lazyInspect: typeof lazyInspect;
19723
- declare const index$4_maybeTaggedErrorToString: typeof maybeTaggedErrorToString;
19724
- declare const index$4_measure: typeof measure;
19725
- declare const index$4_preimageLenAsU32: typeof preimageLenAsU32;
19726
- declare const index$4_resultToString: typeof resultToString;
19727
- declare const index$4_seeThrough: typeof seeThrough;
19728
- declare const index$4_slotsToPreimageStatus: typeof slotsToPreimageStatus;
19729
- declare const index$4_toMemoryOperation: typeof toMemoryOperation;
19730
- declare const index$4_tryAsMachineId: typeof tryAsMachineId;
19731
- declare const index$4_tryAsProgramCounter: typeof tryAsProgramCounter;
19732
- declare const index$4_writeServiceIdAsLeBytes: typeof writeServiceIdAsLeBytes;
19733
19257
  declare namespace index$4 {
19734
- export { index$4_AccumulationStateUpdate as AccumulationStateUpdate, index$4_ArgsDecoder as ArgsDecoder, index$4_ArgumentType as ArgumentType, index$4_BasicBlocks as BasicBlocks, index$4_CURRENT_SERVICE_ID as CURRENT_SERVICE_ID, index$4_EjectError as EjectError, index$4_ExtendedWitdthImmediateDecoder as ExtendedWitdthImmediateDecoder, index$4_ForgetPreimageError as ForgetPreimageError, index$4_HostCallMemory as HostCallMemory, index$4_HostCallRegisters as HostCallRegisters, index$4_HostCallResult as HostCallResult, index$4_ImmediateDecoder as ImmediateDecoder, index$4_MAX_U32 as MAX_U32, index$4_MAX_U32_BIG_INT as MAX_U32_BIG_INT, index$4_MachineInstance as MachineInstance, index$4_Mask as Mask, index$4_MemoryOperation as MemoryOperation, index$4_MemorySegment as MemorySegment, NO_OF_REGISTERS$1 as NO_OF_REGISTERS, index$4_NewServiceError as NewServiceError, index$4_NibblesDecoder as NibblesDecoder, index$4_PagesError as PagesError, index$4_PartiallyUpdatedState as PartiallyUpdatedState, index$4_PeekPokeError as PeekPokeError, index$4_PendingTransfer as PendingTransfer, index$4_PreimageStatusKind as PreimageStatusKind, index$4_Program as Program, index$4_ProgramDecoder as ProgramDecoder, index$4_ProvidePreimageError as ProvidePreimageError, DebuggerAdapter as Pvm, index$4_Registers as Registers, index$4_RequestPreimageError as RequestPreimageError, Result$2 as Result, index$4_RichTaggedError as RichTaggedError, index$4_SERVICE_ID_BYTES as SERVICE_ID_BYTES, index$4_SpiMemory as SpiMemory, index$4_SpiProgram as SpiProgram, index$4_TransferError as TransferError, index$4_UpdatePrivilegesError as UpdatePrivilegesError, index$4_WithDebug as WithDebug, index$4_ZeroVoidError as ZeroVoidError, index$4___OPAQUE_TYPE__ as __OPAQUE_TYPE__, index$4_asOpaqueType as asOpaqueType, index$4_assertEmpty as assertEmpty, index$4_assertNever as assertNever, index$m as block, index$t as bytes, index$4_check as check, index$4_clampU64ToU32 as clampU64ToU32, index$4_createResults as createResults, index$4_decodeStandardProgram as decodeStandardProgram, index$4_deepCloneMapWithArray as deepCloneMapWithArray, index$4_emptyRegistersBuffer as emptyRegistersBuffer, index$4_extractCodeAndMetadata as extractCodeAndMetadata, index$4_getServiceId as getServiceId, index$4_getServiceIdOrCurrent as getServiceIdOrCurrent, index$q as hash, codecServiceAccountInfoWithThresholdBalance as hostCallInfoAccount, index$4_inspect as inspect, index$4_instructionArgumentTypeMap as instructionArgumentTypeMap, index$7 as interpreter, index$4_isBrowser as isBrowser, index$4_isTaggedError as isTaggedError, index$4_lazyInspect as lazyInspect, index$4_maybeTaggedErrorToString as maybeTaggedErrorToString, index$4_measure as measure, index$s as numbers, index$4_preimageLenAsU32 as preimageLenAsU32, index$4_resultToString as resultToString, index$4_seeThrough as seeThrough, index$4_slotsToPreimageStatus as slotsToPreimageStatus, index$4_toMemoryOperation as toMemoryOperation, index$4_tryAsMachineId as tryAsMachineId, index$4_tryAsProgramCounter as tryAsProgramCounter, index$4_writeServiceIdAsLeBytes as writeServiceIdAsLeBytes };
19735
- export type { index$4_Args as Args, index$4_EnumMapping as EnumMapping, index$4_ErrorResult as ErrorResult, index$4_InsufficientFundsError as InsufficientFundsError, index$4_MachineId as MachineId, index$4_MachineResult as MachineResult, index$4_MachineStatus as MachineStatus, index$4_NoMachineError as NoMachineError, index$4_OK as OK, index$4_OkResult as OkResult, index$4_Opaque as Opaque, index$4_PartialState as PartialState, index$4_PreimageStatus as PreimageStatus, index$4_ProgramCounter as ProgramCounter, index$4_RefineExternalities as RefineExternalities, index$4_SegmentExportError as SegmentExportError, index$4_ServiceStateUpdate as ServiceStateUpdate, index$4_StateSlice as StateSlice, index$4_StringLiteral as StringLiteral, index$4_TRANSFER_MEMO_BYTES as TRANSFER_MEMO_BYTES, index$4_TaggedError as TaggedError, index$4_TokenOf as TokenOf, index$4_Uninstantiable as Uninstantiable, index$4_UnprivilegedError as UnprivilegedError, index$4_WithOpaque as WithOpaque };
19258
+ export {
19259
+ DebuggerAdapter as Pvm,
19260
+ };
19736
19261
  }
19737
19262
 
19738
19263
  declare const ENTROPY_BYTES = 32;
package/index.js CHANGED
@@ -17715,79 +17715,7 @@ class DebuggerAdapter {
17715
17715
 
17716
17716
  var index$4 = /*#__PURE__*/Object.freeze({
17717
17717
  __proto__: null,
17718
- AccumulationStateUpdate: AccumulationStateUpdate,
17719
- ArgsDecoder: ArgsDecoder,
17720
- get ArgumentType () { return ArgumentType; },
17721
- BasicBlocks: BasicBlocks,
17722
- CURRENT_SERVICE_ID: CURRENT_SERVICE_ID,
17723
- get EjectError () { return EjectError; },
17724
- ExtendedWitdthImmediateDecoder: ExtendedWitdthImmediateDecoder,
17725
- get ForgetPreimageError () { return ForgetPreimageError; },
17726
- HostCallMemory: HostCallMemory,
17727
- HostCallRegisters: HostCallRegisters,
17728
- HostCallResult: HostCallResult,
17729
- ImmediateDecoder: ImmediateDecoder,
17730
- InsufficientFundsError: InsufficientFundsError,
17731
- MachineInstance: MachineInstance,
17732
- Mask: Mask,
17733
- get MemoryOperation () { return MemoryOperation; },
17734
- MemorySegment: MemorySegment,
17735
- NO_OF_REGISTERS: NO_OF_REGISTERS$1,
17736
- get NewServiceError () { return NewServiceError; },
17737
- NibblesDecoder: NibblesDecoder,
17738
- NoMachineError: NoMachineError,
17739
- OK: OK,
17740
- get PagesError () { return PagesError; },
17741
- PartiallyUpdatedState: PartiallyUpdatedState,
17742
- get PeekPokeError () { return PeekPokeError; },
17743
- PendingTransfer: PendingTransfer,
17744
- get PreimageStatusKind () { return PreimageStatusKind; },
17745
- Program: Program,
17746
- ProgramDecoder: ProgramDecoder,
17747
- get ProvidePreimageError () { return ProvidePreimageError; },
17748
- Pvm: DebuggerAdapter,
17749
- Registers: Registers,
17750
- get RequestPreimageError () { return RequestPreimageError; },
17751
- Result: Result$1,
17752
- SERVICE_ID_BYTES: SERVICE_ID_BYTES,
17753
- SegmentExportError: SegmentExportError,
17754
- SpiMemory: SpiMemory,
17755
- SpiProgram: SpiProgram,
17756
- TRANSFER_MEMO_BYTES: TRANSFER_MEMO_BYTES,
17757
- get TransferError () { return TransferError; },
17758
- UnprivilegedError: UnprivilegedError,
17759
- get UpdatePrivilegesError () { return UpdatePrivilegesError; },
17760
- WithDebug: WithDebug,
17761
- get ZeroVoidError () { return ZeroVoidError; },
17762
- asOpaqueType: asOpaqueType,
17763
- assertEmpty: assertEmpty,
17764
- assertNever: assertNever,
17765
- block: index$m,
17766
- bytes: index$t,
17767
- check: check,
17768
- clampU64ToU32: clampU64ToU32,
17769
- createResults: createResults,
17770
- decodeStandardProgram: decodeStandardProgram,
17771
- emptyRegistersBuffer: emptyRegistersBuffer,
17772
- extractCodeAndMetadata: extractCodeAndMetadata,
17773
- getServiceId: getServiceId,
17774
- getServiceIdOrCurrent: getServiceIdOrCurrent,
17775
- hash: index$p,
17776
- hostCallInfoAccount: codecServiceAccountInfoWithThresholdBalance,
17777
- inspect: inspect,
17778
- instructionArgumentTypeMap: instructionArgumentTypeMap,
17779
- interpreter: index$8,
17780
- isBrowser: isBrowser,
17781
- lazyInspect: lazyInspect,
17782
- measure: measure,
17783
- numbers: index$s,
17784
- resultToString: resultToString,
17785
- seeThrough: seeThrough,
17786
- slotsToPreimageStatus: slotsToPreimageStatus,
17787
- toMemoryOperation: toMemoryOperation,
17788
- tryAsMachineId: tryAsMachineId,
17789
- tryAsProgramCounter: tryAsProgramCounter,
17790
- writeServiceIdAsLeBytes: writeServiceIdAsLeBytes
17718
+ Pvm: DebuggerAdapter
17791
17719
  });
17792
17720
 
17793
17721
  const ENTROPY_BYTES = 32;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@typeberry/lib",
3
- "version": "0.4.0-1ad1b89",
3
+ "version": "0.4.0-2473e55",
4
4
  "main": "index.js",
5
5
  "author": "Fluffy Labs",
6
6
  "license": "MPL-2.0",