summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/jit/gentree.cpp26
-rw-r--r--src/vm/amd64/cgencpu.h6
-rw-r--r--tests/src/GC/Scenarios/FinalizeTimeout/FinalizeTimeout.cs2
3 files changed, 16 insertions, 18 deletions
diff --git a/src/jit/gentree.cpp b/src/jit/gentree.cpp
index d97e67d58f..9d717fb5cc 100644
--- a/src/jit/gentree.cpp
+++ b/src/jit/gentree.cpp
@@ -15789,23 +15789,19 @@ bool GenTree::IsFieldAddr(Compiler* comp, GenTreePtr* pObj, GenTreePtr* pStatic,
baseAddr = gtOp.gtOp1;
}
}
- // Check if "this" has a zero-offset annotation.
- else if (comp->GetZeroOffsetFieldMap()->Lookup(this, &newFldSeq))
- {
- baseAddr = this;
- mustBeStatic = true;
- }
- else if (OperGet() == GT_CNS_INT && gtIntCon.gtFieldSeq != nullptr)
- {
- // Address is a literal constant; must be a static field.
- newFldSeq = gtIntCon.gtFieldSeq;
- baseAddr = this;
- mustBeStatic = true;
- }
else
{
- // This is not a field address.
- return false;
+ // Check if "this" has a zero-offset annotation.
+ if (!comp->GetZeroOffsetFieldMap()->Lookup(this, &newFldSeq))
+ {
+ // If not, this is not a field address.
+ return false;
+ }
+ else
+ {
+ baseAddr = this;
+ mustBeStatic = true;
+ }
}
// If not we don't have a field seq, it's not a field address.
diff --git a/src/vm/amd64/cgencpu.h b/src/vm/amd64/cgencpu.h
index 258ac38915..769f4029ee 100644
--- a/src/vm/amd64/cgencpu.h
+++ b/src/vm/amd64/cgencpu.h
@@ -65,14 +65,16 @@ EXTERN_C void FastCallFinalizeWorker(Object *obj, PCODE funcPtr);
#define CACHE_LINE_SIZE 64 // Current AMD64 processors have 64-byte cache lines as per AMD64 optmization manual
#define LOG2SLOT LOG2_PTRSIZE
-#define ENREGISTERED_RETURNTYPE_INTEGER_MAXSIZE 8 // bytes
-#define ENREGISTERED_PARAMTYPE_MAXSIZE 8 // bytes
#ifdef UNIX_AMD64_ABI
+#define ENREGISTERED_RETURNTYPE_INTEGER_MAXSIZE 16 // bytes
+#define ENREGISTERED_PARAMTYPE_MAXSIZE 16 // bytes
#define ENREGISTERED_RETURNTYPE_MAXSIZE 16 // bytes
#define CALLDESCR_ARGREGS 1 // CallDescrWorker has ArgumentRegister parameter
#define CALLDESCR_FPARGREGS 1 // CallDescrWorker has FloatArgumentRegisters parameter
#else
+#define ENREGISTERED_RETURNTYPE_INTEGER_MAXSIZE 8 // bytes
+#define ENREGISTERED_PARAMTYPE_MAXSIZE 8 // bytes
#define ENREGISTERED_RETURNTYPE_MAXSIZE 8 // bytes
#define COM_STUBS_SEPARATE_FP_LOCATIONS
#define CALLDESCR_REGTYPEMAP 1
diff --git a/tests/src/GC/Scenarios/FinalizeTimeout/FinalizeTimeout.cs b/tests/src/GC/Scenarios/FinalizeTimeout/FinalizeTimeout.cs
index 0935b4524f..0fda8172e4 100644
--- a/tests/src/GC/Scenarios/FinalizeTimeout/FinalizeTimeout.cs
+++ b/tests/src/GC/Scenarios/FinalizeTimeout/FinalizeTimeout.cs
@@ -47,7 +47,7 @@ public class FinalizeTimeout
private class BlockingFinalizerOnShutdown
{
- public volatile static bool finalizerCompletedOnce = false;
+ public static bool finalizerCompletedOnce = false;
public bool isLastObject = false;
~BlockingFinalizerOnShutdown()