mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-22 02:33:06 +01:00
[test] Speculative fix for bots
Bot has error "Failed to create target from default triple: Unable to find target for this triple (no targets are registered)", likely because we only initialized the native target, not the registered target if it's different. https://lab.llvm.org/buildbot/#/builders/86/builds/13664
This commit is contained in:
parent
4e7133736e
commit
3cf1e94194
@ -15,12 +15,13 @@ using namespace llvm;
|
||||
|
||||
class PassBuilderCTest : public testing::Test {
|
||||
void SetUp() override {
|
||||
LLVMInitializeNativeTarget();
|
||||
LLVMInitializeAllTargetInfos();
|
||||
char *Triple = LLVMGetDefaultTargetTriple();
|
||||
char *Err;
|
||||
LLVMTargetRef Target;
|
||||
if (LLVMGetTargetFromTriple(Triple, &Target, &Err)) {
|
||||
FAIL() << "Failed to create target from default triple: " << Err;
|
||||
FAIL() << "Failed to create target from default triple (" << Triple
|
||||
<< "): " << Err;
|
||||
}
|
||||
TM = LLVMCreateTargetMachine(Target, Triple, "generic", "",
|
||||
LLVMCodeGenLevelDefault, LLVMRelocDefault,
|
||||
|
Loading…
Reference in New Issue
Block a user