[llvm-dev] [DebugInfo] DIBuilder missing interface to generate DWARF info for packed_decimal basic type.
Chirag Patel via llvm-dev
llvm-dev at lists.llvm.org
Wed Aug 22 21:59:52 PDT 2018
Hello Paul,
Thanks for the reply.
Yes, I am only looking for dwarf support at the moment and planning to support both PLI/COBOL decimal types. Also thanks for the suggestion, you are right as it is going to be rare cases, so it will be better to implement a separate subclass to avoid memory overhead for others.
>> (Somebody is actively working on scaled binary operations, although they have not yet gotten to the point of wanting to support debug info.)
If possible, can you kindly get me in touch with them so I would not spend time on which is already been done?
Regards,
Chirag Patel| Software Engineer
RAINCODE Mainframe to .NET
Tel : +91 080 41159811 | Mob : +91 90493 36744
www.raincodelabs.com<http://www.raincodelabs.com/>
From: paul.robinson at sony.com <paul.robinson at sony.com>
Sent: 22 August 2018 23:03
To: Chirag Patel <Chirag at raincode.com>
Cc: llvm-dev at lists.llvm.org
Subject: RE: [llvm-dev] [DebugInfo] DIBuilder missing interface to generate DWARF info for packed_decimal basic type.
Hi Chirag,
The DW_ATE_packed_decimal (etc) constants exist because they are merely additional values in an enumeration, and we just added all the values defined in DWARF to the enumeration . LLVM does not actually support any of the decimal types, or scaled binary types. (Somebody is actively working on scaled binary operations, although they have not yet gotten to the point of wanting to support debug info.)
Without spending much time thinking about it, my inclination would be to add a new method to DIBuilder for the decimal and scaled binary types, because the additional parameters are meaningless in any other context. You might also consider whether to add a separate subclass of DIBasicType to handling scaling and decimal attributes. The decimal and scaled types are quite unusual, and we would not want to impose additional memory cost on all basic types to support these relatively rare cases.
Are you planning to support all the decimal types? I know the OpenVMS people will also want them, for COBOL and other languages, so there's benefit in having proper support in LLVM. But even if you are interested only in packed decimal, the infrastructure ought to be designed to handle all cases.
Thanks,
--paulr
(who helped design the DWARF support for COBOL types a long time ago)
From: llvm-dev [mailto:llvm-dev-bounces at lists.llvm.org] On Behalf Of Chirag Patel via llvm-dev
Sent: Wednesday, August 22, 2018 2:10 AM
To: llvm-dev at lists.llvm.org<mailto:llvm-dev at lists.llvm.org>
Subject: [llvm-dev] [DebugInfo] DIBuilder missing interface to generate DWARF info for packed_decimal basic type.
Adding tags on subject line
From: Chirag Patel
Sent: 22 August 2018 11:20
To: llvm-dev at lists.llvm.org<mailto:llvm-dev at lists.llvm.org>
Subject: DIBuilder missing interface to generate DWARF info for packed_decimal basic type.
Hello,
I am working on a llvm based compiler frontend in which, I am using the packed_decimal type encoding.
During using the llvm DIBuilder, I found out that the interface to create BasicType with packed_decimal encoding(DW_ATE_packed_decimal), is missing all the related encoding stuff,
Like
(Missing)
DW_AT_picture_string - should be MDString Node - not decided yet.
DW_AT_decimal_sign - May be in DIflags with mask (5 distinct inputs), like FlagDSOverPunch, etc
DW_AT_digit_count - unsigned integer, like unsigned DigitCount
DW_AT_decimal_scale - integer, like int DecimalScale
I am looking to add this info in DIBasicType class (DebugInfoMetadata.h) and would appreciate advice on above location.
Regrads,
Chirag Patel| Software Engineer
RAINCODE Mainframe to .NET
Tel : +91 080 41159811 | Mob : +91 90493 36744
www.raincodelabs.com<http://www.raincodelabs.com/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20180823/2cff2b0b/attachment-0001.html>
More information about the llvm-dev
mailing list