search for: getindirectresult

Displaying 4 results from an estimated 4 matches for "getindirectresult".

2012 Dec 06
2
[LLVMdev] Value of structure passed byval to a recurse function not initialized when accessed through GDB
...ruct when accessed through GDB. This seems to be an ABI problem in clang. The problem seems to be that when we have pass by value of struct (having indirect arguments) stack is not aligned properly. I tried realigning the stack for indirect arguments in(TargetInfo.cpp) - ABIArgInfo X86_32ABIInfo::getIndirectResult(QualType Ty, bool ByVal) ..... if (StackAlign == 0) return ABIArgInfo::getIndirect(4, /*ByVal=*/true, /*Realign=*/true); // Do a realign of stack. ... This seems to have fixed the issue. Also in case we have a large structure - e.g. - typedef st...
2012 Dec 06
0
[LLVMdev] Value of structure passed byval to a recurse function not initialized when accessed through GDB
...gt; This seems to be an ABI problem in clang. > The problem seems to be that when we have pass by value of struct > (having indirect arguments) stack is not aligned properly. > > I tried realigning the stack for indirect arguments in(TargetInfo.cpp) - > > ABIArgInfo X86_32ABIInfo::getIndirectResult(QualType Ty, bool ByVal) > > ..... > if (StackAlign == 0) > return ABIArgInfo::getIndirect(4, /*ByVal=*/true, > /*Realign=*/true); // Do a > realign of stack. > > ... > > > This seems to have fixed the issue. Also in...
2012 Dec 04
0
[LLVMdev] Value of structure passed byval to a recurse function not initialized when accessed through GDB
This seems to be another case of PR13303 - since GDB can't figure out where to break for this function based on the debug info (you'll notice when you "break recurse" that it's not breaking on a line or source file, just an address) it's breaking at the very start, before the prologue I'm about to commit a fix to this. On Tue, Dec 4, 2012 at 5:34 AM, Karthik Bhat
2012 Dec 04
4
[LLVMdev] Value of structure passed byval to a recurse function not initialized when accessed through GDB
Hi All, I was debugging a clang binary when i found this problem. The following code is complied with clang. typedef struct s { short s; } SVAL; void recurse (SVAL a, int depth) { a.s = --depth; if (depth == 0) return; else recurse(a,depth); } int main () { SVAL s; s.s = 5; recurse (s, 5); return 0; } When i try to access value of a.s in function recurse through gdb(i.e