| ... | @@ -603,6 +603,17 @@ pub const MAP = struct { | ... | @@ -603,6 +603,17 @@ pub const MAP = struct { |
| 603 | pub const ANON = 0x1000; | 603 | pub const ANON = 0x1000; |
| 604 | pub const ANONYMOUS = ANON; | 604 | pub const ANONYMOUS = ANON; |
| 605 | pub const STACK = 0x2000; | 605 | pub const STACK = 0x2000; |
| | 606 | |
| | 607 | pub const ALIGNMENT_SHIFT = 24; |
| | 608 | pub fn ALIGNED(n: u32) u32 { |
| | 609 | return n << ALIGNMENT_SHIFT; |
| | 610 | } |
| | 611 | pub const ALIGNMENT_64KB = MAP.ALIGNED(0xff); |
| | 612 | pub const ALIGNMENT_16MB = MAP.ALIGNED(16); |
| | 613 | pub const ALIGNMENT_4GB = MAP.ALIGNED(32); |
| | 614 | pub const ALIGNMENT_1TB = MAP.ALIGNED(40); |
| | 615 | pub const ALIGNMENT_256TB = MAP.ALIGNED(48); |
| | 616 | pub const ALIGNMENT_64PB = MAP.ALIGNED(56); |
| 606 | }; | 617 | }; |
| 607 | | 618 | |
| 608 | pub const MSF = struct { | 619 | pub const MSF = struct { |