Source/Packages

Compiler.ELF

packages/compiler/src/Compiler/ELF.alpha

282 lines59 declarations11.1 KiBSHA-256 88f2369f1a73

def · lines 199–210

fixedZeroELFHeaderSparseLargeFor

Full file
199def fixedZeroELFHeaderSparseLargeFor =
200  (lambda unrestricted machine : Byte .
201    (lambda unrestricted machineCode : Bytes .
202      (let unrestricted fileExtent =
203        (modelWord64FromNaturalTruncated
204          (naturalAdd (byte-to-nat (byte 120)) (naturalAdd (bytes-length machineCode) (bytes-length (elfPagePadding machineCode)))))
205      in
206        (bytes-append
207          (elfHeaderPrefixFor machine)
208          (bytes-append
209            (elfModelWord64Bytes fileExtent)
210            (bytes-append elfLoadSize4M elfHeaderAlign))))))

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.