[llvm-dev] [hexagon] bug fix for ELFHeaderEFlags
Krzysztof Parzyszek via llvm-dev
llvm-dev at lists.llvm.org
Mon Apr 25 05:56:20 PDT 2016
Fixed in r267397. Thanks!
-Krzysztof
On 4/24/2016 10:37 PM, Mingjie Xing via llvm-dev wrote:
> See the attachment for testcase.
>
>
> 2016-04-24 22:21 GMT+08:00 Rafael EspĂndola <rafael.espindola at gmail.com>:
>> Test case?
>>
>> On Apr 11, 2016 8:56 PM, "Mingjie Xing via llvm-dev"
>> <llvm-dev at lists.llvm.org> wrote:
>>>
>>> Hello,
>>>
>>> I run into a problem that llvm can't write the correct ELFHeaderEFlags
>>> for hexagonv4. The following patch can fix it.
>>>
>>> Index: lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp
>>> ===================================================================
>>> --- lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp (revision
>>> 265917)
>>> +++ lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp (working
>>> copy)
>>> @@ -122,7 +122,7 @@
>>> : HexagonTargetStreamer(S) {
>>> auto Bits = STI.getFeatureBits();
>>> unsigned Flags;
>>> - if (Bits.to_ullong() & llvm::Hexagon::ArchV5)
>>> + if (Bits[Hexagon::ArchV5])
>>> Flags = ELF::EF_HEXAGON_MACH_V5;
>>> else
>>> Flags = ELF::EF_HEXAGON_MACH_V4;
>>>
>>> Maybe hexagon port maintainer has a better solution to handle
>>> Hexagon::ArchV60 etc.
>>>
>>>
>>> Best regards,
>>> Mingjie
>>> _______________________________________________
>>> LLVM Developers mailing list
>>> llvm-dev at lists.llvm.org
>>> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>>>
>>>
>>> _______________________________________________
>>> LLVM Developers mailing list
>>> llvm-dev at lists.llvm.org
>>> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
hosted by The Linux Foundation
More information about the llvm-dev
mailing list