This repository has been archived by the owner on Nov 1, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 510
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
FuncEval #1 - Introduce a DAC accessible global variable in the runti…
…me to store the address of the method to be called in a FuncEval. [tfs-changeset: 1645909]
- Loading branch information
Showing
3 changed files
with
55 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
// See the LICENSE file in the project root for more information. | ||
|
||
#include "common.h" | ||
#include "CommonTypes.h" | ||
#include "DebugFuncEval.h" | ||
|
||
GVAL_IMPL_INIT(UInt64, g_FuncEvalTarget, 0); | ||
|
||
#ifndef DACCESS_COMPILE | ||
|
||
void* DebugFuncEval::GetFuncEvalTarget() | ||
{ | ||
return (void*)g_FuncEvalTarget; | ||
} | ||
|
||
#endif //!DACCESS_COMPILE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
// See the LICENSE file in the project root for more information. | ||
// ----------------------------------------------------------------------------------------------------------- | ||
// Support for evaluating expression in the debuggee during debugging | ||
// ----------------------------------------------------------------------------------------------------------- | ||
|
||
#ifndef __DEBUG_FUNC_EVAL_H__ | ||
#define __DEBUG_FUNC_EVAL_H__ | ||
|
||
#include "common.h" | ||
#include "CommonTypes.h" | ||
#include "CommonMacros.h" | ||
#include "daccess.h" | ||
|
||
#ifndef DACCESS_COMPILE | ||
|
||
class DebugFuncEval | ||
{ | ||
public: | ||
/// <summary> | ||
/// Retrieve the global FuncEval target address | ||
/// </summary> | ||
/// <remarks> | ||
/// During debugging, if a FuncEval is requested, | ||
/// The func eval infrastructure needs to know which function to call, and | ||
/// It will call this API to obtain the target address. | ||
/// By the time, the value should have been set through the UpdateFuncEvalTarget() method | ||
/// on the ISosRedhawk7 interface. | ||
/// </remarks> | ||
static void* GetFuncEvalTarget(); | ||
}; | ||
|
||
#endif //!DACCESS_COMPILE | ||
|
||
#endif // __DEBUG_FUNC_EVAL_H__ |