Fixed the IRInterpreter's handling of "this" and
authorSean Callanan <scallanan@apple.com>
Tue, 11 Dec 2012 22:39:36 +0000 (22:39 +0000)
committerSean Callanan <scallanan@apple.com>
Tue, 11 Dec 2012 22:39:36 +0000 (22:39 +0000)
commit496970f6eec7697dbda6d02fc4f8dc595a24145f
tree52c68a515dc89ccf45cfdffa9d8b229648f30ac2
parent16ba5ff7129a03b661b7fa02d79286026f7ddf6c
Fixed the IRInterpreter's handling of "this" and
"self" when those pointers are in registers.
Previously in this case the IRInterpreter would
handle them just as if the user had typed in
"$rdi", which isn't safe because $rdi is passed
in through the argument struct.

Now we correctly break out all three cases (i.e.,
normal variables in registers, $reg, and this/self),
and handle them in a way that's a little bit easier
to read and change.

This results in more accurate printing of "this" and
"self" pointers all around.  I have strengthened the
optimized-code test case for Objective-C to ensure
that we catch regressions in this area reliably in
the future.

<rdar://problem/12693963>

llvm-svn: 169924
lldb/source/Expression/IRInterpreter.cpp
lldb/test/lang/objc/objc-optimized/TestObjcOptimized.py