Fix a few warnings
authorPyry Haulos <phaulos@google.com>
Tue, 19 Jul 2016 22:17:06 +0000 (15:17 -0700)
committerPyry Haulos <phaulos@google.com>
Tue, 19 Jul 2016 22:17:06 +0000 (15:17 -0700)
external/vulkancts/modules/vulkan/clipping/vktClippingTests.cpp
external/vulkancts/modules/vulkan/pipeline/vktPipelineCacheTests.cpp
external/vulkancts/modules/vulkan/synchronization/vktSynchronizationOperation.cpp

index 2056adb..1be330f 100644 (file)
@@ -178,7 +178,7 @@ DrawContext::DrawContext (Context&                                          context,
 
                {
                        const Allocation& alloc = m_colorAttachmentBuffer->getAllocation();
-                       deMemset(alloc.getHostPtr(), 0, bitmapSize);
+                       deMemset(alloc.getHostPtr(), 0, (size_t)bitmapSize);
                        flushMappedMemoryRange(vk, device, alloc.getMemory(), alloc.getOffset(), bitmapSize);
                }
        }
@@ -190,7 +190,7 @@ DrawContext::DrawContext (Context&                                          context,
                        vk, device, allocator, makeBufferCreateInfo(bufferSize, VK_BUFFER_USAGE_VERTEX_BUFFER_BIT), MemoryRequirement::HostVisible));
 
                const Allocation& alloc = m_vertexBuffer->getAllocation();
-               deMemcpy(alloc.getHostPtr(), &vertices[0], bufferSize);
+               deMemcpy(alloc.getHostPtr(), &vertices[0], (size_t)bufferSize);
                flushMappedMemoryRange(vk, device, alloc.getMemory(), alloc.getOffset(), bufferSize);
        }
 
index 5a1690f..7b9eca0 100644 (file)
@@ -1738,16 +1738,6 @@ CacheHeaderTestInstance::CacheHeaderTestInstance (Context& context, const CacheT
 
        // Create more pipeline caches
        {
-               // Create a empty cache as one of source cache
-               VkPipelineCacheCreateInfo pipelineCacheCreateInfo =
-               {
-                       VK_STRUCTURE_TYPE_PIPELINE_CACHE_CREATE_INFO,           // VkStructureType             sType;
-                       DE_NULL,                                                // const void*                 pNext;
-                       0u,                                                     // VkPipelineCacheCreateFlags  flags;
-                       0u,                                                     // deUintptr                   initialDataSize;
-                       DE_NULL,                                                // const void*                 pInitialData;
-               };
-
                // Create a cache with init data from m_cache
                size_t  dataSize = 0u;
                VK_CHECK(vk.getPipelineCacheData(vkDevice, *m_cache, (deUintptr*)&dataSize, DE_NULL));
@@ -1843,7 +1833,7 @@ InvalidSizeTestInstance::InvalidSizeTestInstance (Context& context, const CacheT
                m_data = new deUint8[savedDataSize];
                deMemset(m_data, 0, savedDataSize);
                DE_ASSERT(m_data);
-               if (vk.getPipelineCacheData(vkDevice, *m_cache, (deUintptr*)&dataSize, (void*)m_data) != VK_INCOMPLETE)\r
+               if (vk.getPipelineCacheData(vkDevice, *m_cache, (deUintptr*)&dataSize, (void*)m_data) != VK_INCOMPLETE)
                        TCU_THROW(TestError, "GetPipelineCacheData should return VK_INCOMPLETE state!");
 
                m_zeroBlock = new deUint8[savedDataSize];
index de4999a..1396886 100644 (file)
@@ -2876,7 +2876,7 @@ public:
                // Init host buffer data
                {
                        const Allocation& alloc = m_hostBuffer->getAllocation();
-                       deMemset(alloc.getHostPtr(), 0, m_hostBufferSizeBytes);
+                       deMemset(alloc.getHostPtr(), 0, static_cast<size_t>(m_hostBufferSizeBytes));
                        flushMappedMemoryRange(vk, device, alloc.getMemory(), alloc.getOffset(), static_cast<size_t>(m_hostBufferSizeBytes));
                }