Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Fix build breaks in GC sample project #5

Merged
merged 1 commit into from
Feb 2, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions src/gc/gc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3894,9 +3894,6 @@ BOOL reserve_initial_memory (size_t normal_size, size_t large_size, size_t num_h
g_lowest_address = MAX_PTR;
g_highest_address = 0;

// Try to get the data all at once
ptrdiff_t allatonce_delta;

if (((size_t)MAX_PTR - large_size) < normal_size)
{
// we are already overflowing with just one heap.
Expand Down
10 changes: 10 additions & 0 deletions src/gc/sample/gcenv.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,16 @@ void * ClrVirtualAlloc(
return VirtualAlloc(lpAddress, dwSize, flAllocationType, flProtect);
}

void * ClrVirtualAllocAligned(
void * lpAddress,
size_t dwSize,
uint32_t flAllocationType,
uint32_t flProtect,
size_t dwAlignment)
{
return VirtualAlloc(lpAddress, dwSize, flAllocationType, flProtect);
}

bool ClrVirtualFree(
void * lpAddress,
size_t dwSize,
Expand Down
7 changes: 7 additions & 0 deletions src/gc/sample/gcenv.h
Original file line number Diff line number Diff line change
Expand Up @@ -692,6 +692,13 @@ void * ClrVirtualAlloc(
uint32_t flAllocationType,
uint32_t flProtect);

void * ClrVirtualAllocAligned(
void * lpAddress,
size_t dwSize,
uint32_t flAllocationType,
uint32_t flProtect,
size_t dwAlignment);

bool ClrVirtualFree(
void * lpAddress,
size_t dwSize,
Expand Down