[Lldb-commits] [PATCH] D9404: Expression evaluation, a new ThreadPlanCallFunctionNoJIT for executing a function call on target via register manipulation
Ewan Crawford
ewan at codeplay.com
Thu Jul 9 10:03:32 PDT 2015
EwanCrawford updated this revision to Diff 29343.
EwanCrawford added a comment.
To address that final point of not doing any code execution at all for certain targets. I used the CanJIT() idea to create a similar CanInterpretFunctionCalls() member function of Process.
This means that we can just pass the value of the m_can_interpret_function_calls variable to CanInterpret() instead of the Arch or execution context.
Since interpreting function calls is a special case for hexagon right now the value defaults to false, and is only set to true by the hexagon dynamic loader.
In the future though when more targets support this feature, CanInterpretFunctionCalls() would be enabled by default and then specifically disabled by targets.
Using the example of the OSX kernel, which can't do any code execution, the patch explicitly sets jitting and interpreting function calls to false in the dynamic loader using an added CanRunCode() function.
Repository:
rL LLVM
http://reviews.llvm.org/D9404
Files:
include/lldb/Expression/IRInterpreter.h
include/lldb/Expression/IRMemoryMap.h
include/lldb/Target/ABI.h
include/lldb/Target/Process.h
include/lldb/Target/ThreadPlanCallFunction.h
include/lldb/Target/ThreadPlanCallFunctionUsingABI.h
lldb.xcodeproj/project.pbxproj
source/Expression/ClangExpressionParser.cpp
source/Expression/ClangUserExpression.cpp
source/Expression/IRInterpreter.cpp
source/Expression/IRMemoryMap.cpp
source/Plugins/ABI/SysV-hexagon/ABISysV_hexagon.cpp
source/Plugins/DynamicLoader/Darwin-Kernel/DynamicLoaderDarwinKernel.cpp
source/Plugins/DynamicLoader/Hexagon-DYLD/DynamicLoaderHexagonDYLD.cpp
source/Target/CMakeLists.txt
source/Target/Process.cpp
source/Target/ThreadPlanCallFunction.cpp
source/Target/ThreadPlanCallFunctionUsingABI.cpp
test/expression_command/call-function/TestCallUserDefinedFunction.py
test/expression_command/call-function/main.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D9404.29343.patch
Type: text/x-patch
Size: 43254 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20150709/e496a157/attachment.bin>
More information about the lldb-commits
mailing list