From de586767f51432e5d89f6fcffee07c488fdeeb7b Mon Sep 17 00:00:00 2001 From: Egor Chesakov Date: Mon, 4 Jun 2018 10:08:22 -0700 Subject: Work in VM towards cross-bitness crossgen (#18245) * Replace sizeof expressions with target-specific constants: * sizeof(ObjHeader) -> OBJHEADER_SIZE * sizeof(Object) -> OBJECT_SIZE * ObjSizeOf(Object) -> OBJECT_BASESIZE * sizeof(ArrayBase) -> ARRAYBASE_SIZE * ObjSizeOf(ArrayBase) -> ARRAYBASE_BASESIZE * Remove ObjSizeOf macro * Use OBJECT_SIZE in ArrayBase::GetBoundsOffset * Cast ppObj to CORCOMPILE_GCREFMAP_TOKENS* before dereferencing in FakePromote * LOG2_PTRSIZE should depend on _TARGET_64BIT_ --- src/vm/methodtable.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/vm/methodtable.cpp') diff --git a/src/vm/methodtable.cpp b/src/vm/methodtable.cpp index af4b8f7121..75b4c6ce49 100644 --- a/src/vm/methodtable.cpp +++ b/src/vm/methodtable.cpp @@ -942,7 +942,7 @@ MethodTable* CreateMinimalMethodTable(Module* pContainingModule, pMT->SetLoaderModule(pContainingModule); pMT->SetLoaderAllocator(pContainingModule->GetLoaderAllocator()); pMT->SetInternalCorElementType(ELEMENT_TYPE_CLASS); - pMT->SetBaseSize(ObjSizeOf(Object)); + pMT->SetBaseSize(OBJECT_BASESIZE); #ifdef _DEBUG pClass->SetDebugClassName("dynamicClass"); -- cgit v1.2.3