@@ -6803,7 +6803,7 @@ bool gc_heap::virtual_alloc_commit_for_heap (void* addr, size_t size, int h_numb
68036803 return GCToOSInterface::VirtualCommit(addr, size);
68046804}
68056805
6806- bool gc_heap::virtual_commit (void* address, size_t size, gc_oh_num oh, int h_number, bool* hard_limit_exceeded_p )
6806+ bool gc_heap::virtual_commit (void* address, size_t size, gc_oh_num oh, int h_number)
68076807{
68086808#ifndef HOST_64BIT
68096809 assert (heap_hard_limit == 0);
@@ -6841,9 +6841,6 @@ bool gc_heap::virtual_commit (void* address, size_t size, gc_oh_num oh, int h_nu
68416841
68426842 check_commit_cs.Leave();
68436843
6844- if (hard_limit_exceeded_p)
6845- *hard_limit_exceeded_p = exceeded_p;
6846-
68476844 if (exceeded_p)
68486845 {
68496846 dprintf (1, ("can't commit %Ix for %Id bytes > HARD LIMIT %Id", (size_t)address, size, heap_hard_limit));
@@ -14220,13 +14217,10 @@ BOOL gc_heap::a_size_fit_p (size_t size, uint8_t* alloc_pointer, uint8_t* alloc_
1422014217}
1422114218
1422214219// Grow by committing more pages
14223- BOOL gc_heap::grow_heap_segment (heap_segment* seg, uint8_t* high_address, bool* hard_limit_exceeded_p )
14220+ BOOL gc_heap::grow_heap_segment (heap_segment* seg, uint8_t* high_address)
1422414221{
1422514222 assert (high_address <= heap_segment_reserved (seg));
1422614223
14227- if (hard_limit_exceeded_p)
14228- *hard_limit_exceeded_p = false;
14229-
1423014224 //return 0 if we are at the end of the segment.
1423114225 if (align_on_page (high_address) > heap_segment_reserved (seg))
1423214226 return FALSE;
@@ -14245,7 +14239,7 @@ BOOL gc_heap::grow_heap_segment (heap_segment* seg, uint8_t* high_address, bool*
1424514239 "Growing heap_segment: %Ix high address: %Ix\n",
1424614240 (size_t)seg, (size_t)high_address);
1424714241
14248- bool ret = virtual_commit (heap_segment_committed (seg), c_size, heap_segment_oh (seg), heap_number, hard_limit_exceeded_p );
14242+ bool ret = virtual_commit (heap_segment_committed (seg), c_size, heap_segment_oh (seg), heap_number);
1424914243 if (ret)
1425014244 {
1425114245 heap_segment_committed (seg) += c_size;
@@ -16130,7 +16124,6 @@ BOOL gc_heap::a_fit_segment_end_p (int gen_number,
1613016124{
1613116125 *commit_failed_p = FALSE;
1613216126 size_t limit = 0;
16133- bool hard_limit_short_seg_end_p = false;
1613416127#ifdef BACKGROUND_GC
1613516128 int cookie = -1;
1613616129#endif //BACKGROUND_GC
@@ -16169,21 +16162,13 @@ BOOL gc_heap::a_fit_segment_end_p (int gen_number,
1616916162 (end - allocated),
1617016163 gen_number, align_const);
1617116164
16172- if (grow_heap_segment (seg, (allocated + limit), &hard_limit_short_seg_end_p ))
16165+ if (grow_heap_segment (seg, (allocated + limit)))
1617316166 {
1617416167 goto found_fit;
1617516168 }
1617616169 else
1617716170 {
16178- if (!hard_limit_short_seg_end_p)
16179- {
16180- dprintf (2, ("can't grow segment, doing a full gc"));
16181- *commit_failed_p = TRUE;
16182- }
16183- else
16184- {
16185- assert (heap_hard_limit);
16186- }
16171+ *commit_failed_p = TRUE;
1618716172 }
1618816173 }
1618916174
@@ -17796,6 +17781,7 @@ void gc_heap::balance_heaps (alloc_context* acontext)
1779617781
1779717782ptrdiff_t gc_heap::get_balance_heaps_uoh_effective_budget (int generation_num)
1779817783{
17784+ #ifndef USE_REGIONS
1779917785 if (heap_hard_limit)
1780017786 {
1780117787 const ptrdiff_t free_list_space = generation_free_list_space (generation_of (generation_num));
@@ -17807,6 +17793,7 @@ ptrdiff_t gc_heap::get_balance_heaps_uoh_effective_budget (int generation_num)
1780717793 return free_list_space - allocated;
1780817794 }
1780917795 else
17796+ #endif // !USE_REGIONS
1781017797 {
1781117798 return dd_new_allocation (dynamic_data_of (generation_num));
1781217799 }
0 commit comments