- 16 Nov, 2017 9 commits
-
-
Nicolas Capens authored
This optimizes evaluation of chained indexing operations by first looking for an lvalue 'root' node and copying from it directly into the topmost rvalue, instead of creating potentially many temporaries. Change-Id: I47cf9b0230bd305695e7b2a44ddc44bc1320b764 Reviewed-on: https://swiftshader-review.googlesource.com/13908Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
Change-Id: I25251e94680624c8c85698e96a053f518bb2c367 Reviewed-on: https://swiftshader-review.googlesource.com/13968Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
After traversing the lvalue node tree we're fully done computing the relative address and emitting any pointer arithmetic that might have been needed. So the temporary that would have been used for that is no longer needed. Change-Id: I0a10bff979128f03544d0f8aa860c29f8867973a Reviewed-on: https://swiftshader-review.googlesource.com/13948Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Nicolas Capens authored
This will enable reusing it to determine the root node of rvalues as well. The only functional change is that struct indexing no longer overrides the register type. This is of no effect here since lvalue intermediates already inherited their type from the root node, but for rvalues the intermediates are considered temporary registers, while instead the root's type should be used. Change-Id: I2dbd1b0f8886c3f111a2ed3ef7fe4e9a5b480085 Reviewed-on: https://swiftshader-review.googlesource.com/13930Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
Previously we processed assignments in PostVisit, i.e. after both the left and right side had been traversed. This produces temporaries for the left hand side, which we don't use since we want to assign to the lvalue. So instead we can explicitly traverse the right hand side, and for the left hand side only traverse indirect indexing expressions. Change-Id: I9ec0596a9c256921b65a9f70428d950959f66aa0 Reviewed-on: https://swiftshader-review.googlesource.com/13630Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
GLSL ES 3.0 interface blocks always have uniform storage qualification and thus can't be used as l-value. Change-Id: Iffe948dccbf2edb28eb1abe52a6f28dc76a1e84b Reviewed-on: https://swiftshader-review.googlesource.com/13929Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
This matches Shader Model 4+ assembly syntax and helps debug shader compilation issues. Change-Id: Iff2a2991794e13476b99e11d6ac07fdf5d37570b Reviewed-on: https://swiftshader-review.googlesource.com/13928Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
The integer modifier was used to emulate integer arithmetic using floating-point operations, as was allowed/typical for OpenGL ES 2.0 implementations. Now that we support native 32-bit integer types and we have separate opcodes for integer operations, it is not longer needed. Change-Id: I89987534c150d2426ac9f9e1e49b66f9deaee560 Reviewed-on: https://swiftshader-review.googlesource.com/13889Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
Matrix elements cannot be accessed with dot notation. Change-Id: I48258428e3fa5ffe9c95a8983516433b98ce233a Reviewed-on: https://swiftshader-review.googlesource.com/13629Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
- 15 Nov, 2017 3 commits
-
-
Alexis Hetu authored
glDeleteSync can only delete an existing FenceSync object. Change-Id: Ieb78894175235cc97c67ff0324d59bb5d7619918 Reviewed-on: https://swiftshader-review.googlesource.com/13829Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Alexis Hetu authored
GL_INVALID_OPERATION is generated if a non-zero vertex array object is bound, zero is bound to the GL_ARRAY_BUFFER buffer object binding point and the pointer argument is not NULL. Change-Id: I48e73dca96bac2bd0496c202785e46e7d754dc11 Reviewed-on: https://swiftshader-review.googlesource.com/13830Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Alexis Hetu authored
While GL_ANY_SAMPLES_PASSED_CONSERVATIVE_EXT and GL_ANY_SAMPLES_PASSED_EXT are mutually exclusive, they can be used simultaneously with the GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN query. Change-Id: I818cf548c724ef56640b795530c3437e4dbcba98 Reviewed-on: https://swiftshader-review.googlesource.com/13828Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
- 14 Nov, 2017 8 commits
-
-
Alexis Hetu authored
- Can't update an already mapped bufferData - Can't unmap an unmapped buffer - Disallowed illegal mapBufferRange flag combinations - Can't flush buffer if not mapped Change-Id: I7013f63e5db64c1016f9ce50a43d0629f0a2950e Reviewed-on: https://swiftshader-review.googlesource.com/13788Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Alexis Hetu authored
The dEQP tests for arccos/arcsin/arctan were failing due to the precision of the arcsin/arccos/arctan approximation being too low. It is possible to significantly improve this precision with a few more terms, which is done here. All arccos/arcsin/arctan dEQP tests pass. Change-Id: I612551b48bdab03b81b2e72ddb8cd7f8502231c5 Reviewed-on: https://swiftshader-review.googlesource.com/13568Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Alexis Hetu authored
Since we don't expose the ASTC related extension string, we need to hide support for ASTC related enums. ASTC_SUPPORT was added to easily re-enable ASTC, should we want to. Change-Id: I3c65906c4729df8a2efb1a9a78e155bccdc715f9 Reviewed-on: https://swiftshader-review.googlesource.com/13749Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Alexis Hetu authored
It is an invalid operation to map an already mapped buffer. Change-Id: Iba1c2389e5ef9c3114a2415279406ac7f08a0ed6 Reviewed-on: https://swiftshader-review.googlesource.com/13750Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Alexis Hetu authored
This implementation allows all dEQP precision test to pass for sin, cos and tan function tests. Change-Id: I33a24497dea68ab2de2e65931f50f2dd4298523c Reviewed-on: https://swiftshader-review.googlesource.com/13555Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Alexis Hétu <sugoi@google.com>
-
Alexis Hetu authored
Added proper checks for invalid operations. Fixes all remaining failures in dEQP-GLES3.functional.lifetime* Change-Id: Ia91ffdb8ced53f1f787b82ada0de22caf9ee9206 Reviewed-on: https://swiftshader-review.googlesource.com/13748Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Alexis Hetu authored
Fixes all dEQP failures in inversesqrt and normalize. Change-Id: Ifd1ac2714fa95bab1c720b65c95a27bbf23ea933 Reviewed-on: https://swiftshader-review.googlesource.com/13728Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Alexis Hetu authored
- Fixed how logarithm2() handles infinity - Fixed a typo in exponential() These fixes combined fix all dEQP failures for: sinh, cosh, pow, exp, log, log2 Change-Id: I2d427892032fc5f75909a5609f606a787b08505a Reviewed-on: https://swiftshader-review.googlesource.com/13708Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
- 10 Nov, 2017 2 commits
-
-
Alexis Hetu authored
Added the missing implementation for isinf and isnan. Change-Id: Ice603956a4ed8ef9515ae8f501b2876ce5fab584 Reviewed-on: https://swiftshader-review.googlesource.com/13608Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Cezary Kulakowski authored
We use icecc to speed up compilation in our project. After this change https://swiftshader-review.googlesource.com/12308 chromium doesn't compile via icecc as __has_include(<atomic>) is never expanded to 0 or 1 on icecc host and file <atomic> is not being included. My guess is that icecc host gets partially expanded code and it's not being passed by preprocessor again so condition #if __has_include(<atomic>) (expanded from #if USE_STD_ATOMIC) is never fulfilled. Bug: chromium:783135 Change-Id: I09cf120c399a794a15dec05d6edd74c7848fc53a Reviewed-on: https://swiftshader-review.googlesource.com/13588Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Cezary Kulakowski <ckulakowski@opera.com>
-
- 07 Nov, 2017 12 commits
-
-
Nicolas Capens authored
Pass a surface to the blit/flip functions, instead of a raw pointer. This puts the FrameBuffer in control of locking and unlocking. Change-Id: I55335b3beef8d7083aae7687bd25392964261bde Reviewed-on: https://swiftshader-review.googlesource.com/4482Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
Previously we assumed the source stride (in pixels) to be the width rounded up to the next multiple of 2. This is currently correct but may not hold in the future. Change-Id: I23a79ace66f720398a120b70081d731c2cf1b4c0 Reviewed-on: https://swiftshader-review.googlesource.com/4481Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
This mainly groups the state that is used for generating a new blit routine into a second BlitState structure 'updateState'. It also allowed for the FrameBuffer's own parameters to not have a 'dest' prefix. Also, 'locked' was renamed to 'framebuffer', and 'target' to 'renderbuffer'. Change-Id: I64e26f0b06f9f4419b8ca67e6fbb0dee8272898a Reviewed-on: https://swiftshader-review.googlesource.com/11510Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
If both libGLES_CM and libGLESv2 are available, we were using the former for creating the buffers of an EGL surface. The choice is arbitrary, but it causes confusing issues when an interface changes and one of the libraries wasn't rebuilt. This is less likely to occur for libGLESv2. Change-Id: If0c05d50a141c3782866892694d238332d8211db Reviewed-on: https://swiftshader-review.googlesource.com/13388Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Nicolas Capens authored
The Reactor Value resulting from loading the value from the dereferenced Pointer does not get passed to the Int4 cast constructor correctly. This happens in 32-bit builds on Visual Studio 2017 (15.3.5), but not in 64-bit builds. Change-Id: I68e1639ada436c65bb4f3bf9b3ac88d503f10e30 Reviewed-on: https://swiftshader-review.googlesource.com/13554Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Nicolas Capens authored
Change-Id: I53b7938af132180dcf95312c76790fe761aab35d Reviewed-on: https://swiftshader-review.googlesource.com/13553Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Nicolas Capens authored
Cube texture sampling functions which take explicit gradients require the gradients to divided by the same factor used to project the texture coordinates onto the cube. Previously we assumed they were already in the projected coordinate space. Change-Id: I2825df17bee74b551b8d7491c050b7766653a65c Reviewed-on: https://swiftshader-review.googlesource.com/13552Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Nicolas Capens authored
This is necessary for cube or 2D array shadow texture sampling functions which need the fourth texture coordinate component for depth comparison while also taking a lod or bias parameter. Change-Id: I1e1399f134e22cecaff97a224df2c13c57ba3a40 Reviewed-on: https://swiftshader-review.googlesource.com/13551Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
Change-Id: Ib62f310abecbc4cdaf6e9300791600f25af0eaf3 Reviewed-on: https://swiftshader-review.googlesource.com/13550Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
Previously we dynamically allocated an array of SamplerCores. This isn't necessary and we can just create one as a temporary object where used. This has the added advantage that we could have Reactor variables as class members and keep them short-lived. Change-Id: Ifb2e6edbf275aa793bd7880bd35384e16000007d Reviewed-on: https://swiftshader-review.googlesource.com/13548Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Nicolas Capens authored
Depth format textures can have a comparison operation performed after their texels have been sampled. Change-Id: I49f6bb7fab9765265761144ee8b6b62439beb5a3 Reviewed-on: https://swiftshader-review.googlesource.com/5870Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Alexis Hetu authored
Fixed glBindVertexArray. The early return was wrong, binding vertex array 0 is perfectly valid. All related dEQP tests pass. Change-Id: Idd0ae745dc15877afb7c7323aab8253fb71e9017 Reviewed-on: https://swiftshader-review.googlesource.com/13549Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
- 03 Nov, 2017 1 commit
-
-
Alexis Hetu authored
Varying variables can be structure in OpenGL ES3. This cl adds support for structure varyings. Change-Id: I4d1d80c6afed0a86a23b0a467d4764a4e08f133d Reviewed-on: https://swiftshader-review.googlesource.com/13529Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
- 02 Nov, 2017 1 commit
-
-
Alexis Hetu authored
When multisampling is enabled, outline edges were getting initialized to one of the primitive's X position. If the primitive was out of bounds, then the default position was out of bounds, which led to an initial out of bounds memory access. Added a clamp to fix the issue. Bug chromium:779364 Change-Id: I4661f4229ee28a3032c763ed18dde799d3c3926b Reviewed-on: https://swiftshader-review.googlesource.com/13528Tested-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
- 01 Nov, 2017 1 commit
-
-
Corentin Wallez authored
This will help ASan find bugs in the translator when fuzzing, by making separate allocations instead of using suballocations within the pool. BUG=swiftshader:86 Change-Id: Ic59f7eef2c7985f7bf545d41be956df478331e2d Reviewed-on: https://swiftshader-review.googlesource.com/13488Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Corentin Wallez <cwallez@google.com>
-
- 31 Oct, 2017 3 commits
-
-
Nicolas Capens authored
Was an implicit narrowing from size_t (64-bit) to unsigned int (32-bit). Change-Id: I9726d70370d97da1bae2652bbce9db929179a292 Reviewed-on: https://swiftshader-review.googlesource.com/13469Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Nicolas Capens authored
Unused variable 'entry'. Change-Id: I115b7d599d871c0f130f72e32618a8ed29776b81 Reviewed-on: https://swiftshader-review.googlesource.com/13468Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
Bug swiftshader:86 Change-Id: If98cbf93e8b8d41246d9f06503da0752fe968ff8 Reviewed-on: https://swiftshader-review.googlesource.com/13448Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Corentin Wallez <cwallez@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-