[Local GC] Remove static fields from GC interface (dotnet/coreclr#10566)
authorSean Gillespie <sean@swgillespie.me>
Sat, 1 Apr 2017 21:25:07 +0000 (14:25 -0700)
committerGitHub <noreply@github.com>
Sat, 1 Apr 2017 21:25:07 +0000 (14:25 -0700)
commite92883c54e60ec3f95e41529abd438abf59169f2
treeec936a9ee5d46f06d6d529de4344c8d5bfa78a18
parent2e3635d6918bff0e2275d34ba8dbbe2afeb87c00
[Local GC] Remove static fields from GC interface (dotnet/coreclr#10566)

* Remove max_generation from GC interface

* [Local GC] Clean up the GC interface by removing all static fields
from it:
  1) gcHeapType is replaced by g_heap_type (EE side) and g_gc_heap_type
     (GC side), each of which is set on initialization. g_heap_type is
     read by the DAC to determine what kind of heap is being used.
  2) maxGeneration is not necessary due to the GC DAC changes.

* Rebase against master

* Comments and cleanup

* Use a heap allocation instead of alloca

* Code review feedback: remove a redundant cast and allocate generation count table once, on first use

* Address code review feedback: cache some calls to GetMaxGeneration

Commit migrated from https://github.com/dotnet/coreclr/commit/ed57233f4d26114d45b1293ced80a09f879f72cf
17 files changed:
src/coreclr/src/debug/daccess/enummem.cpp
src/coreclr/src/debug/daccess/request.cpp
src/coreclr/src/debug/daccess/request_svr.cpp
src/coreclr/src/gc/gc.cpp
src/coreclr/src/gc/gc.h
src/coreclr/src/gc/gccommon.cpp
src/coreclr/src/gc/gcinterface.dac.h
src/coreclr/src/gc/gcinterface.dacvars.def
src/coreclr/src/gc/gcinterface.h
src/coreclr/src/inc/dacvars.h
src/coreclr/src/vm/ceemain.cpp
src/coreclr/src/vm/crossgencompile.cpp
src/coreclr/src/vm/gcenv.ee.cpp
src/coreclr/src/vm/gcheaputilities.cpp
src/coreclr/src/vm/gcheaputilities.h
src/coreclr/src/vm/threads.cpp
src/coreclr/src/vm/threads.h