llvm-commits Digest, Vol 193, Issue 447
Marcin Wiśniewsk via llvm-commits
llvm-commits at lists.llvm.org
Sat Jul 18 12:23:04 PDT 2020
<https://stackoverflow.com/jobs/386842/software-engineer-java-privitar-ltd?so=i&pg=1&offset=3&tl=java>https://stackoverflow.com/jobs/386842/software-engineer-java-privitar-ltd?so=i&pg=1&offset=3&tl=java
________________________________
From: llvm-commits <llvm-commits-bounces at lists.llvm.org> on behalf of via llvm-commits <llvm-commits at lists.llvm.org>
Sent: Saturday, July 18, 2020 4:25:12 PM
To: llvm-commits at lists.llvm.org <llvm-commits at lists.llvm.org>
Subject: llvm-commits Digest, Vol 193, Issue 447
Send llvm-commits mailing list submissions to
llvm-commits at lists.llvm.org
To subscribe or unsubscribe via the World Wide Web, visit
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
or, via email, send a message with subject or body 'help' to
llvm-commits-request at lists.llvm.org
You can reach the person managing the list at
llvm-commits-owner at lists.llvm.org
When replying, please edit your Subject line so it is more specific
than "Re: Contents of llvm-commits digest..."
Today's Topics:
1. [PATCH] D84092: [DebugInfo] Make DIELocList::SizeOf() more
explicit. NFCI. (Igor Kudrin via Phabricator via llvm-commits)
2. [PATCH] D84093: [DebugInfo] Fix a comment and a variable
name. NFC. (Igor Kudrin via Phabricator via llvm-commits)
3. [PATCH] D84094: [DebugInfo] Fix misleading using of DWARF
forms with DIELabel. NFCI.
(Igor Kudrin via Phabricator via llvm-commits)
4. [PATCH] D84095: [DebugInfo] Make DIEDelta::SizeOf() more
explicit. NFCI. (Igor Kudrin via Phabricator via llvm-commits)
5. [PATCH] D84085: [SROA][Mem2Reg] Do not crash on alloca +
addrspacecast (Matt Arsenault via Phabricator via llvm-commits)
6. [PATCH] D84085: [SROA][Mem2Reg] Do not crash on alloca +
addrspacecast (Matt Arsenault via Phabricator via llvm-commits)
7. [PATCH] D80750: llvm-link: Add module flag behavior
MergeTargetID (Yaxun Liu via Phabricator via llvm-commits)
8. [PATCH] D84098: [AMDGPU][MC] Corrected decoding of 16-bit
literals (Dmitry Preobrazhensky via Phabricator via llvm-commits)
9. [PATCH] D81031: [OpenMP] Add Additional Function Attribute
Information to OMPKinds.def
(Joseph Huber via Phabricator via llvm-commits)
10. [PATCH] D84099: [llvm-reduce] Fix off-by one in argument
reduction pass (Alexander Richardson via Phabricator via llvm-commits)
11. [PATCH] D83311: [CodeMoverUtils] Add optional data dependence
checks using MSSA (rithik sharma via Phabricator via llvm-commits)
12. [PATCH] D60620: [HIP] Support target id by --offload-arch
(Yaxun Liu via Phabricator via llvm-commits)
13. [PATCH] D81585: [AIX][XCOFF][Patch1] Provide decoding trace
back table information API for xcoff object file for llvm-objdump
-d (Hubert Tong via Phabricator via llvm-commits)
14. [PATCH] D84099: [llvm-reduce] Fix off-by one in argument
reduction pass (Roman Lebedev via Phabricator via llvm-commits)
15. [PATCH] D84100: [ARM] Optimize immediate selection
(Ben Shi via Phabricator via llvm-commits)
----------------------------------------------------------------------
Message: 1
Date: Sat, 18 Jul 2020 11:32:28 +0000 (UTC)
From: Igor Kudrin via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: ikudrin at accesssoftek.com, dblaikie at gmail.com, echristo at gmail.com,
jh7370 at my.bristol.ac.uk, aprantl at apple.com
Cc: sontuan.vu119 at gmail.com, nikola.tesic at syrmia.com,
chris.jackson at sony.com, llvm-commits at lists.llvm.org,
mateja.marjanovic at syrmia.com, stephen.tozer at sony.com,
asowda at cisco.com, 88888yl at gmail.com, sourabhsingh.tomar at amd.com,
grimar at accesssoftek.com, higuoxing at gmail.com,
AlokKumar.Sharma at amd.com, djordje.todorovic at syrmia.com,
john.reagan at vmssoftware.com
Subject: [PATCH] D84092: [DebugInfo] Make DIELocList::SizeOf() more
explicit. NFCI.
Message-ID:
<differential-rev-PHID-DREV-b6plz7q443peyilznwgm-req at reviews.llvm.org>
Content-Type: text/plain; charset="utf-8"
ikudrin created this revision.
ikudrin added reviewers: dblaikie, echristo, jhenderson, aprantl.
ikudrin added projects: LLVM, debug-info.
Herald added a subscriber: hiraditya.
`DIELocList` is used with a limited number of DWARF forms, see the only place where it is instantiated, `DwarfCompileUnit::addLocationList()`.
The patch marks the unexpected execution path in `DIELocList::SizeOf()` as unreachable, to reduce ambiguity.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D84092
Files:
llvm/lib/CodeGen/AsmPrinter/DIE.cpp
Index: llvm/lib/CodeGen/AsmPrinter/DIE.cpp
===================================================================
--- llvm/lib/CodeGen/AsmPrinter/DIE.cpp
+++ llvm/lib/CodeGen/AsmPrinter/DIE.cpp
@@ -809,13 +809,17 @@
//===----------------------------------------------------------------------===//
unsigned DIELocList::SizeOf(const AsmPrinter *AP, dwarf::Form Form) const {
- if (Form == dwarf::DW_FORM_loclistx)
+ switch (Form) {
+ case dwarf::DW_FORM_loclistx:
return getULEB128Size(Index);
- if (Form == dwarf::DW_FORM_data4)
+ case dwarf::DW_FORM_data4:
return 4;
- if (Form == dwarf::DW_FORM_sec_offset)
+ case dwarf::DW_FORM_sec_offset:
+ // FIXME: add support for DWARF64
return 4;
- return AP->MAI->getCodePointerSize();
+ default:
+ llvm_unreachable("DIE Value form not supported yet");
+ }
}
/// EmitValue - Emit label value.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D84092.278986.patch
Type: text/x-patch
Size: 871 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200718/8b74e3a8/attachment-0001.bin>
------------------------------
Message: 2
Date: Sat, 18 Jul 2020 11:34:14 +0000 (UTC)
From: Igor Kudrin via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: ikudrin at accesssoftek.com, dblaikie at gmail.com,
jh7370 at my.bristol.ac.uk
Cc: sontuan.vu119 at gmail.com, nikola.tesic at syrmia.com,
chris.jackson at sony.com, llvm-commits at lists.llvm.org,
mateja.marjanovic at syrmia.com, stephen.tozer at sony.com,
asowda at cisco.com, 88888yl at gmail.com, sourabhsingh.tomar at amd.com,
grimar at accesssoftek.com, higuoxing at gmail.com,
AlokKumar.Sharma at amd.com, djordje.todorovic at syrmia.com,
john.reagan at vmssoftware.com
Subject: [PATCH] D84093: [DebugInfo] Fix a comment and a variable
name. NFC.
Message-ID:
<differential-rev-PHID-DREV-f2rjrdcuuvxcy6osy7xa-req at reviews.llvm.org>
Content-Type: text/plain; charset="utf-8"
ikudrin created this revision.
ikudrin added reviewers: dblaikie, jhenderson.
ikudrin added projects: LLVM, debug-info.
Herald added a subscriber: hiraditya.
`DebugLocListIndex` keeps the index of an entry list, not the offset.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D84093
Files:
llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h
Index: llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h
===================================================================
--- llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h
+++ llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h
@@ -114,7 +114,7 @@
///
/// Variables that have been optimized out use none of these fields.
class DbgVariable : public DbgEntity {
- /// Offset in DebugLocs.
+ /// Index of the entry list in DebugLocs.
unsigned DebugLocListIndex = ~0u;
/// DW_OP_LLVM_tag_offset value from DebugLocs.
Optional<uint8_t> DebugLocListTagOffset;
Index: llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
===================================================================
--- llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
+++ llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
@@ -690,9 +690,9 @@
// Add variable address.
- unsigned Offset = DV.getDebugLocListIndex();
- if (Offset != ~0U) {
- addLocationList(*VariableDie, dwarf::DW_AT_location, Offset);
+ unsigned Index = DV.getDebugLocListIndex();
+ if (Index != ~0U) {
+ addLocationList(*VariableDie, dwarf::DW_AT_location, Index);
auto TagOffset = DV.getDebugLocListTagOffset();
if (TagOffset)
addUInt(*VariableDie, dwarf::DW_AT_LLVM_tag_offset, dwarf::DW_FORM_data1,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D84093.278987.patch
Type: text/x-patch
Size: 1257 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200718/7bd63f97/attachment-0001.bin>
------------------------------
Message: 3
Date: Sat, 18 Jul 2020 11:39:21 +0000 (UTC)
From: Igor Kudrin via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: ikudrin at accesssoftek.com, dblaikie at gmail.com, echristo at gmail.com,
jh7370 at my.bristol.ac.uk, aprantl at apple.com, wvo at google.com,
ydelendik at mozilla.com
Cc: sontuan.vu119 at gmail.com, nikola.tesic at syrmia.com,
chris.jackson at sony.com, llvm-commits at lists.llvm.org,
mateja.marjanovic at syrmia.com, stephen.tozer at sony.com,
sourabhsingh.tomar at amd.com, 88888yl at gmail.com,
grimar at accesssoftek.com, higuoxing at gmail.com, asowda at cisco.com,
AlokKumar.Sharma at amd.com, djordje.todorovic at syrmia.com,
john.reagan at vmssoftware.com
Subject: [PATCH] D84094: [DebugInfo] Fix misleading using of DWARF
forms with DIELabel. NFCI.
Message-ID:
<differential-rev-PHID-DREV-2kjek5oavbbau5bpbbab-req at reviews.llvm.org>
Content-Type: text/plain; charset="utf-8"
ikudrin created this revision.
ikudrin added reviewers: dblaikie, echristo, jhenderson, aprantl, aardappel, yurydelendik.
ikudrin added projects: LLVM, debug-info.
Herald added subscribers: aheejin, hiraditya.
`DIELabel` can emit only 32- or 64-bit values, while it was created in some places with `DW_FORM_udata`, which implies emitting uleb128. Nevertheless, these places also expected to emit U32 or U64, but just used a misleading DWARF form. The patch updates those places to use more appropriate DWARF forms and restricts `DIELabel::SizeOf()` to accept only forms that are actually used in the LLVM codebase.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D84094
Files:
llvm/lib/CodeGen/AsmPrinter/DIE.cpp
llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp
Index: llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp
===================================================================
--- llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp
+++ llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp
@@ -353,7 +353,7 @@
}
addUInt(Die, dwarf::DW_FORM_data1, dwarf::DW_OP_addr);
- addLabel(Die, dwarf::DW_FORM_udata, Sym);
+ addLabel(Die, dwarf::DW_FORM_addr, Sym);
}
void DwarfUnit::addLabelDelta(DIE &Die, dwarf::Attribute Attribute,
Index: llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
===================================================================
--- llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
+++ llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
@@ -451,8 +451,8 @@
true});
DIELoc *Loc = new (DIEValueAllocator) DIELoc;
addUInt(*Loc, dwarf::DW_FORM_data1, dwarf::DW_OP_WASM_location);
- addSInt(*Loc, dwarf::DW_FORM_sdata, FrameBase.Location.WasmLoc.Kind);
- addLabel(*Loc, dwarf::DW_FORM_udata, SPSym);
+ addSInt(*Loc, dwarf::DW_FORM_sdata, TI_GLOBAL_RELOC);
+ addLabel(*Loc, dwarf::DW_FORM_data4, SPSym);
DD->addArangeLabel(SymbolCU(this, SPSym));
addUInt(*Loc, dwarf::DW_FORM_data1, dwarf::DW_OP_stack_value);
addBlock(*SPDie, dwarf::DW_AT_frame_base, Loc);
Index: llvm/lib/CodeGen/AsmPrinter/DIE.cpp
===================================================================
--- llvm/lib/CodeGen/AsmPrinter/DIE.cpp
+++ llvm/lib/CodeGen/AsmPrinter/DIE.cpp
@@ -495,19 +495,25 @@
/// EmitValue - Emit label value.
///
void DIELabel::emitValue(const AsmPrinter *AP, dwarf::Form Form) const {
- AP->emitLabelReference(
- Label, SizeOf(AP, Form),
- Form == dwarf::DW_FORM_strp || Form == dwarf::DW_FORM_sec_offset ||
- Form == dwarf::DW_FORM_ref_addr || Form == dwarf::DW_FORM_data4);
+ bool IsSectionRelative = Form != dwarf::DW_FORM_addr;
+ AP->emitLabelReference(Label, SizeOf(AP, Form), IsSectionRelative);
}
/// SizeOf - Determine size of label value in bytes.
///
unsigned DIELabel::SizeOf(const AsmPrinter *AP, dwarf::Form Form) const {
- if (Form == dwarf::DW_FORM_data4) return 4;
- if (Form == dwarf::DW_FORM_sec_offset) return 4;
- if (Form == dwarf::DW_FORM_strp) return 4;
- return AP->MAI->getCodePointerSize();
+ switch (Form) {
+ case dwarf::DW_FORM_data4:
+ return 4;
+ case dwarf::DW_FORM_sec_offset:
+ case dwarf::DW_FORM_strp:
+ // FIXME: add support for DWARF64
+ return 4;
+ case dwarf::DW_FORM_addr:
+ return AP->MAI->getCodePointerSize();
+ default:
+ llvm_unreachable("DIE Value form not supported yet");
+ }
}
LLVM_DUMP_METHOD
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D84094.278988.patch
Type: text/x-patch
Size: 2632 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200718/03cbd100/attachment-0001.bin>
------------------------------
Message: 4
Date: Sat, 18 Jul 2020 11:43:19 +0000 (UTC)
From: Igor Kudrin via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: ikudrin at accesssoftek.com, dblaikie at gmail.com,
jh7370 at my.bristol.ac.uk, echristo at gmail.com, aprantl at apple.com
Cc: sontuan.vu119 at gmail.com, nikola.tesic at syrmia.com,
chris.jackson at sony.com, llvm-commits at lists.llvm.org,
mateja.marjanovic at syrmia.com, stephen.tozer at sony.com,
asowda at cisco.com, 88888yl at gmail.com, sourabhsingh.tomar at amd.com,
grimar at accesssoftek.com, higuoxing at gmail.com,
AlokKumar.Sharma at amd.com, djordje.todorovic at syrmia.com,
john.reagan at vmssoftware.com
Subject: [PATCH] D84095: [DebugInfo] Make DIEDelta::SizeOf() more
explicit. NFCI.
Message-ID:
<differential-rev-PHID-DREV-vnyjehk2qdan6m7tndyz-req at reviews.llvm.org>
Content-Type: text/plain; charset="utf-8"
ikudrin created this revision.
ikudrin added reviewers: dblaikie, jhenderson, echristo, aprantl.
ikudrin added projects: LLVM, debug-info.
Herald added a subscriber: hiraditya.
The patch restricts `DIEDelta::SizeOf()` to accept only DWARF forms that are actually used in the LLVM codebase. This should make the use of the class more explicit and help to avoid issues similar to fixed in D83958 <https://reviews.llvm.org/D83958> and D84094 <https://reviews.llvm.org/D84094>.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D84095
Files:
llvm/lib/CodeGen/AsmPrinter/DIE.cpp
Index: llvm/lib/CodeGen/AsmPrinter/DIE.cpp
===================================================================
--- llvm/lib/CodeGen/AsmPrinter/DIE.cpp
+++ llvm/lib/CodeGen/AsmPrinter/DIE.cpp
@@ -549,10 +549,15 @@
/// SizeOf - Determine size of delta value in bytes.
///
unsigned DIEDelta::SizeOf(const AsmPrinter *AP, dwarf::Form Form) const {
- if (Form == dwarf::DW_FORM_data4) return 4;
- if (Form == dwarf::DW_FORM_sec_offset) return 4;
- if (Form == dwarf::DW_FORM_strp) return 4;
- return AP->MAI->getCodePointerSize();
+ switch (Form) {
+ case dwarf::DW_FORM_data4:
+ return 4;
+ case dwarf::DW_FORM_sec_offset:
+ // FIXME: add support for DWARF64
+ return 4;
+ default:
+ llvm_unreachable("DIE Value form not supported yet");
+ }
}
LLVM_DUMP_METHOD
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D84095.278989.patch
Type: text/x-patch
Size: 785 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200718/55efd221/attachment-0001.bin>
------------------------------
Message: 5
Date: Sat, 18 Jul 2020 13:35:57 +0000 (UTC)
From: Matt Arsenault via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: jdoerfert at anl.gov, florian_hahn at apple.com, lebedev.ri at gmail.com,
spatel at rotateright.com, nicholas at mxc.ca
Cc: siddu.druid at gmail.com, 88888yl at gmail.com,
llvm-commits at lists.llvm.org, jun.l at samsung.com, wei.ding2 at amd.com
Subject: [PATCH] D84085: [SROA][Mem2Reg] Do not crash on alloca +
addrspacecast
Message-ID: <b8cb71d613ffe9f8164cb0c742cda467 at localhost.localdomain>
Content-Type: text/plain; charset=us-ascii
arsenm added inline comments.
================
Comment at: llvm/test/Transforms/SROA/alloca_addrspace.ll:20
+}
+
+declare void @llvm.lifetime.start.p0i8(i64 %size, i8* nocapture %ptr)
----------------
Also could use a negative case
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D84085/new/
https://reviews.llvm.org/D84085
------------------------------
Message: 6
Date: Sat, 18 Jul 2020 13:36:24 +0000 (UTC)
From: Matt Arsenault via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: jdoerfert at anl.gov, florian_hahn at apple.com, lebedev.ri at gmail.com,
spatel at rotateright.com, nicholas at mxc.ca
Cc: siddu.druid at gmail.com, 88888yl at gmail.com,
llvm-commits at lists.llvm.org, jun.l at samsung.com, wei.ding2 at amd.com
Subject: [PATCH] D84085: [SROA][Mem2Reg] Do not crash on alloca +
addrspacecast
Message-ID: <90eb224c1482010aa3cb38c714f766c5 at localhost.localdomain>
Content-Type: text/plain; charset=us-ascii
arsenm added inline comments.
================
Comment at: llvm/test/Transforms/SROA/alloca_addrspace.ll:2-3
+; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
+; RUN: opt < %s -sroa -S | FileCheck %s
+; RUN: opt < %s -passes=sroa -S | FileCheck %s
+; RUN: opt < %s -mem2reg -S | FileCheck %s
----------------
This is also covered by SROA tests, should this go in test/Mem2Reg
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D84085/new/
https://reviews.llvm.org/D84085
------------------------------
Message: 7
Date: Sat, 18 Jul 2020 13:37:33 +0000 (UTC)
From: Yaxun Liu via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: yaxun.liu at amd.com, scott.linder at amd.com,
konstantin.zhuravlyov at amd.com, jdoerfert at anl.gov
Cc: 88888yl at gmail.com, llvm-commits at lists.llvm.org
Subject: [PATCH] D80750: llvm-link: Add module flag behavior
MergeTargetID
Message-ID: <4bc3b4d98f4be19a85eed541628eedfe at localhost.localdomain>
Content-Type: text/plain; charset="utf-8"
yaxunl updated this revision to Diff 278995.
yaxunl marked 12 inline comments as done.
yaxunl retitled this revision from "llvm-link: Add module flag behavior MergeTargetId" to "llvm-link: Add module flag behavior MergeTargetID".
yaxunl edited the summary of this revision.
yaxunl added a comment.
Herald added a reviewer: jdoerfert.
revised by Scott's comments.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D80750/new/
https://reviews.llvm.org/D80750
Files:
llvm/docs/LangRef.rst
llvm/include/llvm/IR/Module.h
llvm/lib/IR/Verifier.cpp
llvm/lib/Linker/IRMover.cpp
llvm/test/Linker/Inputs/module-flags-target-id-src-default.ll
llvm/test/Linker/Inputs/module-flags-target-id-src-diff-cpu.ll
llvm/test/Linker/Inputs/module-flags-target-id-src-diff-triple.ll
llvm/test/Linker/Inputs/module-flags-target-id-src-empty.ll
llvm/test/Linker/Inputs/module-flags-target-id-src-invalid.ll
llvm/test/Linker/Inputs/module-flags-target-id-src-none.ll
llvm/test/Linker/Inputs/module-flags-target-id-src-sram-ecc-off-xnack-on.ll
llvm/test/Linker/Inputs/module-flags-target-id-src-xnack-off.ll
llvm/test/Linker/module-flags-target-id-dst-default.ll
llvm/test/Linker/module-flags-target-id-dst-empty.ll
llvm/test/Linker/module-flags-target-id-dst-none.ll
llvm/test/Linker/module-flags-target-id-dst-sram-ecc-off-xnack-on.ll
llvm/test/Verifier/module-flags-target-id-invalid-key.ll
llvm/test/Verifier/module-flags-target-id-invalid-value.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D80750.278995.patch
Type: text/x-patch
Size: 20493 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200718/53290836/attachment-0001.bin>
------------------------------
Message: 8
Date: Sat, 18 Jul 2020 13:43:08 +0000 (UTC)
From: Dmitry Preobrazhensky via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: dpreobrazhensky at luxoft.com, Matthew.Arsenault at amd.com,
stanislav.mekhanoshin at amd.com
Cc: yaxun.liu at amd.com, wei.ding2 at amd.com, sebastian.neubauer at amd.com,
88888yl at gmail.com, nhaehnle at gmail.com, Austin.Kerbow at amd.com,
llvm-commits at lists.llvm.org, david.stuttard at amd.com,
konstantin.zhuravlyov at amd.com, tpr.ll at botech.co.uk, Tony.Tye at amd.com,
kannan.narayanan at amd.com
Subject: [PATCH] D84098: [AMDGPU][MC] Corrected decoding of 16-bit
literals
Message-ID:
<differential-rev-PHID-DREV-4yafcgtmjug4pmjzzulz-req at reviews.llvm.org>
Content-Type: text/plain; charset="utf-8"
dp created this revision.
dp added reviewers: arsenm, rampitec.
Herald added subscribers: llvm-commits, kerbowa, hiraditya, t-tye, tpr, dstuttard, yaxunl, nhaehnle, wdng, jvesely, kzhuravl.
Herald added a project: LLVM.
16-bit literals are encoded as 32-bit values. If high 16-bits of the value is 0xFFFF, the decoded instruction cannot be reassembled.
For example, the following code
0xff,0x04,0x04,0x52,0xcd,0xab,0xff,0xff
is currently decoded as
v_mul_lo_u16_e32 v2, 0xffffabcd, v2
However this literal is actually a 64-bit constant 0x00000000ffffabcd which violates requirements described in the documentation <https://llvm.org/docs/AMDGPUOperandSyntax.html#conversion-of-integer-values> - the truncation is not safe.
This change corrects decoding to make reassembly possible.
Codegen should probably be corrected as well to zero-extend 16 bit values.
https://reviews.llvm.org/D84098
Files:
llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp
llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.h
llvm/test/CodeGen/AMDGPU/add.i16.ll
llvm/test/CodeGen/AMDGPU/add.v2i16.ll
llvm/test/CodeGen/AMDGPU/imm16.ll
llvm/test/CodeGen/AMDGPU/sub.i16.ll
llvm/test/CodeGen/AMDGPU/sub.v2i16.ll
llvm/test/MC/Disassembler/AMDGPU/literal16_vi.txt
llvm/test/MC/Disassembler/AMDGPU/vop3-literal.txt
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D84098.278994.patch
Type: text/x-patch
Size: 11160 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200718/4a890d3f/attachment-0001.bin>
------------------------------
Message: 9
Date: Sat, 18 Jul 2020 13:59:42 +0000 (UTC)
From: Joseph Huber via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: jhuber6 at vols.utk.edu, jdoerfert at anl.gov
Cc: yaxun.liu at amd.com, lildmh at gmail.com, blitzrakete at gmail.com,
aaron.ballman at gmail.com, llvm-commits at lists.llvm.org,
Saiyedul.Islam at amd.com, cfe-commits at lists.llvm.org,
shenhan at google.com, sara.royuela at bsc.es, 88888yl at gmail.com,
sourabhsingh.tomar at amd.com, deepak.eachempati at hpe.com, lin32 at llnl.gov,
leonardchan at google.com, greg63706 at gmail.com, stefomeister at gmail.com,
mlekena at skidmore.edu, zhang.guansong at gmail.com,
ravi.narayanaswamy at intel.com, ron.lieberman at amd.com,
a.bataev at hotmail.com, xw111luoye at gmail.com, liao6 at llnl.gov
Subject: [PATCH] D81031: [OpenMP] Add Additional Function Attribute
Information to OMPKinds.def
Message-ID: <93330b8386adb041a2bf4e7e160ad97a at localhost.localdomain>
Content-Type: text/plain; charset=us-ascii
jhuber6 added a comment.
In D81031#2159943 <https://reviews.llvm.org/D81031#2159943>, @jdoerfert wrote:
> In D81031#2159895 <https://reviews.llvm.org/D81031#2159895>, @jhuber6 wrote:
>
> > Fixing errors caused by unused attribute sets. Adding missing attributes to barrier_codegen.cpp.
> >
> > Should I go ahead and commit this considering the previous was temporarily reverted? Or should I just wait a bit to see if it fails testing again.
>
>
> If you only did minor modifications and no major problem showed up, the previous LGTM still stands. You should (always) run a full make check-all locally (or better on a server) to verify no other issues are known.
>
> FWIW, it happens that we break bots and patches get reverted. That is not great but also not too bad.
I did run a check-all but apparently the last build I did didn't build clang for some reason so it wasn't included in the tests. I ran cmake again with the same options and it seemed to build clang this time so I don't know what that was about.
After that I ran the tests again and I passed everything except these four. I reverted my commit and pulled from master and still failed the same test so I'm assuming it's a problem with my CUDA installation rather than the patch.
libomp :: env/kmp_set_dispatch_buf.c
libomp :: worksharing/for/kmp_set_dispatch_buf.c
libomptarget :: mapping/declare_mapper_target_update.cpp
libomptarget :: offloading/target_depend_nowait.cpp
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D81031/new/
https://reviews.llvm.org/D81031
------------------------------
Message: 10
Date: Sat, 18 Jul 2020 14:08:35 +0000 (UTC)
From: Alexander Richardson via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: arichardson.kde at gmail.com, dblaikie at gmail.com
Cc: 88888yl at gmail.com, llvm-commits at lists.llvm.org
Subject: [PATCH] D84099: [llvm-reduce] Fix off-by one in argument
reduction pass
Message-ID:
<differential-rev-PHID-DREV-6lpv62grobenn66evgtx-req at reviews.llvm.org>
Content-Type: text/plain; charset="utf-8"
arichardson created this revision.
arichardson added a reviewer: dblaikie.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
The function extractArgumentsFromModule() was passing a one-based index to,
but replaceFunctionCalls() was expecting a zero-based argument index. This
resulted in assertion errors when reducing function call arguments with
different types.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D84099
Files:
llvm/test/Reduce/remove-args-2.ll
llvm/tools/llvm-reduce/deltas/ReduceArguments.cpp
Index: llvm/tools/llvm-reduce/deltas/ReduceArguments.cpp
===================================================================
--- llvm/tools/llvm-reduce/deltas/ReduceArguments.cpp
+++ llvm/tools/llvm-reduce/deltas/ReduceArguments.cpp
@@ -84,7 +84,7 @@
int ArgI = 0;
for (auto &Arg : F->args())
if (ArgsToKeep.count(&Arg))
- ArgIndexesToKeep.insert(++ArgI);
+ ArgIndexesToKeep.insert(ArgI++);
auto *ClonedFunc = CloneFunction(F, VMap);
// In order to preserve function order, we move Clone after old Function
Index: llvm/test/Reduce/remove-args-2.ll
===================================================================
--- /dev/null
+++ llvm/test/Reduce/remove-args-2.ll
@@ -0,0 +1,20 @@
+; Test that llvm-reduce can remove uninteresting function arguments from function definitions as well as their calls.
+; This test checks that functions with different argument types are handled correctly
+;
+; RUN: llvm-reduce --test %python --test-arg %p/Inputs/remove-args.py %s -o %t
+; RUN: cat %t | FileCheck -implicit-check-not=uninteresting %s
+
+%struct.foo = type { %struct.foo*, i32, i32, i8* }
+
+define dso_local void @bar() {
+entry:
+ ; CHECK: call void @interesting(%struct.foo* null)
+ call void @interesting(%struct.foo* null, i8* null)
+ ret void
+}
+
+; CHECK: define internal void @interesting(%struct.foo* %interesting) {
+define internal void @interesting(%struct.foo* %interesting, i8* %uninteresting) {
+entry:
+ ret void
+}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D84099.278999.patch
Type: text/x-patch
Size: 1483 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200718/abd0e095/attachment-0001.bin>
------------------------------
Message: 11
Date: Sat, 18 Jul 2020 14:09:21 +0000 (UTC)
From: rithik sharma via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: rithiksh02 at gmail.com, whitney.uwaterloo at gmail.com,
bmahjour at ca.ibm.com, etiotto at gmail.com, florian_hahn at apple.com
Cc: 88888yl at gmail.com, llvm-commits at lists.llvm.org, jun.l at samsung.com,
asbirlea at google.com
Subject: [PATCH] D83311: [CodeMoverUtils] Add optional data dependence
checks using MSSA
Message-ID: <a2ca20e2492ccaa324a31ba537c3f10b at localhost.localdomain>
Content-Type: text/plain; charset=us-ascii
RithikSharma marked 6 inline comments as done.
RithikSharma added inline comments.
================
Comment at: llvm/lib/Transforms/Utils/CodeMoverUtils.cpp:259
+ // write after read dependency on same memory location
+ if (InstMA == CurInstDefMA || InstLastDefMA == CurInstDefMA)
+ return true;
----------------
bmahjour wrote:
> I don't understand why we need this part: `|| InstLastDefMA == CurInstDefMA`. Wouldn't it suffice to check the reaching def of the use against the instruction being moved (the first part of this condition) ? Do you have a test that would fail if you remove it?
Yes we have a failure if we remove this,
```
isSafeToMoveBefore(*StoreA2, *LoadA1, DT, &PDT, nullptr, &MSSA)
```
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D83311/new/
https://reviews.llvm.org/D83311
------------------------------
Message: 12
Date: Sat, 18 Jul 2020 14:15:43 +0000 (UTC)
From: Yaxun Liu via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: yaxun.liu at amd.com, tra at google.com, brian.sumner at amd.com,
Aaronenye.Shi at amd.com, siuchi.chan at amd.com, Tony.Tye at amd.com
Cc: zturner at roblox.com, sebastian.neubauer at amd.com, 88888yl at gmail.com,
nhaehnle at gmail.com, Austin.Kerbow at amd.com,
llvm-commits at lists.llvm.org, cfe-commits at lists.llvm.org
Subject: [PATCH] D60620: [HIP] Support target id by --offload-arch
Message-ID: <21e4c0723be02c37db40df259bc366dc at localhost.localdomain>
Content-Type: text/plain; charset="utf-8"
yaxunl updated this revision to Diff 279000.
yaxunl added a comment.
Herald added subscribers: llvm-commits, dang, hiraditya.
Herald added a project: LLVM.
rebase and added more checks.
The documentation work is still under development.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D60620/new/
https://reviews.llvm.org/D60620
Files:
clang/include/clang/Basic/DiagnosticDriverKinds.td
clang/include/clang/Basic/TargetID.h
clang/include/clang/Basic/TargetInfo.h
clang/include/clang/Driver/Compilation.h
clang/include/clang/Driver/Driver.h
clang/include/clang/Driver/Options.td
clang/lib/Basic/CMakeLists.txt
clang/lib/Basic/TargetID.cpp
clang/lib/Basic/Targets/AMDGPU.cpp
clang/lib/Basic/Targets/AMDGPU.h
clang/lib/CodeGen/CodeGenModule.cpp
clang/lib/Driver/Driver.cpp
clang/lib/Driver/ToolChains/AMDGPU.cpp
clang/lib/Driver/ToolChains/AMDGPU.h
clang/lib/Driver/ToolChains/CommonArgs.cpp
clang/lib/Driver/ToolChains/HIP.cpp
clang/test/CodeGenCUDA/target-id.hip
clang/test/CodeGenOpenCL/target-id.cl
clang/test/Driver/Inputs/rocm/amdgcn/bitcode/oclc_isa_version_908.bc
clang/test/Driver/amdgpu-features.c
clang/test/Driver/amdgpu-macros.cl
clang/test/Driver/amdgpu-mcpu.cl
clang/test/Driver/hip-invalid-target-id.hip
clang/test/Driver/hip-target-id.hip
clang/test/Driver/hip-toolchain-features.hip
clang/test/Driver/invalid-target-id.cl
clang/test/Driver/target-id-macros.cl
clang/test/Driver/target-id-macros.hip
clang/test/Driver/target-id.cl
llvm/include/llvm/Support/TargetParser.h
llvm/lib/Support/TargetParser.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D60620.279000.patch
Type: text/x-patch
Size: 64787 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200718/5f5f0d4a/attachment-0001.bin>
------------------------------
Message: 13
Date: Sat, 18 Jul 2020 14:16:51 +0000 (UTC)
From: Hubert Tong via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: digger.llvm at gmail.com, jasonliu.development at gmail.com,
hubert.reinterpretcast at gmail.com, jh7370 at my.bristol.ac.uk,
maskray at google.com
Cc: 88888yl at gmail.com, llvm-commits at lists.llvm.org,
p8u8i7l5t1q9r8w3 at ibm-systems-z.slack.com
Subject: [PATCH] D81585: [AIX][XCOFF][Patch1] Provide decoding trace
back table information API for xcoff object file for llvm-objdump -d
Message-ID: <55ce9b69e00e240cc83fcd62a84ccbd3 at localhost.localdomain>
Content-Type: text/plain; charset=us-ascii
hubert.reinterpretcast added inline comments.
================
Comment at: llvm/include/llvm/Object/XCOFFObjectFile.h:403
+ Optional<SmallVector<uint32_t, 8>> ControlledStorageInfoDisp;
+ Optional<uint16_t> FunctionNameLen;
+ Optional<StringRef> FunctionName;
----------------
Why a separate field for the length of the function name? The `StringRef` for the function name has a length field.
================
Comment at: llvm/include/llvm/Object/XCOFFObjectFile.h:416
+ /// \param[in] Ptr
+ /// A pointer points to the beginning of XCOFF Traceback Table (right after
+ /// the initial 4 bytes of zeros).
----------------
s/pointer points/pointer that points/;
s/of XCOFF/of an XCOFF/;
================
Comment at: llvm/include/llvm/Object/XCOFFObjectFile.h:419
+ /// \param[in, out] Size
+ /// A pointer points to the length of the XCOFF Traceback Table.
+ /// If XCOFF Traceback Table is not parsed successfully or there are extra
----------------
s/pointer points/pointer that points/;
================
Comment at: llvm/include/llvm/Object/XCOFFObjectFile.h:422
+ /// bytes that are not recognized, \a Size will be updated to reflect the
+ /// actual length of the XCOFF Traceback Table that get parsed.
+ static Expected<XCOFFTracebackTable> create(const uint8_t *Ptr,
----------------
s/get/got/;
Is the value of `Size` modified or not when `create` reports an error? If modified, does `Size` represent the last successfully parsed field?
================
Comment at: llvm/include/llvm/Object/XCOFFObjectFile.h:434
+ bool hasTOC() const;
+ bool isFloatPointPresent() const;
+ bool isLogAbort() const;
----------------
Note: More instances of "FloatPoint" here.
================
Comment at: llvm/include/llvm/Object/XCOFFObjectFile.h:435
+ bool isFloatPointPresent() const;
+ bool isLogAbort() const;
+
----------------
The function names have fallen out of sync with the mask naming.
================
Comment at: llvm/include/llvm/Object/XCOFFObjectFile.h:440
+ bool isAllocaUsed() const;
+ uint8_t getClDisInv() const;
+ bool isCRSaved() const;
----------------
This name is very different from the name we are using for the associated mask. Please go through the names and resync.
================
Comment at: llvm/include/llvm/Object/XCOFFObjectFile.h:451
+
+ uint8_t getNumberOfFixedPara() const;
+
----------------
Same comments here as for the mask names.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D81585/new/
https://reviews.llvm.org/D81585
------------------------------
Message: 14
Date: Sat, 18 Jul 2020 14:20:01 +0000 (UTC)
From: Roman Lebedev via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: arichardson.kde at gmail.com, dblaikie at gmail.com
Cc: 88888yl at gmail.com, llvm-commits at lists.llvm.org
Subject: [PATCH] D84099: [llvm-reduce] Fix off-by one in argument
reduction pass
Message-ID: <847bdda9f52bc19dbe864ff3c29f8bd3 at localhost.localdomain>
Content-Type: text/plain; charset=us-ascii
lebedev.ri added inline comments.
================
Comment at: llvm/tools/llvm-reduce/deltas/ReduceArguments.cpp:84-87
int ArgI = 0;
for (auto &Arg : F->args())
if (ArgsToKeep.count(&Arg))
+ ArgIndexesToKeep.insert(ArgI++);
----------------
Let's take this one step further, shall we?
```
std::set<int> ArgIndexesToKeep;
for (auto &Arg : enumerate(F->args()))
if (ArgsToKeep.count(&Arg.value()))
ArgIndexesToKeep.insert(Arg.index());
```
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D84099/new/
https://reviews.llvm.org/D84099
------------------------------
Message: 15
Date: Sat, 18 Jul 2020 14:24:48 +0000 (UTC)
From: Ben Shi via Phabricator via llvm-commits
<llvm-commits at lists.llvm.org>
To: powerman1st at 163.com, t.p.northover at gmail.com,
greened at obbligato.org, anhtuyen at ca.ibm.com, efriedma at quicinc.com,
david.green at arm.com, sam.parker at arm.com
Cc: 88888yl at gmail.com, llvm-commits at lists.llvm.org, kanheim at a-bix.com,
kristof.beyls at arm.com, daniel.kiss at arm.com
Subject: [PATCH] D84100: [ARM] Optimize immediate selection
Message-ID:
<differential-rev-PHID-DREV-e747qjpy467kd7rwrccd-req at reviews.llvm.org>
Content-Type: text/plain; charset="utf-8"
benshi001 created this revision.
benshi001 added reviewers: t.p.northover, greened, anhtuyen, efriedma, dmgreen, samparker.
Herald added subscribers: llvm-commits, danielkiss, hiraditya, kristof.beyls.
Herald added a project: LLVM.
Optimize some specific immediate selection to movi+subri
or addri+subri against loading from the constant pool.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D84100
Files:
llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp
llvm/lib/Target/ARM/ARMExpandPseudoInsts.cpp
llvm/lib/Target/ARM/ARMInstrInfo.td
llvm/lib/Target/ARM/MCTargetDesc/ARMAddressingModes.h
llvm/test/CodeGen/ARM/sadd_sat.ll
llvm/test/CodeGen/ARM/ssub_sat.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D84100.279002.patch
Type: text/x-patch
Size: 11628 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200718/ddefd125/attachment.bin>
------------------------------
Subject: Digest Footer
_______________________________________________
llvm-commits mailing list
llvm-commits at lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
------------------------------
End of llvm-commits Digest, Vol 193, Issue 447
**********************************************
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200718/728998c9/attachment.html>
More information about the llvm-commits
mailing list