search for: emitglobalconst

Displaying 12 results from an estimated 12 matches for "emitglobalconst".

2012 May 08
0
[LLVMdev] Address space information dropped
...i all, >>> >>> Tuning my TargetAsmPrinter implementation in the back-end side, I >>> discovered that the address space number is not passed down while >>> emitting global variables with constant initializers. The information is >>> dropped at AsmPrinter::EmitGlobalConstant() function call which defaults >>> it to zero. >> >> >> This sounds like a bug. > > > The feature added to allow targets emit custom data directives based on the > address space seems to be broken. However, it doesn't produce any odd > behavior becau...
2012 May 08
4
[LLVMdev] Address space information dropped
...; wrote: >> Hi all, >> >> Tuning my TargetAsmPrinter implementation in the back-end side, I >> discovered that the address space number is not passed down while >> emitting global variables with constant initializers. The information is >> dropped at AsmPrinter::EmitGlobalConstant() function call which defaults >> it to zero. > > This sounds like a bug. The feature added to allow targets emit custom data directives based on the address space seems to be broken. However, it doesn't produce any odd behavior because it's not used. The attached patch is...
2012 May 09
1
[LLVMdev] Address space information dropped
...gt; >>>> Tuning my TargetAsmPrinter implementation in the back-end side, I >>>> discovered that the address space number is not passed down while >>>> emitting global variables with constant initializers. The information is >>>> dropped at AsmPrinter::EmitGlobalConstant() function call which defaults >>>> it to zero. >>> >>> This sounds like a bug. >> >> The feature added to allow targets emit custom data directives based on the >> address space seems to be broken. However, it doesn't produce any odd >>...
2012 May 07
4
[LLVMdev] Address space information dropped
Hi all, Tuning my TargetAsmPrinter implementation in the back-end side, I discovered that the address space number is not passed down while emitting global variables with constant initializers. The information is dropped at AsmPrinter::EmitGlobalConstant() function call which defaults it to zero. I would like to emit target-dependent asm directives depending on the address space of constant initializers. Is there another method to implement this feature ? The main reason is that we have 2 distinct memories and we are currently using address...
2008 Jun 06
0
[LLVMdev] StmtPrinter long double support.
...hat you mean. Probably this dumper should use APFloat::convert to get the long double into APFloat::IEEEdouble format (with loss of precision; the comment claims that's OK), then use convertToDouble on that. If you want full precision, you'll need to print all the bits in hex; see EmitGlobalConstant in AsmPrinter.cpp. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20080606/6860d98a/attachment.html>
2008 Jun 06
3
[LLVMdev] StmtPrinter long double support.
Hello, I'm playing with llvm/clang and I have a problem when I try to use the -ast-print options for a file that uses long double. The Basic/Targets.cpp file defined the x86 (and x86_64) long double type as APFloat::x87DoubleExtended. Then, when the AST printer try to write a long double literal value (using VisitFloatingLiteral()), it call FloatingLiteral- >getValueAsDouble()
2012 May 07
0
[LLVMdev] Address space information dropped
...anllopard at gmail.com> wrote: > Hi all, > > Tuning my TargetAsmPrinter implementation in the back-end side, I > discovered that the address space number is not passed down while > emitting global variables with constant initializers. The information is > dropped at AsmPrinter::EmitGlobalConstant() function call which defaults > it to zero. This sounds like a bug. -Eli
2010 May 27
0
[LLVMdev] ARM Relocation Information
...d relocation information to assembly data instructions? For instance, ARM GCC generates symbols like: _ZTIi (TARGET2) While Clang doesn't include the TARGET2 relocation information, and that mess up cross-linking. Looking at the AsmPrinter, when emitting the global constant value (EmitGlobalConstant), it calls EmitGlobalConstantImpl, which end up using EmitValue or EmitIntValue, but neither has relocation information on them. Also, searching the code, I couldn't find any reference to relocation or any of the basic relocation types available in Codesourcery's GCC. Is there anythi...
2017 Mar 07
4
[BUG Report] -dead_strip, strips prefix data unconditionally on macOS
Firstly, do you need "main.dsp" defined as an external symbol, or can all external references go via "main"? If the answer is the latter, that will make the solution simpler. If only the latter, you will need to make a change to LLVM here: http://llvm-cs.pcc.me.uk/lib/CodeGen/AsmPrinter/AsmPrinter.cpp#650 Basically you would need to add a hook to the TargetLoweringObjectFile
2007 Aug 12
0
[LLVMdev] ocaml+llvm
...ormed? 5. Update the frame table constant with information only available during codegen. - I'm thinking I should populate an on-the-side data structure during compilation, and only convert it to a Constant* and emit it during an epilogue pass using AsmPrinter::EmitGlobalConstant. That's the doozy. Unfortunately, I think the runtime requirements will preclude the use of the basic LLVM toolchain in conjunction with LLVM ocamlopt, which is unfortunate. The simpler problem is that each ocaml object exports symbols bracketing its code and data. An ocaml object absent...
2010 Mar 15
0
[LLVMdev] [patch] Writing ConstantUnions
...er.cpp =================================================================== --- lib/CodeGen/AsmPrinter/AsmPrinter.cpp (revision 98552) +++ lib/CodeGen/AsmPrinter/AsmPrinter.cpp (working copy) @@ -1128,6 +1128,21 @@ "Layout of constant struct may be incorrect!"); } +static void EmitGlobalConstantUnion(const ConstantUnion *CU, + unsigned AddrSpace, AsmPrinter &AP) { + const TargetData *TD = AP.TM.getTargetData(); + unsigned Size = TD->getTypeAllocSize(CU->getType()); + + const Constant *Contents = CU->getOperand(0); + unsigned FilledSiz...
2010 Mar 15
3
[LLVMdev] [patch] Writing ConstantUnions
Hello, I noticed a bit of a gap in the current code for unions: a ConstantUnion cannot be written out to .ll. Hopefully I'm not stepping on Talin's toes by posting this, it's a fairly straightforward adaptation of the code for structs just above. Tim. -- The University of Edinburgh is a charitable body, registered in Scotland, with registration number SC005336. --------------