summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Kotas <jkotas@microsoft.com>2015-03-06 08:52:41 -0800
committerJan Kotas <jkotas@microsoft.com>2015-03-06 08:52:41 -0800
commit894d0fd00826c79e253a45b469536d153c1c6f63 (patch)
tree41d5fd567b0c64357a9e7dd42894df4911c606de
parent3e9b95e7f10ec125a48acbe6d620248c4b6e473f (diff)
downloadcoreclr-894d0fd00826c79e253a45b469536d153c1c6f63.tar.gz
coreclr-894d0fd00826c79e253a45b469536d153c1c6f63.tar.bz2
coreclr-894d0fd00826c79e253a45b469536d153c1c6f63.zip
Fix trashing of P/Invoke return value by GC probe
-rw-r--r--src/jit/codegenxarch.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/jit/codegenxarch.cpp b/src/jit/codegenxarch.cpp
index 1149836466..064e10fc3c 100644
--- a/src/jit/codegenxarch.cpp
+++ b/src/jit/codegenxarch.cpp
@@ -2274,7 +2274,13 @@ CodeGen::genCodeForTreeNode(GenTreePtr treeNode)
inst_JMP(genJumpKindForOper(GT_EQ, true), skipLabel);
// emit the call to the EE-helper that stops for GC (or other reasons)
- genEmitHelperCall(CORINFO_HELP_STOP_FOR_GC, 0, EA_UNKNOWN);
+
+ genEmitHelperCall(CORINFO_HELP_STOP_FOR_GC, 0, EA_UNKNOWN
+#ifdef _TARGET_AMD64_
+ , REG_ECX
+#endif
+ );
+
genDefineTempLabel(skipLabel);
}
break;