| ... | @@ -544,13 +544,13 @@ pub fn testAllocatorAlignedShrink(base_allocator: mem.Allocator) !void { | ... | @@ -544,13 +544,13 @@ pub fn testAllocatorAlignedShrink(base_allocator: mem.Allocator) !void { |
| 544 | var slice = try allocator.alignedAlloc(u8, .@"16", alloc_size); | 544 | var slice = try allocator.alignedAlloc(u8, .@"16", alloc_size); |
| 545 | defer allocator.free(slice); | 545 | defer allocator.free(slice); |
| 546 | | 546 | |
| 547 | var stuff_to_free = std.array_list.Managed([]align(16) u8).init(debug_allocator); | 547 | var stuff_to_free: std.ArrayList([]align(16) u8) = .empty; |
| 548 | // On Windows, VirtualAlloc returns addresses aligned to a 64K boundary, | 548 | // On Windows, VirtualAlloc returns addresses aligned to a 64K boundary, |
| 549 | // which is 16 pages, hence the 32. This test may require to increase | 549 | // which is 16 pages, hence the 32. This test may require to increase |
| 550 | // the size of the allocations feeding the `allocator` parameter if they | 550 | // the size of the allocations feeding the `allocator` parameter if they |
| 551 | // fail, because of this high over-alignment we want to have. | 551 | // fail, because of this high over-alignment we want to have. |
| 552 | while (@intFromPtr(slice.ptr) == mem.alignForward(usize, @intFromPtr(slice.ptr), pageSize() * 32)) { | 552 | while (@intFromPtr(slice.ptr) == mem.alignForward(usize, @intFromPtr(slice.ptr), pageSize() * 32)) { |
| 553 | try stuff_to_free.append(slice); | 553 | try stuff_to_free.append(debug_allocator, slice); |
| 554 | slice = try allocator.alignedAlloc(u8, .@"16", alloc_size); | 554 | slice = try allocator.alignedAlloc(u8, .@"16", alloc_size); |
| 555 | } | 555 | } |
| 556 | while (stuff_to_free.pop()) |item| { | 556 | while (stuff_to_free.pop()) |item| { |