Commit 5bd80722 by Antonio Maiorano

Android: add llvm-10 build file and fix build

This change makes it possible to build SwiftShader against llvm-10 on Android. To enable this, the root Android.bp must be modified to depend on libLLVM10_swiftshader, which will be done in a separate change. Successfully built for arm, arm64, x86, and x64 with the following lunch configs: * blueline-userdebug * aosp_x86-eng * aosp_x86_64-eng Bug: b/152339534 Change-Id: Id70f16f1dbde313bb97763d8a10a73a92c3530c9 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/46289 Kokoro-Result: kokoro <noreply+kokoro@google.com> Tested-by: 's avatarAntonio Maiorano <amaiorano@google.com> Reviewed-by: 's avatarNicolas Capens <nicolascapens@google.com>
parent 594318ea
...@@ -171,6 +171,7 @@ llvm::Value *lowerTrunc(llvm::Value *x) ...@@ -171,6 +171,7 @@ llvm::Value *lowerTrunc(llvm::Value *x)
return jit->builder->CreateCall(trunc, ARGS(x)); return jit->builder->CreateCall(trunc, ARGS(x));
} }
# if LLVM_VERSION_MAJOR < 8
// Packed add/sub with saturation // Packed add/sub with saturation
llvm::Value *lowerPSAT(llvm::Value *x, llvm::Value *y, bool isAdd, bool isSigned) llvm::Value *lowerPSAT(llvm::Value *x, llvm::Value *y, bool isAdd, bool isSigned)
{ {
...@@ -205,6 +206,7 @@ llvm::Value *lowerPSAT(llvm::Value *x, llvm::Value *y, bool isAdd, bool isSigned ...@@ -205,6 +206,7 @@ llvm::Value *lowerPSAT(llvm::Value *x, llvm::Value *y, bool isAdd, bool isSigned
return jit->builder->CreateTrunc(res, ty); return jit->builder->CreateTrunc(res, ty);
} }
# endif // LLVM_VERSION_MAJOR < 8
llvm::Value *lowerSQRT(llvm::Value *x) llvm::Value *lowerSQRT(llvm::Value *x)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment