35 lines
1.4 KiB
Diff
35 lines
1.4 KiB
Diff
|
From c03a5142444476a1caa5c2ba7fa2d92d7793d6f1 Mon Sep 17 00:00:00 2001
|
||
|
From: Deepak Rajendrakumaran <deepak.rajendrakumaran@intel.com>
|
||
|
Date: Mon, 25 Jan 2021 09:22:49 -0800
|
||
|
Subject: [PATCH] Fixing build on llvm trunk.
|
||
|
|
||
|
---
|
||
|
src/ctx.cpp | 7 +++----
|
||
|
1 file changed, 3 insertions(+), 4 deletions(-)
|
||
|
|
||
|
diff --git a/src/ctx.cpp b/src/ctx.cpp
|
||
|
index ded524b71..b60e6fe84 100644
|
||
|
--- a/src/ctx.cpp
|
||
|
+++ b/src/ctx.cpp
|
||
|
@@ -1020,8 +1020,7 @@ void FunctionEmitContext::EmitCaseLabel(int value, bool checkMask, SourcePos pos
|
||
|
llvm::BasicBlock *bbCaseImpl = NULL;
|
||
|
if (emitGenXHardwareMask()) {
|
||
|
// Create basic block with actual case implementation
|
||
|
- llvm::Twine bbName = llvm::Twine(bbCase->getName()) + "_impl";
|
||
|
- bbCaseImpl = CreateBasicBlock(bbName, bbCase);
|
||
|
+ bbCaseImpl = CreateBasicBlock(llvm::Twine(bbCase->getName()) + "_impl", bbCase);
|
||
|
}
|
||
|
#endif
|
||
|
|
||
|
@@ -3142,8 +3141,8 @@ llvm::Value *FunctionEmitContext::BroadcastValue(llvm::Value *v, llvm::Type *vec
|
||
|
llvm::Value *undef2 = llvm::UndefValue::get(vecType);
|
||
|
|
||
|
// InsertElement
|
||
|
- llvm::Twine tw = name.isTriviallyEmpty() ? (llvm::Twine(v->getName()) + "_broadcast") : name + llvm::Twine("_init");
|
||
|
- llvm::Value *insert = InsertInst(undef1, v, 0, tw.str().c_str());
|
||
|
+ llvm::Value *insert =
|
||
|
+ InsertInst(undef1, v, 0, name.isTriviallyEmpty() ? (llvm::Twine(v->getName()) + "_broadcast") : name + "_init");
|
||
|
|
||
|
// ShuffleVector
|
||
|
#if ISPC_LLVM_VERSION < ISPC_LLVM_11_0
|