Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Mesa
mesa
Commits
8e430ff8
Commit
8e430ff8
authored
Nov 14, 2016
by
Vedran Miletić
Committed by
Tom Stellard
Nov 14, 2016
Browse files
clover: adapt to new error API since LLVM r286752
Tested-by:
Dieter Nützel
<
Dieter@nuetzel-hh.de
>
parent
c8a51fa7
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/gallium/state_trackers/clover/llvm/codegen/bitcode.cpp
View file @
8e430ff8
...
...
@@ -98,8 +98,14 @@ clover::llvm::parse_module_library(const module &m, ::llvm::LLVMContext &ctx,
std
::
string
&
r_log
)
{
auto
mod
=
::
llvm
::
parseBitcodeFile
(
::
llvm
::
MemoryBufferRef
(
as_string
(
m
.
secs
[
0
].
data
),
" "
),
ctx
);
if
(
!
mod
)
fail
(
r_log
,
error
(
CL_INVALID_PROGRAM
),
mod
.
getError
().
message
());
if
(
::
llvm
::
Error
err
=
mod
.
takeError
())
{
std
::
string
msg
;
::
llvm
::
handleAllErrors
(
std
::
move
(
err
),
[
&
](
::
llvm
::
ErrorInfoBase
&
EIB
)
{
msg
=
EIB
.
message
();
fail
(
r_log
,
error
(
CL_INVALID_PROGRAM
),
msg
.
c_str
());
});
}
return
std
::
unique_ptr
<::
llvm
::
Module
>
(
std
::
move
(
*
mod
));
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment