Source/Packages

Runtime.NativePhysicalNative

packages/execution/src/Runtime/NativePhysicalNative.alpha

3,420 lines207 declarations187.4 KiBSHA-256 9c16b0741974

def · lines 3283–3387

nativePhysicalNativeUnpackBlock

Full file
3283def nativePhysicalNativeUnpackBlock =
3284  (lambda unrestricted tail : (family X86NativeAssembly) .
3285    (nativePhysicalNativeLabel
3286      nativePhysicalNativeLabelUnpack
3287      (npLoad64 npRAX npR15 nativePhysicalNativeD8
3288        (npCompareImmediate npRAX (nativePhysicalNativeI32Byte (byte 1))
3289          (npJumpIf npNotZero nativePhysicalNativeLabelFatalUnpack
3290            (npLoad64 npR13 npR15 (npD (byte 16))
3291              (npLoad64 npR12 npR15 (npD (byte 24))
3292                (npTest npR13
3293                  (npJumpIf npZero nativePhysicalNativeLabelFatalUnpack
3294                    -- source and its end; a packed length that wraps refuses
3295                    (npMove npRBX npR15
3296                      (npStep npRBX 32
3297                        (npMove npR8 npRBX
3298                          (npAdd npR8 npR12
3299                            (npCompare npR8 npRBX
3300                              (npJumpIf npBelow nativePhysicalNativeLabelFatalUnpack
3301                                -- output: the page after the file's last page, U page-rounded
3302                                (npMove npR14 npR8
3303                                  (npPageRound npR14
3304                                    (npMove npR10 npR13
3305                                      (npPageRound npR10
3306                                        (npCompare npR10 npR13
3307                                          (npJumpIf npBelow nativePhysicalNativeLabelFatalUnpack
3308                                            (npProtectUnpacked 3
3309                                              (npMove npRDI npR14
3310                                                (npMove npR9 npR14
3311                                                  (npAdd npR9 npR13
3312                                                    (nativePhysicalNativeLabel
3313                                                      nativePhysicalNativeLabelUnpackSequence
3314                                                      (npCompare npRBX npR8
3315                                                        (npJumpIf npBelow nativePhysicalNativeLabelUnpackToken
3316                                                          (nativePhysicalNativeJump
3317                                                            nativePhysicalNativeLabelUnpackEnd
3318                                                            (nativePhysicalNativeLabel
3319                                                              nativePhysicalNativeLabelUnpackToken
3320                                                              (npLoad8 npRCX npRBX (byte 0)
3321                                                                (npStep npRBX 1
3322                                                                  -- literals: the token's high nibble, continued at 15
3323                                                                  (npMove npRDX npRCX
3324                                                                    (nativePhysicalNativeEmit
3325                                                                      (constructor X86NativeInstruction X86NativeShiftRightImmediate64 npRDX (nativePhysicalNativeImmediate8 (byte 4)))
3326                                                                      (npCompareImmediate npRDX (nativePhysicalNativeI32Byte (byte 15))
3327                                                                        (npJumpIf npNotZero nativePhysicalNativeLabelUnpackLiterals
3328                                                                          (npUnpackLength
3329                                                                            nativePhysicalNativeLabelUnpackLiteralLength
3330                                                                            nativePhysicalNativeLabelUnpackLiteralByte
3331                                                                            (nativePhysicalNativeLabel
3332                                                                              nativePhysicalNativeLabelUnpackLiterals
3333                                                                              (npUnpackRoom npR8 npRBX
3334                                                                                (npUnpackRoom npR9 npRDI
3335                                                                                  (npUnpackCopy
3336                                                                                    npRBX
3337                                                                                    nativePhysicalNativeLabelUnpackLiteralCopy
3338                                                                                    nativePhysicalNativeLabelUnpackLiteralsDone
3339                                                                                    (nativePhysicalNativeLabel
3340                                                                                      nativePhysicalNativeLabelUnpackLiteralsDone
3341                                                                                      -- the last sequence ends with its literals
3342                                                                                      (npCompare npRBX npR8
3343                                                                                        (npJumpIf npZero nativePhysicalNativeLabelUnpackEnd
3344                                                                                          -- distance: two bytes, little-endian, 1 .. produced
3345                                                                                          (npImmediate npRDX 2
3346                                                                                            (npUnpackRoom npR8 npRBX
3347                                                                                              (npLoad8 npRAX npRBX (byte 0)
3348                                                                                                (npLoad8 npRSI npRBX (byte 1)
3349                                                                                                  (nativePhysicalNativeEmit
3350                                                                                                    (nativePhysicalNativeShiftLeft npRSI (nativePhysicalNativeImmediate8 (byte 8)))
3351                                                                                                    (nativePhysicalNativeEmit
3352                                                                                                      (constructor X86NativeInstruction X86NativeOrRegister64 npRSI npRAX)
3353                                                                                                      (npStep npRBX 2
3354                                                                                                        (npTest npRAX
3355                                                                                                          (npJumpIf npZero nativePhysicalNativeLabelFatalUnpack
3356                                                                                                            (npMove npRSI npRDI
3357                                                                                                              (npSubtract npRSI npR14
3358                                                                                                                (npCompare npRSI npRAX
3359                                                                                                                  (npJumpIf npBelow nativePhysicalNativeLabelFatalUnpack
3360                                                                                                                    -- match length: the low nibble plus 4, continued at 15
3361                                                                                                                    (npMove npRDX npRCX
3362                                                                                                                      (nativePhysicalNativeEmit
3363                                                                                                                        (constructor X86NativeInstruction X86NativeAndImmediate64 npRDX (x86NativeImmediate32FromNatural 15))
3364                                                                                                                        (npCompareImmediate npRDX (nativePhysicalNativeI32Byte (byte 15))
3365                                                                                                                          (npJumpIf npNotZero nativePhysicalNativeLabelUnpackMatch
3366                                                                                                                            (npUnpackLength
3367                                                                                                                              nativePhysicalNativeLabelUnpackMatchLength
3368                                                                                                                              nativePhysicalNativeLabelUnpackMatchByte
3369                                                                                                                              (nativePhysicalNativeLabel
3370                                                                                                                                nativePhysicalNativeLabelUnpackMatch
3371                                                                                                                                (npStep npRDX 4
3372                                                                                                                                  (npUnpackRoom npR9 npRDI
3373                                                                                                                                    (npMove npRSI npRDI
3374                                                                                                                                      (npSubtract npRSI npRAX
3375                                                                                                                                        (npUnpackCopy
3376                                                                                                                                          npRSI
3377                                                                                                                                          nativePhysicalNativeLabelUnpackMatchCopy
3378                                                                                                                                          nativePhysicalNativeLabelUnpackSequence
3379                                                                                                                                          (nativePhysicalNativeLabel
3380                                                                                                                                            nativePhysicalNativeLabelUnpackEnd
3381                                                                                                                                            (npCompare npRDI npR9
3382                                                                                                                                              (npJumpIf npNotZero nativePhysicalNativeLabelFatalUnpack
3383                                                                                                                                                (npProtectUnpacked 5
3384                                                                                                                                                  (npMove npR15 npR14
3385                                                                                                                                                    (nativePhysicalNativeJump
3386                                                                                                                                                      nativePhysicalNativeLabelImageReady
3387                                                                                                                                                      tail))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))

The compiler supplied declaration spans and resolved links from this source snapshot. This page does not assert that this file belongs to a checked closure.