summaryrefslogtreecommitdiffstats
path: root/lldb/source/Expression/IRInterpreter.cpp
diff options
context:
space:
mode:
authorGreg Clayton <gclayton@apple.com>2013-04-25 00:57:05 +0000
committerGreg Clayton <gclayton@apple.com>2013-04-25 00:57:05 +0000
commit78e44bdd472ba0846f95208bee1b4cb636f6304a (patch)
tree895d0b14866107ac17f35a448cfc0f32b7c7dc53 /lldb/source/Expression/IRInterpreter.cpp
parent99394bbd0290922789b71a765d6c6939d2d8b74e (diff)
downloadbcm5719-llvm-78e44bdd472ba0846f95208bee1b4cb636f6304a.tar.gz
bcm5719-llvm-78e44bdd472ba0846f95208bee1b4cb636f6304a.zip
Don't crash if we try to interpret the IR (incorrectly in this case) and can't handle the size. This came from trying to do:
(lldb) p typedef float __attribute__((ext_vector_type(8))) __ext_vector_float8; (__ext_vector_float8)$ymm0 llvm-svn: 180235
Diffstat (limited to 'lldb/source/Expression/IRInterpreter.cpp')
-rw-r--r--lldb/source/Expression/IRInterpreter.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/lldb/source/Expression/IRInterpreter.cpp b/lldb/source/Expression/IRInterpreter.cpp
index 622ce9cd361..daa6217056a 100644
--- a/lldb/source/Expression/IRInterpreter.cpp
+++ b/lldb/source/Expression/IRInterpreter.cpp
@@ -209,9 +209,11 @@ public:
return false;
lldb::offset_t offset = 0;
- uint64_t u64value = value_extractor.GetMaxU64(&offset, value_size);
-
- return AssignToMatchType(scalar, u64value, value->getType());
+ if (value_size <= 8)
+ {
+ uint64_t u64value = value_extractor.GetMaxU64(&offset, value_size);
+ return AssignToMatchType(scalar, u64value, value->getType());
+ }
}
return false;
OpenPOWER on IntegriCloud