summaryrefslogtreecommitdiffstats
path: root/lldb/source/Target/Target.cpp
diff options
context:
space:
mode:
authorSean Callanan <scallanan@apple.com>2016-09-26 20:18:51 +0000
committerSean Callanan <scallanan@apple.com>2016-09-26 20:18:51 +0000
commit5deb06eb43c73ded9debc59a87947a91649c94c0 (patch)
tree0e2413150b07544fb54fae4fff70ddb62036af6c /lldb/source/Target/Target.cpp
parentd543def21097bc245dfc009aee421e8511b24b57 (diff)
downloadbcm5719-llvm-5deb06eb43c73ded9debc59a87947a91649c94c0.tar.gz
bcm5719-llvm-5deb06eb43c73ded9debc59a87947a91649c94c0.zip
Added a setting that enables saving all .o files from a given JIT expression.
This allows debugging of the JIT and other analyses of the internals of the expression parser. I've also added a testcase that verifies that the setting works correctly when off and on. llvm-svn: 282434
Diffstat (limited to 'lldb/source/Target/Target.cpp')
-rw-r--r--lldb/source/Target/Target.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/lldb/source/Target/Target.cpp b/lldb/source/Target/Target.cpp
index ee7eab71c6a..f4a91192cfd 100644
--- a/lldb/source/Target/Target.cpp
+++ b/lldb/source/Target/Target.cpp
@@ -3246,6 +3246,8 @@ static PropertyDefinition g_properties[] = {
nullptr, "Automatically apply fix-it hints to expressions."},
{"notify-about-fixits", OptionValue::eTypeBoolean, false, true, nullptr,
nullptr, "Print the fixed expression text."},
+ {"save-jit-objects", OptionValue::eTypeBoolean, false, false, nullptr,
+ nullptr, "Save intermediate object files generated by the LLVM JIT"},
{"max-children-count", OptionValue::eTypeSInt64, false, 256, nullptr,
nullptr, "Maximum number of children to expand in any level of depth."},
{"max-string-summary-length", OptionValue::eTypeSInt64, false, 1024,
@@ -3370,6 +3372,7 @@ enum {
ePropertyAutoImportClangModules,
ePropertyAutoApplyFixIts,
ePropertyNotifyAboutFixIts,
+ ePropertySaveObjects,
ePropertyMaxChildrenCount,
ePropertyMaxSummaryLength,
ePropertyMaxMemReadSize,
@@ -3788,6 +3791,12 @@ bool TargetProperties::GetEnableNotifyAboutFixIts() const {
nullptr, idx, g_properties[idx].default_uint_value != 0);
}
+bool TargetProperties::GetEnableSaveObjects() const {
+ const uint32_t idx = ePropertySaveObjects;
+ return m_collection_sp->GetPropertyAtIndexAsBoolean(
+ nullptr, idx, g_properties[idx].default_uint_value != 0);
+}
+
bool TargetProperties::GetEnableSyntheticValue() const {
const uint32_t idx = ePropertyEnableSynthetic;
return m_collection_sp->GetPropertyAtIndexAsBoolean(
OpenPOWER on IntegriCloud