Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEugene Tarassov2015-04-01 21:23:57 +0000
committerEugene Tarassov2015-04-01 21:23:57 +0000
commit7528f552d4a148a3307ccfe9d13754ac083518a9 (patch)
treef7bd5abdbfb3532d20f7b05b9f9de384ee3bd27a /agent/tcf/framework/cpudefs.c
parent3e7c3c89cca7a02c307ff52c865bca0b3c2dc886 (diff)
downloadorg.eclipse.tcf.agent-7528f552d4a148a3307ccfe9d13754ac083518a9.tar.gz
org.eclipse.tcf.agent-7528f552d4a148a3307ccfe9d13754ac083518a9.tar.xz
org.eclipse.tcf.agent-7528f552d4a148a3307ccfe9d13754ac083518a9.zip
TCF Agent: symbols: better handling of a piece of an object that is present in the source but not in the object code (perhaps due to optimization)
Diffstat (limited to 'agent/tcf/framework/cpudefs.c')
-rw-r--r--agent/tcf/framework/cpudefs.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/agent/tcf/framework/cpudefs.c b/agent/tcf/framework/cpudefs.c
index 2d027f6e..ef3d471a 100644
--- a/agent/tcf/framework/cpudefs.c
+++ b/agent/tcf/framework/cpudefs.c
@@ -497,8 +497,12 @@ void read_location_pieces(Context * ctx, StackFrame * frame,
unsigned piece_bits = piece->bit_size ? piece->bit_size : piece->size * 8;
uint8_t * pbf = NULL;
uint8_t * rbf = NULL;
+ if (piece->optimized_away) {
+ set_errno(ERR_OTHER, "Cannot get symbol value: optimized away");
+ exception(errno);
+ }
if (piece->implicit_pointer) {
- set_errno(ERR_OTHER, "Symbol value unknown: implicit pointer");
+ set_errno(ERR_OTHER, "Cannot get symbol value: implicit pointer");
exception(errno);
}
if (piece->reg) {
@@ -555,6 +559,10 @@ void write_location_pieces(Context * ctx, StackFrame * frame,
unsigned piece_bits = piece->bit_size ? piece->bit_size : piece->size * 8;
uint8_t * pbf = NULL;
uint8_t * rbf = NULL;
+ if (piece->optimized_away) {
+ set_errno(ERR_OTHER, "Cannot set symbol value: optimized away");
+ exception(errno);
+ }
if (piece->implicit_pointer) {
set_errno(ERR_OTHER, "Cannot set symbol value: implicit pointer");
exception(errno);

Back to the top