search for: visitret

Displaying 18 results from an estimated 18 matches for "visitret".

Did you mean: visited
2008 May 14
7
[LLVMdev] Troubling promotion of return value to Integer ...
...e other two threads: (1) [LLVMdev] Integer promotion of return node operand (initiated by Sachin) (2) [LLVMdev] trouble with 32-bit promotion of return value (initiated by myself) To summarize: Evan has replied to thread (1) and suggested to add a calling convention and check for it in visitRet Dan replied to thread (2) and suggested to add a new field to the TargetLowering class, and then let each target specify the minimum integer type to promote return types to Either way, I think we all agree that the root of the problem is the FIXME in SelectionDAGLowering::visitRet() But wh...
2008 May 12
2
[LLVMdev] Integer promotion of return node operand
...disassembly. However return node operand promotion is not visible in disassembly but LLVM is doing that. 2) Also should the char not be promoted to target integer (Target integer may be 16 bits). LLVM tries to promote to i32 (promotion to i32 is hardcoded in file SelectionDAGISel.cpp - function visitRet). The comment in LLVM code says "C calling convention requires the return type to be promoted to atleast 32 bits. But this is not necessary for non-C calling conventions." What about targets where integer size is not 32 bits ?? 3) And How should this promotion be handled when the tar...
2008 May 15
0
[LLVMdev] Troubling promotion of return value to Integer ...
...er promotion of return node operand > (initiated by Sachin) > (2) [LLVMdev] trouble with 32-bit promotion of return value > (initiated by myself) > > To summarize: > Evan has replied to thread (1) and suggested to add a calling > convention and check for it in visitRet > Dan replied to thread (2) and suggested to add a new field to the > TargetLowering class, and then let each target specify the minimum > integer type to promote return types to > > Either way, I think we all agree that the root of the problem is the > FIXME in SelectionDAG...
2008 May 13
0
[LLVMdev] Integer promotion of return node operand
...int and this promotion is > visible > in the disassembly. However return node operand promotion is not > visible > in disassembly but LLVM is doing that. I think all currently defined calling conventions are "C like". You can add a calling convention and check for it in visitRet. > > > 2) Also should the char not be promoted to target integer (Target > integer may be 16 bits). LLVM tries to promote to i32 (promotion to > i32 > is hardcoded in file SelectionDAGISel.cpp - function visitRet). > > The comment in LLVM code says "C calling conve...
2011 Mar 16
3
[LLVMdev] Calls to functions with signext/zeroext return values
In SelectionDAGBuilder::visitRet(), there is this bit of code: // FIXME: C calling convention requires the return type to be promoted // to at least 32-bit. But this is not necessary for non-C calling // conventions. The frontend should mark functions whose return values // require promoting with s...
2011 Mar 16
2
[LLVMdev] Calls to functions with signext/zeroext return values
On Mar 16, 2011, at 9:31 AM, Cameron Zwarich wrote: > Promoting the return value is unsafe for bool returns on x86-64, which in the latest revision of the ABI only guarantees that the top 7 bits of the 8-bit register are 0. My comment is a bit off, because the question of what type to make the return value is somewhat orthogonal to the question of which zext assert we should add. Cameron
2011 Mar 16
0
[LLVMdev] Calls to functions with signext/zeroext return values
...t sure I follow. Won't a zeroext attribute on a bool return value ensure that it will be zero-extended to 32 bits by the callee? Or does the X86 backend consider such functions unlowerable (via TargetLowering::CanLowerReturn()) and thereby bypass the extension to 32 bits in SelectionDAGBuilder::visitRet() making a promotion in the caller unnecessary? -Ken
2008 May 13
0
[LLVMdev] trouble with 32-bit promotion of return value
There is a FIXME part in SelectionDAGLowering::visitRet() that is giving us trouble. And I would like to know how the community has planned for addressing this problem. The current implementation assumes that all C calling conventions require the return value of integer types in the largest register class (for most ports 32-bit). However, this is not t...
2008 May 16
0
[LLVMdev] Troubling promotion of return value to Integer ...
...er promotion of return node operand > (initiated by Sachin) > (2) [LLVMdev] trouble with 32-bit promotion of return value > (initiated by myself) > > To summarize: > Evan has replied to thread (1) and suggested to add a calling > convention and check for it in visitRet > Dan replied to thread (2) and suggested to add a new field to the > TargetLowering class, and then let each target specify the minimum > integer type to promote return types to > > Either way, I think we all agree that the root of the problem is the > FIXME in SelectionDAG...
2008 May 12
3
[LLVMdev] LLVM Exception Handling Changes
I just took a closer read of Chris' "LLVM Exception Handling Changes" document and have some comments. [...] > This bloats the code and is quite slow: it's not feasible to use > hardware traps to implement these checks. It's not totally infeasible. An approach similar to what if-conversion does could implement this. I'm not necessarily advocating this, I'm
2009 Sep 16
0
[LLVMdev] struct returns
...se instruction-selection IR, which is lower-level. Calls are split up into multiple parts which are eventually lowered into the actual instructions for the calling sequence. The main areas of attention will be SelectionDAGISel::LowerArguments SelectionDAGLowering::LowerCallTo SelectionDAGLowering::visitRet These functions are responsible for breaking up LLVM IR values into register-sized pieces and handing them off to target-specific code through these virtual functions: TLI.LowerFormalArguments TLI.LowerCall TLI.LowerReturn (Actually, SelectionDAGLowering::LowerCallTo calls TargetLowering::LowerC...
2009 Sep 16
2
[LLVMdev] struct returns
> I recently made a major reorganization of the calling-convention > lowering code which cleared away one of the major obstacles to > doing this within codegen. > > Dan So what was the obstacle, and how was it cleared? And how do you see the large struct return working in codegen? Anything you care to tell me would be welcome. I will be starting on this today or tomorrow.
2009 Feb 11
0
[LLVMdev] Bug in SelectionDAGBuild.cpp?
I'm hitting a problem in SelectionDAGBuild::visitRet(), mainly: MVT VT = ValueVTs[j]; // FIXME: C calling convention requires the return type to be promoted to // at least 32-bit. But this is not necessary for non-C calling // conventions. if (VT.isInteger()) { MVT MinVT = TLI.getRegisterType(MVT::i32); if (VT...
2011 Mar 16
0
[LLVMdev] Calls to functions with signext/zeroext return values
On Mar 16, 2011, at 5:58 AM, Ken Dyck wrote: > In SelectionDAGBuilder::visitRet(), there is this bit of code: > > // FIXME: C calling convention requires the return type to be promoted > // to at least 32-bit. But this is not necessary for non-C calling > // conventions. The frontend should mark functions whose return values > // req...
2008 May 12
0
[LLVMdev] FW: Integer promotion of return node operand
...disassembly. However return node operand promotion is not visible in disassembly but LLVM is doing that. 2) Also should the char not be promoted to target integer (Target integer may be 16 bits). LLVM tries to promote to i32 (promotion to i32 is hardcoded in file SelectionDAGISel.cpp - function visitRet). The comment in LLVM code says "C calling convention requires the return type to be promoted to atleast 32 bits. But this is not necessary for non-C calling conventions." What about targets where integer size is not 32 bits ?? 3) And How should this promotion be handled when the tar...
2008 May 15
2
[LLVMdev] Troubling promotion of return value to Integer ...
...f language. So I'm not sure if SelectionDAGLowering is the right place for this promotion to begin with, TargetLowering class seems more logical; but I'm not sure how. >> Either way, I think we all agree that the root of the problem is the >> FIXME in SelectionDAGLowering::visitRet() >What I would like to know is if the promotion of return values to integer is specified by the C language standard, or if it is specified by the (target specific) ABI. > >Ciao, > >Duncan. -------------- next part -------------- An HTML attachment was scrubbed... UR...
2008 Feb 27
2
[LLVMdev] 16-bit target problem
Has any one been successful with a 16-bit target? I'm new to LLVM and am having problems. One problem I found stems from code in lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp: visitRet(): // If this is an integer return value, we need to promote it ourselves to // the full width of a register, since getCopyToParts and Legalize will use // ANY_EXTEND rather than sign/zero. // FIXME: C calling convention requires the return type to be promoted to // at least 32-bit. But...
2009 Sep 20
2
[LLVMdev] struct returns
...> is lower-level. Calls are split up into multiple parts which are > eventually lowered into the actual instructions for the calling > sequence. The main areas of attention will be > > SelectionDAGISel::LowerArguments > SelectionDAGLowering::LowerCallTo > SelectionDAGLowering::visitRet > > These functions are responsible for breaking up LLVM IR values into > register-sized pieces and handing them off to target-specific code > through these virtual functions: > > TLI.LowerFormalArguments > TLI.LowerCall > TLI.LowerReturn > > (Actually, SelectionDAGLow...