<div dir="ltr">Sorry, I didn't enable WebAssembly in my builds. Thanks.</div><br><div class="gmail_quote"><div dir="ltr">On Thu, Jan 28, 2016 at 2:13 PM JF Bastien <<a href="mailto:jfb@chromium.org">jfb@chromium.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">This broke the WebAssembly build, fixed in r259020.</div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jan 27, 2016 at 8:41 PM, NAKAMURA Takumi via llvm-commits <span dir="ltr"><<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: chapuni<br>
Date: Wed Jan 27 22:41:32 2016<br>
New Revision: 259016<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=259016&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=259016&view=rev</a><br>
Log:<br>
Revert r258951 (and r258950), "Refactor backend diagnostics for unsupported features"<br>
<br>
It broke layering violation in LLVMIR.<br>
<br>
clang r258950 "Add backend dignostic printer for unsupported features"<br>
llvm r258951 "Refactor backend diagnostics for unsupported features"<br>
<br>
Added:<br>
llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.cpp<br>
llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.h<br>
Removed:<br>
llvm/trunk/lib/CodeGen/DiagnosticInfoCodeGen.cpp<br>
Modified:<br>
llvm/trunk/include/llvm/IR/DiagnosticInfo.h<br>
llvm/trunk/lib/CodeGen/CMakeLists.txt<br>
llvm/trunk/lib/IR/DiagnosticInfo.cpp<br>
llvm/trunk/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp<br>
llvm/trunk/lib/Target/AMDGPU/AMDGPUISelLowering.cpp<br>
llvm/trunk/lib/Target/AMDGPU/CMakeLists.txt<br>
llvm/trunk/lib/Target/AMDGPU/SIISelLowering.cpp<br>
llvm/trunk/lib/Target/BPF/BPFISelLowering.cpp<br>
llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp<br>
llvm/trunk/test/CodeGen/AMDGPU/addrspacecast.ll<br>
llvm/trunk/test/CodeGen/AMDGPU/call.ll<br>
llvm/trunk/test/CodeGen/AMDGPU/dynamic_stackalloc.ll<br>
llvm/trunk/test/CodeGen/AMDGPU/global-zero-initializer.ll<br>
llvm/trunk/test/CodeGen/AMDGPU/lds-initializer.ll<br>
llvm/trunk/test/CodeGen/AMDGPU/lds-zero-initializer.ll<br>
llvm/trunk/test/CodeGen/AMDGPU/llvm.amdgcn.dispatch.ptr.ll<br>
llvm/trunk/test/CodeGen/AMDGPU/no-hsa-graphics-shaders.ll<br>
llvm/trunk/test/CodeGen/AMDGPU/promote-alloca-bitcast-function.ll<br>
<br>
Modified: llvm/trunk/include/llvm/IR/DiagnosticInfo.h<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/IR/DiagnosticInfo.h?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/IR/DiagnosticInfo.h?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/include/llvm/IR/DiagnosticInfo.h (original)<br>
+++ llvm/trunk/include/llvm/IR/DiagnosticInfo.h Wed Jan 27 22:41:32 2016<br>
@@ -16,7 +16,6 @@<br>
#define LLVM_IR_DIAGNOSTICINFO_H<br>
<br>
#include "llvm/ADT/ArrayRef.h"<br>
-#include "llvm/CodeGen/SelectionDAG.h"<br>
#include "llvm/IR/DebugLoc.h"<br>
#include "llvm/IR/Module.h"<br>
#include "llvm/Support/Casting.h"<br>
@@ -61,7 +60,6 @@ enum DiagnosticKind {<br>
DK_OptimizationFailure,<br>
DK_MIRParser,<br>
DK_PGOProfile,<br>
- DK_Unsupported,<br>
DK_FirstPluginKind<br>
};<br>
<br>
@@ -277,42 +275,8 @@ private:<br>
const Twine &Msg;<br>
};<br>
<br>
-/// Common features for diagnostics with an associated DebugLoc<br>
-class DiagnosticInfoWithDebugLocBase : public DiagnosticInfo {<br>
-public:<br>
- /// \p Fn is the function where the diagnostic is being emitted. \p DLoc is<br>
- /// the location information to use in the diagnostic.<br>
- DiagnosticInfoWithDebugLocBase(enum DiagnosticKind Kind,<br>
- enum DiagnosticSeverity Severity,<br>
- const Function &Fn,<br>
- const DebugLoc &DLoc)<br>
- : DiagnosticInfo(Kind, Severity), Fn(Fn), DLoc(DLoc) {}<br>
-<br>
- /// Return true if location information is available for this diagnostic.<br>
- bool isLocationAvailable() const;<br>
-<br>
- /// Return a string with the location information for this diagnostic<br>
- /// in the format "file:line:col". If location information is not available,<br>
- /// it returns "<unknown>:0:0".<br>
- const std::string getLocationStr() const;<br>
-<br>
- /// Return location information for this diagnostic in three parts:<br>
- /// the source file name, line number and column.<br>
- void getLocation(StringRef *Filename, unsigned *Line, unsigned *Column) const;<br>
-<br>
- const Function &getFunction() const { return Fn; }<br>
- const DebugLoc &getDebugLoc() const { return DLoc; }<br>
-<br>
-private:<br>
- /// Function where this diagnostic is triggered.<br>
- const Function &Fn;<br>
-<br>
- /// Debug location where this diagnostic is triggered.<br>
- DebugLoc DLoc;<br>
-};<br>
-<br>
/// Common features for diagnostics dealing with optimization remarks.<br>
-class DiagnosticInfoOptimizationBase : public DiagnosticInfoWithDebugLocBase {<br>
+class DiagnosticInfoOptimizationBase : public DiagnosticInfo {<br>
public:<br>
/// \p PassName is the name of the pass emitting this diagnostic.<br>
/// \p Fn is the function where the diagnostic is being emitted. \p DLoc is<br>
@@ -325,8 +289,8 @@ public:<br>
enum DiagnosticSeverity Severity,<br>
const char *PassName, const Function &Fn,<br>
const DebugLoc &DLoc, const Twine &Msg)<br>
- : DiagnosticInfoWithDebugLocBase(Kind, Severity, Fn, DLoc),<br>
- PassName(PassName), Msg(Msg) {}<br>
+ : DiagnosticInfo(Kind, Severity), PassName(PassName), Fn(Fn), DLoc(DLoc),<br>
+ Msg(Msg) {}<br>
<br>
/// \see DiagnosticInfo::print.<br>
void print(DiagnosticPrinter &DP) const override;<br>
@@ -338,7 +302,21 @@ public:<br>
/// in BackendConsumer::OptimizationRemarkHandler).<br>
virtual bool isEnabled() const = 0;<br>
<br>
+ /// Return true if location information is available for this diagnostic.<br>
+ bool isLocationAvailable() const;<br>
+<br>
+ /// Return a string with the location information for this diagnostic<br>
+ /// in the format "file:line:col". If location information is not available,<br>
+ /// it returns "<unknown>:0:0".<br>
+ const std::string getLocationStr() const;<br>
+<br>
+ /// Return location information for this diagnostic in three parts:<br>
+ /// the source file name, line number and column.<br>
+ void getLocation(StringRef *Filename, unsigned *Line, unsigned *Column) const;<br>
+<br>
const char *getPassName() const { return PassName; }<br>
+ const Function &getFunction() const { return Fn; }<br>
+ const DebugLoc &getDebugLoc() const { return DLoc; }<br>
const Twine &getMsg() const { return Msg; }<br>
<br>
private:<br>
@@ -347,6 +325,12 @@ private:<br>
/// be emitted.<br>
const char *PassName;<br>
<br>
+ /// Function where this diagnostic is triggered.<br>
+ const Function &Fn;<br>
+<br>
+ /// Debug location where this diagnostic is triggered.<br>
+ DebugLoc DLoc;<br>
+<br>
/// Message to report.<br>
const Twine &Msg;<br>
};<br>
@@ -588,35 +572,6 @@ public:<br>
bool isEnabled() const override;<br>
};<br>
<br>
-/// Diagnostic information for unsupported feature in backend.<br>
-class DiagnosticInfoUnsupported<br>
- : public DiagnosticInfoWithDebugLocBase {<br>
-private:<br>
- const Twine &Msg;<br>
- const SDValue Value;<br>
-<br>
-public:<br>
- /// \p Fn is the function where the diagnostic is being emitted. \p DLoc is<br>
- /// the location information to use in the diagnostic. If line table<br>
- /// information is available, the diagnostic will include the source code<br>
- /// location. \p Msg is the message to show. Note that this class does not<br>
- /// copy this message, so this reference must be valid for the whole life time<br>
- /// of the diagnostic.<br>
- DiagnosticInfoUnsupported(const Function &Fn, const Twine &Msg,<br>
- SDLoc DLoc = SDLoc(), SDValue Value = SDValue())<br>
- : DiagnosticInfoWithDebugLocBase(DK_Unsupported, DS_Error, Fn,<br>
- DLoc.getDebugLoc()),<br>
- Msg(Msg), Value(Value) {}<br>
-<br>
- static bool classof(const DiagnosticInfo *DI) {<br>
- return DI->getKind() == DK_Unsupported;<br>
- }<br>
-<br>
- const Twine &getMessage() const { return Msg; }<br>
-<br>
- void print(DiagnosticPrinter &DP) const;<br>
-};<br>
-<br>
/// Emit a warning when loop vectorization is specified but fails. \p Fn is the<br>
/// function triggering the warning, \p DLoc is the debug location where the<br>
/// diagnostic is generated. \p Msg is the message string to use.<br>
<br>
Modified: llvm/trunk/lib/CodeGen/CMakeLists.txt<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/CMakeLists.txt?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/CMakeLists.txt?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/CodeGen/CMakeLists.txt (original)<br>
+++ llvm/trunk/lib/CodeGen/CMakeLists.txt Wed Jan 27 22:41:32 2016<br>
@@ -18,7 +18,6 @@ add_llvm_library(LLVMCodeGen<br>
CriticalAntiDepBreaker.cpp<br>
DeadMachineInstructionElim.cpp<br>
DFAPacketizer.cpp<br>
- DiagnosticInfoCodeGen.cpp<br>
DwarfEHPrepare.cpp<br>
EarlyIfConversion.cpp<br>
EdgeBundles.cpp<br>
<br>
Removed: llvm/trunk/lib/CodeGen/DiagnosticInfoCodeGen.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/DiagnosticInfoCodeGen.cpp?rev=259015&view=auto" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/DiagnosticInfoCodeGen.cpp?rev=259015&view=auto</a><br>
==============================================================================<br>
--- llvm/trunk/lib/CodeGen/DiagnosticInfoCodeGen.cpp (original)<br>
+++ llvm/trunk/lib/CodeGen/DiagnosticInfoCodeGen.cpp (removed)<br>
@@ -1,33 +0,0 @@<br>
-//===- llvm/Support/DiagnosticInfo.cpp - Diagnostic Definitions -*- C++ -*-===//<br>
-//<br>
-// The LLVM Compiler Infrastructure<br>
-//<br>
-// This file is distributed under the University of Illinois Open Source<br>
-// License. See LICENSE.TXT for details.<br>
-//<br>
-//===----------------------------------------------------------------------===//<br>
-//<br>
-// This file defines the different classes involved in codegen diagnostics.<br>
-//<br>
-// Diagnostics reporting is still done as part of the LLVMContext.<br>
-//===----------------------------------------------------------------------===//<br>
-<br>
-#include "llvm/IR/DiagnosticInfo.h"<br>
-#include "llvm/IR/DiagnosticPrinter.h"<br>
-<br>
-namespace llvm {<br>
-<br>
-void DiagnosticInfoUnsupported::print(DiagnosticPrinter &DP) const {<br>
- std::string Str;<br>
- raw_string_ostream OS(Str);<br>
-<br>
- OS << getLocationStr() << ": in function " << getFunction().getName() << ' '<br>
- << *getFunction().getFunctionType() << ": " << Msg;<br>
- if (Value)<br>
- Value->print(OS);<br>
- OS << '\n';<br>
- OS.flush();<br>
- DP << Str;<br>
-}<br>
-<br>
-}<br>
<br>
Modified: llvm/trunk/lib/IR/DiagnosticInfo.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/DiagnosticInfo.cpp?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/DiagnosticInfo.cpp?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/IR/DiagnosticInfo.cpp (original)<br>
+++ llvm/trunk/lib/IR/DiagnosticInfo.cpp Wed Jan 27 22:41:32 2016<br>
@@ -138,11 +138,11 @@ void DiagnosticInfoPGOProfile::print(Dia<br>
DP << getMsg();<br>
}<br>
<br>
-bool DiagnosticInfoWithDebugLocBase::isLocationAvailable() const {<br>
+bool DiagnosticInfoOptimizationBase::isLocationAvailable() const {<br>
return getDebugLoc();<br>
}<br>
<br>
-void DiagnosticInfoWithDebugLocBase::getLocation(StringRef *Filename,<br>
+void DiagnosticInfoOptimizationBase::getLocation(StringRef *Filename,<br>
unsigned *Line,<br>
unsigned *Column) const {<br>
DILocation *L = getDebugLoc();<br>
@@ -152,7 +152,7 @@ void DiagnosticInfoWithDebugLocBase::get<br>
*Column = L->getColumn();<br>
}<br>
<br>
-const std::string DiagnosticInfoWithDebugLocBase::getLocationStr() const {<br>
+const std::string DiagnosticInfoOptimizationBase::getLocationStr() const {<br>
StringRef Filename("<unknown>");<br>
unsigned Line = 0;<br>
unsigned Column = 0;<br>
<br>
Added: llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.cpp?rev=259016&view=auto" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.cpp?rev=259016&view=auto</a><br>
==============================================================================<br>
--- llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.cpp (added)<br>
+++ llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.cpp Wed Jan 27 22:41:32 2016<br>
@@ -0,0 +1,26 @@<br>
+//===-- AMDGPUDiagnosticInfoUnsupported.cpp -------------------------------===//<br>
+//<br>
+// The LLVM Compiler Infrastructure<br>
+//<br>
+// This file is distributed under the University of Illinois Open Source<br>
+// License. See LICENSE.TXT for details.<br>
+//<br>
+//===----------------------------------------------------------------------===//<br>
+<br>
+#include "AMDGPUDiagnosticInfoUnsupported.h"<br>
+<br>
+using namespace llvm;<br>
+<br>
+DiagnosticInfoUnsupported::DiagnosticInfoUnsupported(<br>
+ const Function &Fn,<br>
+ const Twine &Desc,<br>
+ DiagnosticSeverity Severity)<br>
+ : DiagnosticInfo(getKindID(), Severity),<br>
+ Description(Desc),<br>
+ Fn(Fn) { }<br>
+<br>
+int DiagnosticInfoUnsupported::KindID = 0;<br>
+<br>
+void DiagnosticInfoUnsupported::print(DiagnosticPrinter &DP) const {<br>
+ DP << "unsupported " << getDescription() << " in " << Fn.getName();<br>
+}<br>
<br>
Added: llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.h<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.h?rev=259016&view=auto" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.h?rev=259016&view=auto</a><br>
==============================================================================<br>
--- llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.h (added)<br>
+++ llvm/trunk/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.h Wed Jan 27 22:41:32 2016<br>
@@ -0,0 +1,48 @@<br>
+//===-- AMDGPUDiagnosticInfoUnsupported.h - Error reporting -----*- C++ -*-===//<br>
+//<br>
+// The LLVM Compiler Infrastructure<br>
+//<br>
+// This file is distributed under the University of Illinois Open Source<br>
+// License. See LICENSE.TXT for details.<br>
+//<br>
+//===----------------------------------------------------------------------===//<br>
+<br>
+#ifndef LLVM_LIB_TARGET_AMDGPU_AMDGPUDIAGNOSTICINFOUNSUPPORTED_H<br>
+#define LLVM_LIB_TARGET_AMDGPU_AMDGPUDIAGNOSTICINFOUNSUPPORTED_H<br>
+<br>
+#include "llvm/IR/DiagnosticInfo.h"<br>
+#include "llvm/IR/DiagnosticPrinter.h"<br>
+<br>
+namespace llvm {<br>
+<br>
+/// Diagnostic information for unimplemented or unsupported feature reporting.<br>
+class DiagnosticInfoUnsupported : public DiagnosticInfo {<br>
+private:<br>
+ const Twine &Description;<br>
+ const Function &Fn;<br>
+<br>
+ static int KindID;<br>
+<br>
+ static int getKindID() {<br>
+ if (KindID == 0)<br>
+ KindID = llvm::getNextAvailablePluginDiagnosticKind();<br>
+ return KindID;<br>
+ }<br>
+<br>
+public:<br>
+ DiagnosticInfoUnsupported(const Function &Fn, const Twine &Desc,<br>
+ DiagnosticSeverity Severity = DS_Error);<br>
+<br>
+ const Function &getFunction() const { return Fn; }<br>
+ const Twine &getDescription() const { return Description; }<br>
+<br>
+ void print(DiagnosticPrinter &DP) const override;<br>
+<br>
+ static bool classof(const DiagnosticInfo *DI) {<br>
+ return DI->getKind() == getKindID();<br>
+ }<br>
+};<br>
+<br>
+}<br>
+<br>
+#endif<br>
<br>
Modified: llvm/trunk/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp (original)<br>
+++ llvm/trunk/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp Wed Jan 27 22:41:32 2016<br>
@@ -12,6 +12,7 @@<br>
//<br>
//===----------------------------------------------------------------------===//<br>
<br>
+#include "AMDGPUDiagnosticInfoUnsupported.h"<br>
#include "AMDGPUInstrInfo.h"<br>
#include "AMDGPUISelLowering.h" // For AMDGPUISD<br>
#include "AMDGPURegisterInfo.h"<br>
@@ -26,7 +27,6 @@<br>
#include "llvm/CodeGen/PseudoSourceValue.h"<br>
#include "llvm/CodeGen/SelectionDAG.h"<br>
#include "llvm/CodeGen/SelectionDAGISel.h"<br>
-#include "llvm/IR/DiagnosticInfo.h"<br>
#include "llvm/IR/Function.h"<br>
<br>
using namespace llvm;<br>
@@ -1220,7 +1220,7 @@ SDNode *AMDGPUDAGToDAGISel::SelectAddrSp<br>
<br>
const MachineFunction &MF = CurDAG->getMachineFunction();<br>
DiagnosticInfoUnsupported NotImplemented(*MF.getFunction(),<br>
- "addrspacecast not implemented", DL);<br>
+ "addrspacecast not implemented");<br>
CurDAG->getContext()->diagnose(NotImplemented);<br>
<br>
assert(Subtarget->hasFlatAddressSpace() &&<br>
<br>
Modified: llvm/trunk/lib/Target/AMDGPU/AMDGPUISelLowering.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/AMDGPUISelLowering.cpp?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/AMDGPUISelLowering.cpp?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/Target/AMDGPU/AMDGPUISelLowering.cpp (original)<br>
+++ llvm/trunk/lib/Target/AMDGPU/AMDGPUISelLowering.cpp Wed Jan 27 22:41:32 2016<br>
@@ -15,7 +15,7 @@<br>
<br>
#include "AMDGPUISelLowering.h"<br>
#include "AMDGPU.h"<br>
-//#include "AMDGPUDiagnosticInfoUnsupported.h"<br>
+#include "AMDGPUDiagnosticInfoUnsupported.h"<br>
#include "AMDGPUFrameLowering.h"<br>
#include "AMDGPUIntrinsicInfo.h"<br>
#include "AMDGPURegisterInfo.h"<br>
@@ -28,7 +28,6 @@<br>
#include "llvm/CodeGen/SelectionDAG.h"<br>
#include "llvm/CodeGen/TargetLoweringObjectFileImpl.h"<br>
#include "llvm/IR/DataLayout.h"<br>
-#include "llvm/IR/DiagnosticInfo.h"<br>
#include "SIInstrInfo.h"<br>
using namespace llvm;<br>
<br>
@@ -610,7 +609,7 @@ SDValue AMDGPUTargetLowering::LowerCall(<br>
else if (const GlobalAddressSDNode *G = dyn_cast<GlobalAddressSDNode>(Callee))<br>
FuncName = G->getGlobal()->getName();<br>
<br>
- DiagnosticInfoUnsupported NoCalls(Fn, "unsupported call to function " + FuncName, CLI.DL);<br>
+ DiagnosticInfoUnsupported NoCalls(Fn, "call to function " + FuncName);<br>
DAG.getContext()->diagnose(NoCalls);<br>
return SDValue();<br>
}<br>
@@ -619,7 +618,7 @@ SDValue AMDGPUTargetLowering::LowerDYNAM<br>
SelectionDAG &DAG) const {<br>
const Function &Fn = *DAG.getMachineFunction().getFunction();<br>
<br>
- DiagnosticInfoUnsupported NoDynamicAlloca(Fn, "unsupported dynamic alloca", SDLoc(Op));<br>
+ DiagnosticInfoUnsupported NoDynamicAlloca(Fn, "dynamic alloca");<br>
DAG.getContext()->diagnose(NoDynamicAlloca);<br>
return SDValue();<br>
}<br>
@@ -866,8 +865,8 @@ SDValue AMDGPUTargetLowering::LowerGloba<br>
}<br>
<br>
const Function &Fn = *DAG.getMachineFunction().getFunction();<br>
- DiagnosticInfoUnsupported BadInit(<br>
- Fn, "unsupported initializer for address space", SDLoc(Op));<br>
+ DiagnosticInfoUnsupported BadInit(Fn,<br>
+ "initializer for address space");<br>
DAG.getContext()->diagnose(BadInit);<br>
return SDValue();<br>
}<br>
<br>
Modified: llvm/trunk/lib/Target/AMDGPU/CMakeLists.txt<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/CMakeLists.txt?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/CMakeLists.txt?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/Target/AMDGPU/CMakeLists.txt (original)<br>
+++ llvm/trunk/lib/Target/AMDGPU/CMakeLists.txt Wed Jan 27 22:41:32 2016<br>
@@ -18,6 +18,7 @@ add_llvm_target(AMDGPUCodeGen<br>
AMDGPUAnnotateKernelFeatures.cpp<br>
AMDGPUAnnotateUniformValues.cpp<br>
AMDGPUAsmPrinter.cpp<br>
+ AMDGPUDiagnosticInfoUnsupported.cpp<br>
AMDGPUFrameLowering.cpp<br>
AMDGPUTargetObjectFile.cpp<br>
AMDGPUIntrinsicInfo.cpp<br>
<br>
Modified: llvm/trunk/lib/Target/AMDGPU/SIISelLowering.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/SIISelLowering.cpp?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/SIISelLowering.cpp?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/Target/AMDGPU/SIISelLowering.cpp (original)<br>
+++ llvm/trunk/lib/Target/AMDGPU/SIISelLowering.cpp Wed Jan 27 22:41:32 2016<br>
@@ -20,6 +20,7 @@<br>
<br>
#include "SIISelLowering.h"<br>
#include "AMDGPU.h"<br>
+#include "AMDGPUDiagnosticInfoUnsupported.h"<br>
#include "AMDGPUIntrinsicInfo.h"<br>
#include "AMDGPUSubtarget.h"<br>
#include "SIInstrInfo.h"<br>
@@ -31,7 +32,6 @@<br>
#include "llvm/CodeGen/MachineInstrBuilder.h"<br>
#include "llvm/CodeGen/MachineRegisterInfo.h"<br>
#include "llvm/CodeGen/SelectionDAG.h"<br>
-#include "llvm/IR/DiagnosticInfo.h"<br>
#include "llvm/IR/Function.h"<br>
#include "llvm/ADT/SmallString.h"<br>
<br>
@@ -591,8 +591,7 @@ SDValue SITargetLowering::LowerFormalArg<br>
<br>
if (Subtarget->isAmdHsaOS() && Info->getShaderType() != ShaderType::COMPUTE) {<br>
const Function *Fn = MF.getFunction();<br>
- DiagnosticInfoUnsupported NoGraphicsHSA(<br>
- *Fn, "unsupported non-compute shaders with HSA", DL);<br>
+ DiagnosticInfoUnsupported NoGraphicsHSA(*Fn, "non-compute shaders with HSA");<br>
DAG.getContext()->diagnose(NoGraphicsHSA);<br>
return SDValue();<br>
}<br>
@@ -1321,9 +1320,8 @@ SDValue SITargetLowering::LowerINTRINSIC<br>
switch (IntrinsicID) {<br>
case Intrinsic::amdgcn_dispatch_ptr:<br>
if (!Subtarget->isAmdHsaOS()) {<br>
- DiagnosticInfoUnsupported BadIntrin(<br>
- *MF.getFunction(), "unsupported hsa intrinsic without hsa target",<br>
- DL);<br>
+ DiagnosticInfoUnsupported BadIntrin(*MF.getFunction(),<br>
+ "hsa intrinsic without hsa target");<br>
DAG.getContext()->diagnose(BadIntrin);<br>
return DAG.getUNDEF(VT);<br>
}<br>
<br>
Modified: llvm/trunk/lib/Target/BPF/BPFISelLowering.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/BPF/BPFISelLowering.cpp?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/BPF/BPFISelLowering.cpp?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/Target/BPF/BPFISelLowering.cpp (original)<br>
+++ llvm/trunk/lib/Target/BPF/BPFISelLowering.cpp Wed Jan 27 22:41:32 2016<br>
@@ -34,6 +34,60 @@ using namespace llvm;<br>
<br>
#define DEBUG_TYPE "bpf-lower"<br>
<br>
+namespace {<br>
+<br>
+// Diagnostic information for unimplemented or unsupported feature reporting.<br>
+class DiagnosticInfoUnsupported : public DiagnosticInfo {<br>
+private:<br>
+ // Debug location where this diagnostic is triggered.<br>
+ DebugLoc DLoc;<br>
+ const Twine &Description;<br>
+ const Function &Fn;<br>
+ SDValue Value;<br>
+<br>
+ static int KindID;<br>
+<br>
+ static int getKindID() {<br>
+ if (KindID == 0)<br>
+ KindID = llvm::getNextAvailablePluginDiagnosticKind();<br>
+ return KindID;<br>
+ }<br>
+<br>
+public:<br>
+ DiagnosticInfoUnsupported(SDLoc DLoc, const Function &Fn, const Twine &Desc,<br>
+ SDValue Value)<br>
+ : DiagnosticInfo(getKindID(), DS_Error), DLoc(DLoc.getDebugLoc()),<br>
+ Description(Desc), Fn(Fn), Value(Value) {}<br>
+<br>
+ void print(DiagnosticPrinter &DP) const override {<br>
+ std::string Str;<br>
+ raw_string_ostream OS(Str);<br>
+<br>
+ if (DLoc) {<br>
+ auto DIL = DLoc.get();<br>
+ StringRef Filename = DIL->getFilename();<br>
+ unsigned Line = DIL->getLine();<br>
+ unsigned Column = DIL->getColumn();<br>
+ OS << Filename << ':' << Line << ':' << Column << ' ';<br>
+ }<br>
+<br>
+ OS << "in function " << Fn.getName() << ' ' << *Fn.getFunctionType() << '\n'<br>
+ << Description;<br>
+ if (Value)<br>
+ Value->print(OS);<br>
+ OS << '\n';<br>
+ OS.flush();<br>
+ DP << Str;<br>
+ }<br>
+<br>
+ static bool classof(const DiagnosticInfo *DI) {<br>
+ return DI->getKind() == getKindID();<br>
+ }<br>
+};<br>
+<br>
+int DiagnosticInfoUnsupported::KindID = 0;<br>
+}<br>
+<br>
BPFTargetLowering::BPFTargetLowering(const TargetMachine &TM,<br>
const BPFSubtarget &STI)<br>
: TargetLowering(TM) {<br>
@@ -182,16 +236,16 @@ SDValue BPFTargetLowering::LowerFormalAr<br>
InVals.push_back(ArgValue);<br>
}<br>
} else {<br>
- DiagnosticInfoUnsupported Err(<br>
- *MF.getFunction(), "defined with too many args", DL);<br>
+ DiagnosticInfoUnsupported Err(DL, *MF.getFunction(),<br>
+ "defined with too many args", SDValue());<br>
DAG.getContext()->diagnose(Err);<br>
}<br>
}<br>
<br>
if (IsVarArg || MF.getFunction()->hasStructRetAttr()) {<br>
DiagnosticInfoUnsupported Err(<br>
- *MF.getFunction(),<br>
- "functions with VarArgs or StructRet are not supported", DL);<br>
+ DL, *MF.getFunction(),<br>
+ "functions with VarArgs or StructRet are not supported", SDValue());<br>
DAG.getContext()->diagnose(Err);<br>
}<br>
<br>
@@ -231,8 +285,8 @@ SDValue BPFTargetLowering::LowerCall(Tar<br>
unsigned NumBytes = CCInfo.getNextStackOffset();<br>
<br>
if (Outs.size() >= 6) {<br>
- DiagnosticInfoUnsupported Err(*MF.getFunction(), "too many args to ",<br>
- CLI.DL, Callee);<br>
+ DiagnosticInfoUnsupported Err(CLI.DL, *MF.getFunction(),<br>
+ "too many args to ", Callee);<br>
DAG.getContext()->diagnose(Err);<br>
}<br>
<br>
@@ -241,8 +295,8 @@ SDValue BPFTargetLowering::LowerCall(Tar<br>
if (!Flags.isByVal())<br>
continue;<br>
<br>
- DiagnosticInfoUnsupported Err(<br>
- *MF.getFunction(), "pass by value not supported ", CLI.DL, Callee);<br>
+ DiagnosticInfoUnsupported Err(CLI.DL, *MF.getFunction(),<br>
+ "pass by value not supported ", Callee);<br>
DAG.getContext()->diagnose(Err);<br>
}<br>
<br>
@@ -344,8 +398,8 @@ BPFTargetLowering::LowerReturn(SDValue C<br>
CCState CCInfo(CallConv, IsVarArg, MF, RVLocs, *DAG.getContext());<br>
<br>
if (MF.getFunction()->getReturnType()->isAggregateType()) {<br>
- DiagnosticInfoUnsupported Err(<br>
- *MF.getFunction(), "only integer returns supported", DL);<br>
+ DiagnosticInfoUnsupported Err(DL, *MF.getFunction(),<br>
+ "only integer returns supported", SDValue());<br>
DAG.getContext()->diagnose(Err);<br>
}<br>
<br>
@@ -389,8 +443,8 @@ SDValue BPFTargetLowering::LowerCallResu<br>
CCState CCInfo(CallConv, IsVarArg, MF, RVLocs, *DAG.getContext());<br>
<br>
if (Ins.size() >= 2) {<br>
- DiagnosticInfoUnsupported Err(*MF.getFunction(),<br>
- "only small returns supported", DL);<br>
+ DiagnosticInfoUnsupported Err(DL, *MF.getFunction(),<br>
+ "only small returns supported", SDValue());<br>
DAG.getContext()->diagnose(Err);<br>
}<br>
<br>
<br>
Modified: llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp (original)<br>
+++ llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp Wed Jan 27 22:41:32 2016<br>
@@ -35,6 +35,61 @@ using namespace llvm;<br>
<br>
#define DEBUG_TYPE "wasm-lower"<br>
<br>
+namespace {<br>
+// Diagnostic information for unimplemented or unsupported feature reporting.<br>
+// TODO: This code is copied from BPF and AMDGPU; consider factoring it out<br>
+// and sharing code.<br>
+class DiagnosticInfoUnsupported final : public DiagnosticInfo {<br>
+private:<br>
+ // Debug location where this diagnostic is triggered.<br>
+ DebugLoc DLoc;<br>
+ const Twine &Description;<br>
+ const Function &Fn;<br>
+ SDValue Value;<br>
+<br>
+ static int KindID;<br>
+<br>
+ static int getKindID() {<br>
+ if (KindID == 0)<br>
+ KindID = llvm::getNextAvailablePluginDiagnosticKind();<br>
+ return KindID;<br>
+ }<br>
+<br>
+public:<br>
+ DiagnosticInfoUnsupported(SDLoc DLoc, const Function &Fn, const Twine &Desc,<br>
+ SDValue Value)<br>
+ : DiagnosticInfo(getKindID(), DS_Error), DLoc(DLoc.getDebugLoc()),<br>
+ Description(Desc), Fn(Fn), Value(Value) {}<br>
+<br>
+ void print(DiagnosticPrinter &DP) const override {<br>
+ std::string Str;<br>
+ raw_string_ostream OS(Str);<br>
+<br>
+ if (DLoc) {<br>
+ auto DIL = DLoc.get();<br>
+ StringRef Filename = DIL->getFilename();<br>
+ unsigned Line = DIL->getLine();<br>
+ unsigned Column = DIL->getColumn();<br>
+ OS << Filename << ':' << Line << ':' << Column << ' ';<br>
+ }<br>
+<br>
+ OS << "in function " << Fn.getName() << ' ' << *Fn.getFunctionType() << '\n'<br>
+ << Description;<br>
+ if (Value)<br>
+ Value->print(OS);<br>
+ OS << '\n';<br>
+ OS.flush();<br>
+ DP << Str;<br>
+ }<br>
+<br>
+ static bool classof(const DiagnosticInfo *DI) {<br>
+ return DI->getKind() == getKindID();<br>
+ }<br>
+};<br>
+<br>
+int DiagnosticInfoUnsupported::KindID = 0;<br>
+} // end anonymous namespace<br>
+<br>
WebAssemblyTargetLowering::WebAssemblyTargetLowering(<br>
const TargetMachine &TM, const WebAssemblySubtarget &STI)<br>
: TargetLowering(TM), Subtarget(&STI) {<br>
<br>
Modified: llvm/trunk/test/CodeGen/AMDGPU/addrspacecast.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/addrspacecast.ll?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/addrspacecast.ll?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/CodeGen/AMDGPU/addrspacecast.ll (original)<br>
+++ llvm/trunk/test/CodeGen/AMDGPU/addrspacecast.ll Wed Jan 27 22:41:32 2016<br>
@@ -1,6 +1,6 @@<br>
; RUN: not llc -O0 -march=amdgcn -mcpu=bonaire -mattr=-promote-alloca < %s 2>&1 | FileCheck -check-prefix=ERROR %s<br>
<br>
-; ERROR: addrspacecast not implemented<br>
+; ERROR: unsupported addrspacecast not implemented<br>
<br>
; XUN: llc -O0 -march=amdgcn -mcpu=bonaire -mattr=-promote-alloca < %s | FileCheck -check-prefix=CHECK -check-prefix=CHECK-NO-PROMOTE %s<br>
; XUN: llc -O0 -march=amdgcn -mcpu=bonaire -mattr=+promote-alloca < %s | FileCheck -check-prefix=CHECK -check-prefix=CHECK-PROMOTE %s<br>
<br>
Modified: llvm/trunk/test/CodeGen/AMDGPU/call.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/call.ll?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/call.ll?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/CodeGen/AMDGPU/call.ll (original)<br>
+++ llvm/trunk/test/CodeGen/AMDGPU/call.ll Wed Jan 27 22:41:32 2016<br>
@@ -2,7 +2,7 @@<br>
; RUN: not llc -march=amdgcn -mcpu=tonga -verify-machineinstrs< %s 2>&1 | FileCheck %s<br>
; RUN: not llc -march=r600 -mcpu=cypress < %s 2>&1 | FileCheck %s<br>
<br>
-; CHECK: in function test_call_external{{.*}}: unsupported call to function external_function<br>
+; CHECK: error: unsupported call to function external_function in test_call_external<br>
<br>
<br>
declare i32 @external_function(i32) nounwind<br>
<br>
Modified: llvm/trunk/test/CodeGen/AMDGPU/dynamic_stackalloc.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/dynamic_stackalloc.ll?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/dynamic_stackalloc.ll?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/CodeGen/AMDGPU/dynamic_stackalloc.ll (original)<br>
+++ llvm/trunk/test/CodeGen/AMDGPU/dynamic_stackalloc.ll Wed Jan 27 22:41:32 2016<br>
@@ -2,7 +2,7 @@<br>
; RUN: not llc -march=amdgcn -mcpu=tahiti -mattr=-promote-alloca -verify-machineinstrs < %s 2>&1 | FileCheck %s<br>
; RUN: not llc -march=r600 -mcpu=cypress < %s 2>&1 | FileCheck %s<br>
<br>
-; CHECK: in function test_dynamic_stackalloc{{.*}}: unsupported dynamic alloca<br>
+; CHECK: error: unsupported dynamic alloca in test_dynamic_stackalloc<br>
<br>
define void @test_dynamic_stackalloc(i32 addrspace(1)* %out, i32 %n) {<br>
%alloca = alloca i32, i32 %n<br>
<br>
Modified: llvm/trunk/test/CodeGen/AMDGPU/global-zero-initializer.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/global-zero-initializer.ll?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/global-zero-initializer.ll?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/CodeGen/AMDGPU/global-zero-initializer.ll (original)<br>
+++ llvm/trunk/test/CodeGen/AMDGPU/global-zero-initializer.ll Wed Jan 27 22:41:32 2016<br>
@@ -1,7 +1,7 @@<br>
; RUN: not llc -march=amdgcn -mcpu=SI < %s 2>&1 | FileCheck %s<br>
; RUN: not llc -march=amdgcn -mcpu=tonga < %s 2>&1 | FileCheck %s<br>
<br>
-; CHECK: in function load_init_global_global{{.*}}: unsupported initializer for address space<br>
+; CHECK: error: unsupported initializer for address space in load_init_global_global<br>
<br>
@lds = addrspace(1) global [256 x i32] zeroinitializer<br>
<br>
<br>
Modified: llvm/trunk/test/CodeGen/AMDGPU/lds-initializer.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/lds-initializer.ll?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/lds-initializer.ll?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/CodeGen/AMDGPU/lds-initializer.ll (original)<br>
+++ llvm/trunk/test/CodeGen/AMDGPU/lds-initializer.ll Wed Jan 27 22:41:32 2016<br>
@@ -1,7 +1,7 @@<br>
; RUN: not llc -march=amdgcn -mcpu=SI < %s 2>&1 | FileCheck %s<br>
; RUN: not llc -march=amdgcn -mcpu=tonga < %s 2>&1 | FileCheck %s<br>
<br>
-; CHECK: in function load_init_lds_global{{.*}}: unsupported initializer for address space<br>
+; CHECK: error: unsupported initializer for address space in load_init_lds_global<br>
<br>
@lds = addrspace(3) global [8 x i32] [i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 8]<br>
<br>
<br>
Modified: llvm/trunk/test/CodeGen/AMDGPU/lds-zero-initializer.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/lds-zero-initializer.ll?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/lds-zero-initializer.ll?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/CodeGen/AMDGPU/lds-zero-initializer.ll (original)<br>
+++ llvm/trunk/test/CodeGen/AMDGPU/lds-zero-initializer.ll Wed Jan 27 22:41:32 2016<br>
@@ -1,7 +1,7 @@<br>
; RUN: not llc -march=amdgcn -mcpu=SI < %s 2>&1 | FileCheck %s<br>
; RUN: not llc -march=amdgcn -mcpu=tonga < %s 2>&1 | FileCheck %s<br>
<br>
-; CHECK: in function load_zeroinit_lds_global{{.*}}: unsupported initializer for address space<br>
+; CHECK: error: unsupported initializer for address space in load_zeroinit_lds_global<br>
<br>
@lds = addrspace(3) global [256 x i32] zeroinitializer<br>
<br>
<br>
Modified: llvm/trunk/test/CodeGen/AMDGPU/llvm.amdgcn.dispatch.ptr.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/llvm.amdgcn.dispatch.ptr.ll?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/llvm.amdgcn.dispatch.ptr.ll?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/CodeGen/AMDGPU/llvm.amdgcn.dispatch.ptr.ll (original)<br>
+++ llvm/trunk/test/CodeGen/AMDGPU/llvm.amdgcn.dispatch.ptr.ll Wed Jan 27 22:41:32 2016<br>
@@ -1,7 +1,7 @@<br>
; RUN: llc -mtriple=amdgcn--amdhsa -mcpu=kaveri -verify-machineinstrs < %s | FileCheck -check-prefix=GCN %s<br>
; RUN: not llc -mtriple=amdgcn-unknown-unknown -mcpu=kaveri -verify-machineinstrs < %s 2>&1 | FileCheck -check-prefix=ERROR %s<br>
<br>
-; ERROR: in function test{{.*}}: unsupported hsa intrinsic without hsa target<br>
+; ERROR: error: unsupported hsa intrinsic without hsa target in test<br>
<br>
; GCN-LABEL: {{^}}test:<br>
; GCN: enable_sgpr_dispatch_ptr = 1<br>
<br>
Modified: llvm/trunk/test/CodeGen/AMDGPU/no-hsa-graphics-shaders.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/no-hsa-graphics-shaders.ll?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/no-hsa-graphics-shaders.ll?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/CodeGen/AMDGPU/no-hsa-graphics-shaders.ll (original)<br>
+++ llvm/trunk/test/CodeGen/AMDGPU/no-hsa-graphics-shaders.ll Wed Jan 27 22:41:32 2016<br>
@@ -1,6 +1,6 @@<br>
; RUN: not llc -march=amdgcn -mtriple=amdgcn-unknown-amdhsa < %s 2>&1 | FileCheck %s<br>
<br>
-; CHECK: in function pixel_s{{.*}}: unsupported non-compute shaders with HSA<br>
+; CHECK: error: unsupported non-compute shaders with HSA in pixel_shader<br>
define void @pixel_shader() #0 {<br>
ret void<br>
}<br>
<br>
Modified: llvm/trunk/test/CodeGen/AMDGPU/promote-alloca-bitcast-function.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/promote-alloca-bitcast-function.ll?rev=259016&r1=259015&r2=259016&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/AMDGPU/promote-alloca-bitcast-function.ll?rev=259016&r1=259015&r2=259016&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/CodeGen/AMDGPU/promote-alloca-bitcast-function.ll (original)<br>
+++ llvm/trunk/test/CodeGen/AMDGPU/promote-alloca-bitcast-function.ll Wed Jan 27 22:41:32 2016<br>
@@ -6,7 +6,7 @@<br>
declare void @foo(float*) #0<br>
declare void @foo.varargs(...) #0<br>
<br>
-; CHECK: in function crash_call_constexpr_cast{{.*}}: unsupported call to function foo<br>
+; CHECK: error: unsupported call to function foo in crash_call_constexpr_cast<br>
define void @crash_call_constexpr_cast() #0 {<br>
%alloca = alloca i32<br>
call void bitcast (void (float*)* @foo to void (i32*)*)(i32* %alloca) #0<br>
<br>
<br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits</a><br>
</blockquote></div><br></div>
</blockquote></div>