Commit Graph

13079 Commits

Author SHA1 Message Date
baldurk cef00a102b Add struct VarType and combine flags into single field
* This is not a space saving right now, but allows more flags to be added
  without adding more storage.
2022-05-20 13:37:25 +01:00
Jake Turner 5a722b0efa Apple: cache debugger detection
Also added check if sysctl succeeded
2022-05-20 13:36:23 +01:00
Jake Turner 1d9be38380 Apple: support for Output_DebugMon log channel 2022-05-20 13:36:23 +01:00
Jake Turner 39cdfeb138 Set s_hookObjcMethods true in MTLHookObjcMethods
PR Feedback
2022-05-18 10:17:16 +01:00
Jake Turner 814ad814cd Adopt g_* naming convention for class static's
WrappedMTLDevice
real_CAMetalLayer_nextDrawable -> g_real_CAMetalLayer_nextDrawable
nextDrawableTLSSlot -> g_nextDrawableTLSSlot
2022-05-18 10:17:16 +01:00
Jake Turner 8d7d060e63 Set nextDrawable TLS data before creating hook 2022-05-18 10:17:16 +01:00
Jake Turner 259205fdc9 Remove extra rdDescriptor variable
PR Feedback.
2022-05-18 10:17:16 +01:00
Jake Turner 00fdb79d68 Hook CAMetalLayer nextDrawable message
PR Feedback.
Replace the brittle callstack string comparison
2022-05-18 10:17:16 +01:00
Jake Turner cef722a3d8 Simplify GetObjcArray implementation
PR Feedback.
Remove optimisation of the array of pointers on the stack
resize the to array when adding a valid object
2022-05-18 10:17:16 +01:00
Jake Turner ddf56d7b0d Move DoSerialise* methods to metal_serialise.cpp
PR Feedback.
Moved from metal_types.cpp -> metal_stringise.cpp
2022-05-18 10:17:16 +01:00
Jake Turner 7f19df6a2b Refactored WrappedMTLDevice texture helper methods
PR Feedback.
Replaced NewTexture & NewIOSurfaceTextureWithDescriptor with a single combined method Common_NewTexture
2022-05-18 10:17:16 +01:00
Jake Turner 8a85d15386 Added wrapped MTLRenderPipelineState & MTLTexture
Implemented capture serialisation for APIs:
MTLDevice::newRenderPipelineStateWithDescriptor
MTLDevice::newTextureWithDescriptor

Workaround to prevent Metal capture library assert triggering on the bridge MTLTexture object, add protocol "MTLTextureImplementation" to class "ObjCBridgeMTLTexture"

Serialisation for helper types:
MTL::TextureDescriptor
MTL::RenderPipelineDescriptor
MTL::RenderPipelineColorAttachmentDescriptor
MTL::PixelFormat
MTL::TextureType
MTL::PrimitiveTopologyClass
MTL::ResourceOptions
MTL::CPUCacheMode
MTL::StorageMode
MTL::HazardTrackingMode
MTL::TextureUsage
MTL::TextureSwizzleChannels
MTL::TextureSwizzle
MTL::ColorWriteMask
MTL::BlendOperation
MTL::BlendFactor
MTL::Winding
MTL::TessellationFactorFormat
MTL::TessellationControlPointIndexType
MTL::TessellationFactorStepFunction
MTL::TessellationPartitionMode
2022-05-18 10:17:16 +01:00
Jake Turner 1fdf8fc776 Fix MTL::LinkedFunctions bug in metal-cpp.h
MTLLinkedFunctions groups is an NS::Dictionary* not an NS::Array*
ie.
@property(readwrite, nonatomic, copy, nullable) NSDictionary<NSString *,NSArray<id<MTLFunction>> *> *groups;
2022-05-18 10:17:16 +01:00
baldurk 6dfca8bc87 Ensure vkCmdSetEvent2 struct chain is properly unwrapped. Closes #2582 2022-05-11 11:31:11 +01:00
baldurk ee3e77a5a7 Only update backing store if it has been allocated. Closes #2583 2022-05-11 00:52:42 +01:00
Jake Turner f3fe008d73 Store ObjC bridge class in Wrapped C++ classes
Stored as first member data in Wrapped C++ classes (m_ObjcBridge)
Can cast WrappedMTL* C++ pointer to ObjCBridgeMTL* type to use as the ObjC bridge class
Can cast ObjCBridgeMTL* pointer to WrappedMTL* C++ type to use as the Wrapped C++ class

Removed use of term ObjCBridge except on the ObjC bridge declarations

WrappedMTLObject member initialization
Prefer member initialization instead of constructor initialization list
2022-05-10 11:36:02 +01:00
baldurk 797fbcc181 Fix friendly name of registers in cbuffer declarations in dxbc 2022-05-09 11:32:25 +01:00
baldurk 2fc0866c9f Fix display of register names for matrix source variables 2022-05-09 11:32:11 +01:00
baldurk 8d34ea577d Add some missing tooltips for event browser location buttons 2022-05-06 13:17:09 +01:00
baldurk e5000ff91b Handle source variables that map to non-existant debug variables 2022-05-04 15:47:04 +01:00
baldurk 09519c802f Add usage from trailing events in command buffers 2022-05-04 15:47:04 +01:00
kkhalid 7d68116f5d Update dxbc_debug.cpp
fix clang-CL errors : call to constructor of 'ShaderVariable' is ambiguous
2022-05-04 10:01:13 +01:00
kkhalid 229d80b439 Update win32_threading.cpp
fixing compilation errors with clang-cl:  "template specialization requires 'template<>"
2022-05-04 10:01:13 +01:00
baldurk 4953adde03 Add a test of KHR_Dynamic_Rendering
* Not all possible interactions are currently tested, but at least the ones that
  have been broken in the past.
2022-05-03 18:47:27 +01:00
baldurk cfdbc3da57 Remove outdated experimental feature check 2022-05-03 15:30:47 +01:00
baldurk a9562c87f5 Test that discard patterns don't disturb bound state on vulkan 2022-05-03 15:30:20 +01:00
baldurk 96a7639c2e Add test of flow control constructs in D3D11 shader debugging 2022-05-03 14:06:07 +01:00
Remi Palandri acde46de57 move ms/compute shader system to single descriptorset 2022-05-03 12:33:46 +01:00
kmchan 85789e6209 Update HWCPipe to support performance counters of Dimensity 9000 SoC
Base HWCPipe commit: https://github.com/ARM-software/HWCPipe/commit/8cc02065b4ef249127aa0164dc0d62d65c0d4203
2022-05-03 12:26:32 +01:00
Yuxin Hu f54d28c2cd Support VK_GOOGLE_surfaceless_query
This change adds the VK_GOOGLE_surfaceless_query extension
to RenderDoc's allowlist.
2022-05-03 12:03:42 +01:00
baldurk d9c98f44f6 Fix stepping backwards working incorrectly with multiple location maps 2022-04-28 16:34:44 +01:00
baldurk 04c62f9595 Add a test debugging shaders on D3D12 with banned flags in the root sig 2022-04-28 14:19:38 +01:00
baldurk c1240effe3 Test alternative functions for binding contexts on GL 2022-04-28 14:05:38 +01:00
baldurk 7066692262 Test that sampler heaps are represented in structured data properly
* This is a test of a specific case of lazy serialisation, but in particular
  D3D12 descriptors do some aliasing tricks for types to compress the data, so
  repeated serialisation needs to be safe.
2022-04-28 13:39:37 +01:00
baldurk 4103f6a545 Properly zero initialise DDS return structure 2022-04-28 11:39:11 +01:00
baldurk 51a9d26f83 Handle DebugSourceContinued properly in SPIR-V 2022-04-27 16:02:38 +01:00
baldurk 9f9419c21f Preprocess #line directives in SPIR-V debug info to get referenced files
* This matches the line number and source file references generated in the debug
  info
2022-04-27 13:46:02 +01:00
baldurk 4667609163 Fix docstrings in ResultDetails and ExecuteResult 2022-04-26 18:09:15 +01:00
baldurk 16f3764cda Work around gcc compiler bug
* It complains that there is switch fallthrough after an unconditional return,
  when it's inside a do{}while(0). Simplifying the while condition seems to
  address it.
2022-04-26 17:37:31 +01:00
baldurk 8aa0390948 Add string messages to returned result codes to display to user
* Most of the main entry points that can fail with relevant reasons now has a
  way of specifying a message to return with it. This message can be displayed
  to the user to give more information or context about an error.
2022-04-26 16:21:54 +01:00
baldurk 10dd4c194c Update some tips that are out of date 2022-04-26 16:21:35 +01:00
baldurk 7aa7f1da99 Generate .sig files after signing installers 2022-04-26 13:20:09 +01:00
Tatsuyuki Ishi 2285bcc270 spirv_reflect: Remove unnecessary spec sort
By construction the variables are pushed in order from smaller offset to
larger offsets. The sort only confuses the reader, so remove it.
2022-04-25 14:17:12 +01:00
Tatsuyuki Ishi 3d4cd457bd foz: Encode sampleMask as array 2022-04-25 14:17:12 +01:00
Tatsuyuki Ishi b0ff54fbcf foz: Reconstruct specialization constants with correct layout 2022-04-25 14:17:12 +01:00
Tatsuyuki Ishi a2d77f58db foz: Rename dynamic rendering colorAttachmentFormats 2022-04-25 14:17:12 +01:00
Jake Turner aef7fc698b Add header files to demos CMakeLists.txt
Helpful for source browsing when using an IDE project generated by CMake

Potential list of header files found using:

find util/test/demos -name '*.h' \! -path "*3rdparty*" \! -path "*official*"
2022-04-25 12:08:51 +01:00
Aurelien Chanot b173e85a1f Fix crash when application is using unsupported function.
It fixes this crash:
https://gist.github.com/achanot/7e0d25d1e5a619a61b688ec895c7a349
2022-04-22 18:27:06 +01:00
Bertrand Guay-Paquet cb0dc39bf3 Add link to the contrib repository for custom visualisation 2022-04-22 13:49:56 +01:00
baldurk 1ae2afc05a Apply shader prefix even if encoding is directly accepted. Closes #2561
* The prefix, if available, must always be applied for custom shaders to compile
  correctly.
2022-04-22 12:55:40 +01:00