OSDN Git Service

New integer related core functions
authorAlexis Hetu <sugoi@google.com>
Tue, 18 Aug 2015 19:43:09 +0000 (15:43 -0400)
committerAlexis Hétu <sugoi@google.com>
Fri, 28 Aug 2015 18:11:39 +0000 (18:11 +0000)
commitc4f2c2970f43bfe8a89289a3300fd68e01ff0976
tree86b412371fd36b9ab9a450f5ad369247b49b040e
parentc4b57f53c63ca6ffeff9224ec374cf90c4ade3eb
New integer related core functions

- Removed float <-> int bit conversion functions, as these
  will not be needed if everything is stored as float.
- Added ineg for the minus (-) sign in from of a value.
- Added f2i/i2f/f2u/u2f for float <-> int conversions
- Added b2i/i2b/b2u/u2b for bool <-> int conversions
- Added iadd, isub, imul, imad, [iu]div, [iu]mod, [iu]min,
  [iu]max for these basic operations as integer operations.
- Added left and right shifts
- Added ucmp to compare unsigned values
- Modified or/xor/and to support vectors instead of only
  scalars.
- Added vector equality comparison functions

Change-Id: I0f138e3707242ec0fffc1c12b95064ddc98f0087
Reviewed-on: https://swiftshader-review.googlesource.com/3888
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
src/Shader/PixelProgram.cpp
src/Shader/ShaderCore.cpp
src/Shader/ShaderCore.hpp
src/Shader/VertexProgram.cpp