platform/upstream/Vulkan-Tools.git
9 years agoxgl-generate.py: add and use helpers from loader.h
Chia-I Wu [Sat, 11 Apr 2015 07:34:07 +0000 (15:34 +0800)]
xgl-generate.py: add and use helpers from loader.h

Add helpers to loader.h to improve readability of LoaderEntrypointsSubcommand.

9 years agoxgl-generate.py: add WinDefFileSubcommand
Chia-I Wu [Sat, 11 Apr 2015 02:56:50 +0000 (10:56 +0800)]
xgl-generate.py: add WinDefFileSubcommand

It replaces xgl-win-def-file-generate.py and is able to generate loader's
XGL.def.

9 years agodemo: remove XCB_NVIDIA paths
Chia-I Wu [Sat, 11 Apr 2015 04:55:53 +0000 (12:55 +0800)]
demo: remove XCB_NVIDIA paths

The memory returned by xglWsiX11CreatePresentableImage() is not supposed to be
freed.  This change at worse leaks the memories on app exiting for some
implementations.  That should be fine.

Also, the function returns at most one memory.  Remove multiple memory support
from tri.

9 years agodemos: set EXTERNAL_SPV from CMakeLists.txt
Chia-I Wu [Sat, 11 Apr 2015 05:06:46 +0000 (13:06 +0800)]
demos: set EXTERNAL_SPV from CMakeLists.txt

Do not abuse XCB_NVIDIA.

9 years agodemos: remove non-__linux__ paths
Chia-I Wu [Sat, 11 Apr 2015 04:45:21 +0000 (12:45 +0800)]
demos: remove non-__linux__ paths

I do not think they work in that the framebuffer is created with

  .colorAttachmentCount = 1,
  .pColorAttachments = NULL,

If we want to support offscreen rendering, add a command line option for that.
If we want to support other window systems, refactor the code first.

9 years agoMerge branch 'master' of https://github.com/KhronosGroup/GL-Next
Peter Lohrmann [Tue, 7 Apr 2015 00:25:03 +0000 (17:25 -0700)]
Merge branch 'master' of https://github.com/KhronosGroup/GL-Next

9 years agoMerge branch 'glave_snapshot_support'
Peter Lohrmann [Mon, 6 Apr 2015 21:14:44 +0000 (14:14 -0700)]
Merge branch 'glave_snapshot_support'

Conflicts:
layers/CMakeLists.txt
tools/glave/scripts/vk_generate.py
tools/glave/src/glv_extensions/glvreplay_xgl/CMakeLists.txt
tools/glave/src/glv_extensions/glvtrace_xgl/CMakeLists.txt
tools/glave/src/glv_extensions/glvtrace_xgl/codegen/glvtrace_xgl_xgl.c
tools/glave/src/glv_extensions/glvtrace_xgl/codegen/glvtrace_xgl_xgl.h
tools/glave/src/glv_extensions/glvtrace_xgl/codegen/xgl_struct_size_helper.h
tools/glave/src/glv_extensions/glvtrace_xgl/codegen/xgl_struct_string_helper.h
tools/glave/src/glv_extensions/glvtrace_xgl/codegen/xgl_struct_string_helper_cpp.h
tools/glave/src/glv_extensions/glvtrace_xgl/codegen/xgl_struct_string_helper_no_addr.h
tools/glave/src/glv_extensions/glvtrace_xgl/codegen/xgl_struct_string_helper_no_addr_cpp.h
tools/glave/src/glv_extensions/glvtrace_xgl/codegen/xgl_struct_validate_helper.h
tools/glave/src/glv_extensions/glvtrace_xgl/codegen/xgl_struct_wrappers.cpp
tools/glave/src/glv_extensions/glvtrace_xgl/codegen/xgl_struct_wrappers.h
xgl_helper.py

9 years agolayers: Update layer README.md info with current DrawState and MemTracker status
Tobin Ehlis [Mon, 6 Apr 2015 15:24:42 +0000 (09:24 -0600)]
layers: Update layer README.md info with current DrawState and MemTracker status

9 years agodemos: Fix shader assert in tri.c
Mark Lobodzinski [Mon, 6 Apr 2015 20:24:40 +0000 (15:24 -0500)]
demos: Fix shader assert in tri.c

Updating tri demo's shader versions to 140 keeps them from asserting

9 years agolayers: Updated for explicit fence validation with multiple queues
Mark Lobodzinski [Fri, 3 Apr 2015 01:49:09 +0000 (20:49 -0500)]
layers: Updated for explicit fence validation with multiple queues

Fences were being validated to make sure they had been retired, layer
was updated to validate that the app has checked the fences.

9 years agolayers: Added support for multiple queues
Mark Lobodzinski [Thu, 2 Apr 2015 13:52:53 +0000 (08:52 -0500)]
layers: Added support for multiple queues

Not supported on Intel, but will be on other hw.

9 years agolayers: Added GetDeviceQueue API, fixed up variable names
Mark Lobodzinski [Tue, 31 Mar 2015 21:05:35 +0000 (16:05 -0500)]
layers: Added GetDeviceQueue API, fixed up variable names

Updated LinkedList-related variable names

9 years agoMerge remote-tracking branch 'origin/master'
Piers Daniell [Fri, 3 Apr 2015 23:46:24 +0000 (17:46 -0600)]
Merge remote-tracking branch 'origin/master'

Conflicts:
loader/loader.c

9 years agoloader: Work correctly when there is no reg entry
Piers Daniell [Fri, 3 Apr 2015 23:44:52 +0000 (17:44 -0600)]
loader: Work correctly when there is no reg entry

Without this fix the loader will crash if there is no registry entry.

9 years agodemo: tri: Use explicit locations on the attribs
Piers Daniell [Fri, 3 Apr 2015 23:44:02 +0000 (17:44 -0600)]
demo: tri: Use explicit locations on the attribs

Without this the attributes may assume the wrong vertex attrib slot.

9 years agodemos: copy XGL.dll to target folder
Piers Daniell [Fri, 3 Apr 2015 23:42:59 +0000 (17:42 -0600)]
demos: copy XGL.dll to target folder

Makes life easier so the XGL.dll doesn't have to be manually copied
every time.

9 years agoHave demos give a useful error if no compatible ICD found.
Ian Elliott [Fri, 3 Apr 2015 21:24:55 +0000 (15:24 -0600)]
Have demos give a useful error if no compatible ICD found.

9 years agoFix NULL-pointer dereference if can't find registry entry.
Ian Elliott [Fri, 3 Apr 2015 19:13:01 +0000 (13:13 -0600)]
Fix NULL-pointer dereference if can't find registry entry.

9 years agolayers: update codegen to split struct_size_helper into .h and .c files.
Peter Lohrmann [Fri, 3 Apr 2015 18:43:06 +0000 (11:43 -0700)]
layers: update codegen to split struct_size_helper into .h and .c files.

* Also added a copyright notice to all the generated files.
* Splitting the definition from the declaration was needed to better utilize these helpers in glave.

9 years agoglaveSnapshot: snapshot now does deep copy of DEVICE_CREATE_INFO struct.
Peter Lohrmann [Wed, 1 Apr 2015 20:54:18 +0000 (13:54 -0700)]
glaveSnapshot: snapshot now does deep copy of DEVICE_CREATE_INFO struct.

* Add new local methods to do a deep copy of the DEVICE_CREATE_INFO struct. A similar method is added to do a deep free of the struct. This is just to experiment with what will be needed to support all the Create* entrypoints; most of this should be code-gen'ed later on.
* The CreateInfo struct is now also printed as part of glvSnapshotPrintDelta to confirm that it is working via the UI. Note the helper function I'm using to print the struct will only print the first layer in the list. It doesn't support printing > 1 layer.

9 years agoxgl_helper: sort dictionaries to make generated output consistent
Peter Lohrmann [Mon, 30 Mar 2015 23:29:56 +0000 (16:29 -0700)]
xgl_helper: sort dictionaries to make generated output consistent

9 years agolayers: Shadow PSO Creation structs directly in PIPELINE_NODE
Tobin Ehlis [Wed, 1 Apr 2015 17:59:08 +0000 (11:59 -0600)]
layers: Shadow PSO Creation structs directly in PIPELINE_NODE

This simplifies creation and desctruction as well as validation of PSO.

9 years agolayers: Add DrawState validation that FB samples matches PSO samples
Tobin Ehlis [Wed, 1 Apr 2015 14:40:34 +0000 (08:40 -0600)]
layers: Add DrawState validation that FB samples matches PSO samples

9 years agoNew loader_get_registry_value() function reads 32/64 registry ...
Ian Elliott [Tue, 31 Mar 2015 21:32:41 +0000 (15:32 -0600)]
New loader_get_registry_value() function reads 32/64 registry ...

This version should be able to find a key/value if it exists in either the 32
or 64 bit hive.  Also, it also doesn't allocate any string data until it knows
what size is needed.

Changed the "xcv_nvidia.cpp" file to also use the new registry approach.

9 years agoxgl_helper: sort dictionaries to make generated output consistent
Peter Lohrmann [Mon, 30 Mar 2015 23:29:56 +0000 (16:29 -0700)]
xgl_helper: sort dictionaries to make generated output consistent

9 years agoglave: move code-gen'ed files.
Peter Lohrmann [Thu, 26 Mar 2015 04:35:32 +0000 (21:35 -0700)]
glave: move code-gen'ed files.

* glave-generate.py has moved into tools/glave/scripts/ and renamed to vk_generate.py
* still reference xgl.py and xgl_helper.py from GL-Next directory.
* all glave-specific code-gen'ed files now live in the source tree
* all glave-specific code-gen'ed files are now generated into a "codegen" directory local to the project to make it easier to spot when a generated file has changed or is being debugged.
* all glave-specific code-gen'ed files are now being checked in so that we can better track differences caused by the code-gen as the header file evolves.

(based on squash of the follow two cherry-picks, plus some additional changes to remove files generated by xgl_helper.py since they change every build)
(cherry picked from commit eec461f4bc68c5ac12a6b73b9f6e5464be0640bf)
(cherry picked from commit 2614252bfc3fe9c2cd8470b3b42b529a69f2e3f3)

9 years agoglaveSnapshot: Reorganize creation/insertion and deletion of objects
Peter Lohrmann [Mon, 30 Mar 2015 19:58:50 +0000 (12:58 -0700)]
glaveSnapshot: Reorganize creation/insertion and deletion of objects

* Return value of api's Create* calls is now ensured to be XGL_SUCCESS before attempting to track the object.
* Created objects are now inserted into a snapshot's global and object lists, then the node is returned so that the caller can populate additional information in the pStruct member if needed.
* The list of devices now uses the GLV_VK_SNAPSHOT_LL_NODE because device object nodes will be linked into the global list and object lists to help avoid duplication of data.
* When a created object needs to get deleted, snapshot_remove_object(..) will search for the object in the global list and remove the node from both lists before returning a pointer to the node (or NULL if the object was not in the global list, meaning we didn't see the creation). The caller should delete the pStruct member as appropriate and then delete the node itself. If the creation of the object was not captured, the caller should add the object to the deleted object list.
* Deleted objects (whose creation was not recorded) now get tracked using a different linked-list struct than other objects. There is a lot less known information related to a deleted object, so there's no need to use the larger struct.

9 years agoGlaveSnapshot: Remove ifdef'd code for OBJ_NODES.
Peter Lohrmann [Sat, 28 Mar 2015 00:31:17 +0000 (17:31 -0700)]
GlaveSnapshot: Remove ifdef'd code for OBJ_NODES.

* The new tracking of objects in the snapshot struct is working, and will soon diverge from the OBJ_NODES functionality.

9 years agoGlaveSnapshot Layer: Objects are now tracked within a GLV_VK_SNAPSHOT structure.
Peter Lohrmann [Fri, 27 Mar 2015 03:38:12 +0000 (20:38 -0700)]
GlaveSnapshot Layer: Objects are now tracked within a GLV_VK_SNAPSHOT structure.

* Moved the previously static linked lists into a snapshot structure. Old functionality is available temporarily via a defined macro
* Added a description of how the master and delta snapshots are planned to function.
* Added new entrypoints for planned snapshot functionality.
* Started expanding tracking of XGL_DEVICE objects to get a better understanding of what will need to be done for each of the different object types. Some code-gen (or possibly existing scripts) will likely help here.

9 years agoglave: Add ability for replay memory allocations and mapping to be pending
Jon Ashburn [Fri, 27 Mar 2015 22:23:47 +0000 (16:23 -0600)]
glave: Add ability for replay memory allocations and mapping to be pending

9 years agoglave: Consolidate the maped data and gpu memory maps used during replay
Jon Ashburn [Thu, 26 Mar 2015 22:15:18 +0000 (16:15 -0600)]
glave: Consolidate the maped data and gpu memory maps used during replay

Now the information is all within a single STL map.

9 years agoglave: Make the XGL_GPU_MEMORY object mapping use a structure. Needed so can merge...
Jon Ashburn [Tue, 24 Mar 2015 17:05:02 +0000 (11:05 -0600)]
glave: Make the XGL_GPU_MEMORY object mapping use a structure. Needed so can merge the Memory object data and info into the same mapping.

9 years agoglave: Track Buffer and Image memory requirements during replay.
Jon Ashburn [Mon, 23 Mar 2015 15:27:33 +0000 (09:27 -0600)]
glave: Track Buffer and Image memory requirements during replay.

This is start of replayer having it's own memory manager.  Needed since
trace GPU may not have same memory requirements for objects as replay GPU

9 years agolayers: Correct xglBindObjectMemory signature in MemTracker message.
Tobin Ehlis [Thu, 26 Mar 2015 14:24:16 +0000 (08:24 -0600)]
layers: Correct xglBindObjectMemory signature in MemTracker message.

9 years agoglave: move code-gen'ed files.
Peter Lohrmann [Thu, 26 Mar 2015 04:35:32 +0000 (21:35 -0700)]
glave: move code-gen'ed files.

* glave-generate.py has moved into tools/glave/scripts/ and renamed to vk-generate.py
* all code-gen'ed files now live in the source tree
* all code-gen'ed files are now generated into a "codegen" directory local to the project to make it easier to spot when a generated file has changed or is being debugged.
* all code-gen'ed files are now being checked in so that we can better track differences caused by the code-gen as the header file evolves.

9 years agoGlaveSnapshot layer: remove code specific to validation
Peter Lohrmann [Thu, 26 Mar 2015 03:37:02 +0000 (20:37 -0700)]
GlaveSnapshot layer: remove code specific to validation

9 years agolayers: Migrated DrawState layer to cpp
Tobin Ehlis [Tue, 17 Mar 2015 22:24:32 +0000 (16:24 -0600)]
layers: Migrated DrawState layer to cpp

Move almost all linked-lists to unordered_maps and vectors.
Clean up malloc/free with new/delete.
Skip write-strings compile warnings for graphviz_helper.

Still need to migrate the DS update tree to c++.

9 years agolayers: Rename synchDS function to validateVBBinding
Tobin Ehlis [Mon, 16 Mar 2015 17:49:58 +0000 (11:49 -0600)]
layers: Rename synchDS function to validateVBBinding

9 years agolayers: Convert memtracker to cpp
Mark Lobodzinski [Tue, 24 Mar 2015 21:29:24 +0000 (16:29 -0500)]
layers: Convert memtracker to cpp

Take advantage of containers, memory allocation, and strings.

9 years agoGlaveSnapshot layer: Snapshot information is now passed to the message callback.
Peter Lohrmann [Wed, 25 Mar 2015 17:35:03 +0000 (10:35 -0700)]
GlaveSnapshot layer: Snapshot information is now passed to the message callback.

* This way it can be passed to the UI.
* Comment out other XGL_DBG_MSG_UNKNOWN messages so there isn't as much info spew.

9 years agoglvreplay_xgl: use the GlaveSnapshot layer to print tracked objects.
Peter Lohrmann [Wed, 25 Mar 2015 00:19:24 +0000 (17:19 -0700)]
glvreplay_xgl: use the GlaveSnapshot layer to print tracked objects.

* Currently this is called as part of dump_validation_data(), which is called when the replayer is paused.

9 years agoGlaveSnapshot layer: Rename enums and entrypoints to make them layer specific; add...
Peter Lohrmann [Wed, 25 Mar 2015 00:15:03 +0000 (17:15 -0700)]
GlaveSnapshot layer: Rename enums and entrypoints to make them layer specific; add an entrypoint to print the object lists.

* glvSnapshotPrintObjects() is now exported and causes the tracked objects to get printed out (currently to the console).
** This will be used to help debug the contents of the snapshot as this layer is being developed.

9 years agoGlaveSnapshot Layer: XGL_OBJECT_TYPE_PRESENTABLE_IMABE_MEMORY enum can now be convert...
Peter Lohrmann [Tue, 24 Mar 2015 23:31:39 +0000 (16:31 -0700)]
GlaveSnapshot Layer: XGL_OBJECT_TYPE_PRESENTABLE_IMABE_MEMORY enum can now be converted to a string.

9 years agoGlaveSnapshot Layer: Use correct header file.
Peter Lohrmann [Tue, 24 Mar 2015 23:30:17 +0000 (16:30 -0700)]
GlaveSnapshot Layer: Use correct header file.

9 years agoGlaveSnapshot Layer: Initial code which is basically a copy of the ObjectTracker...
Peter Lohrmann [Tue, 24 Mar 2015 23:14:01 +0000 (16:14 -0700)]
GlaveSnapshot Layer: Initial code which is basically a copy of the ObjectTracker layer.

* Using the ObjectTracker since it already keeps track of the objects being created and destroyed. This is a huge benefit to have as a starting point for the snapshots!
* I've made a few minor changes to ensure the layer gets enabled and the output messages are using a different tag so they can be distinguished from the ObjectTracker.
* Added the new layer to CMakeLists.

9 years agodemos: Use lower left coord origin for cube
Mike Stroyan [Tue, 24 Mar 2015 21:13:34 +0000 (15:13 -0600)]
demos: Use lower left coord origin for cube

The intel driver currently does only XGL_COORDINATE_ORIGIN_LOWER_LEFT.
Use it for now.

9 years agodemos: Make cube use back face culling.
Mike Stroyan [Thu, 19 Mar 2015 20:29:04 +0000 (14:29 -0600)]
demos: Make cube use back face culling.

Use back face culling to confirm that the sense is correct.

9 years agoNote how to pin xserver-xorg-video-intel
Mike Stroyan [Mon, 23 Mar 2015 23:36:54 +0000 (17:36 -0600)]
Note how to pin xserver-xorg-video-intel

Prevent updates from overwriting xserver-xorg-video-intel and breaking DRI3.

9 years agoBUILD.md: Update Windows instructions for correct registry and python3.3
Jon Ashburn [Wed, 18 Mar 2015 18:01:19 +0000 (12:01 -0600)]
BUILD.md:  Update Windows instructions for correct registry and python3.3

9 years agowin: Make build able to find python3 on Windows and Linux
Jon Ashburn [Wed, 18 Mar 2015 15:29:11 +0000 (09:29 -0600)]
win: Make build able to find python3 on Windows and Linux

Use the py launcher on Windows which understands she bangs

9 years agoSPIR-V: Change BIL to SPV in all source files
Cody Northrop [Tue, 17 Mar 2015 21:55:58 +0000 (15:55 -0600)]
SPIR-V: Change BIL to SPV in all source files

9 years agoicd: Rename icd-bil.h to icd-spv.h
Cody Northrop [Tue, 17 Mar 2015 20:54:35 +0000 (14:54 -0600)]
icd: Rename icd-bil.h to icd-spv.h

9 years agofix cube demo for .spv filenames
Steve K [Tue, 17 Mar 2015 16:18:08 +0000 (10:18 -0600)]
fix cube demo for .spv filenames

9 years agoRevert "misc: Explicitly run python for generated code"
Jon Ashburn [Tue, 17 Mar 2015 23:54:58 +0000 (17:54 -0600)]
Revert "misc: Explicitly run python for generated code"

This reverts commit 10e987d610d43b37556df9b12349f9ffc8cb30c4.

9 years agomisc: Explicitly run python for generated code
Jon Ashburn [Tue, 17 Mar 2015 23:34:20 +0000 (16:34 -0700)]
misc: Explicitly run python for generated code
On windows if multiple python versions installed, then command line args
for python scripts fail.  This works around python issue

9 years agolayers: Added fence tracking for command buffer completion
Mark Lobodzinski [Tue, 17 Mar 2015 15:53:12 +0000 (10:53 -0500)]
layers: Added fence tracking for command buffer completion

Cleaned up MemTracker fence tracking for command buffer completions,
fixed several issues with local fences.

9 years agolayers: Reduce unmeaningful error messages for memtracker
Mark Lobodzinski [Thu, 5 Mar 2015 16:07:53 +0000 (10:07 -0600)]
layers: Reduce unmeaningful error messages for memtracker

It is a common case for a command buffer not to have a fence associated
with it -- no reason to call these cases out as errors.

9 years agolayers: MemTracker add check to verify CB complete prior to Reset
Tobin Ehlis [Wed, 4 Mar 2015 15:38:22 +0000 (08:38 -0700)]
layers: MemTracker add check to verify CB complete prior to Reset

If CB fence has not completed on call to Begin or Reset CB, flag validation error.

Various improvements to make sure the CB fence is getting reset as appropriate if the fence completes or is destroyed.

9 years agolayers: Update DrawState to use generated struct size functions
Tobin Ehlis [Mon, 16 Mar 2015 16:44:40 +0000 (10:44 -0600)]
layers: Update DrawState to use generated struct size functions

Update struct size codegen to handle callback void* case and ppMemBarriers void** cases conservatively for now.

9 years agoglave: Use generated code to get pAppInfo struct size
Tobin Ehlis [Mon, 16 Mar 2015 14:21:33 +0000 (08:21 -0600)]
glave: Use generated code to get pAppInfo struct size

9 years agoglave: Update more trace custom code to use generated struct sizing code instead
Tobin Ehlis [Fri, 13 Mar 2015 13:18:05 +0000 (07:18 -0600)]
glave: Update more trace custom code to use generated struct sizing code instead

9 years agoglave: Add codgen helper for struct size calculation and use for trace packet creation
Tobin Ehlis [Thu, 12 Mar 2015 20:50:40 +0000 (14:50 -0600)]
glave: Add codgen helper for struct size calculation and use for trace packet creation

9 years agoglave: Codegen cleanup for tracing code to add/finalize ptrs in packet
Tobin Ehlis [Wed, 11 Mar 2015 23:19:54 +0000 (17:19 -0600)]
glave: Codegen cleanup for tracing code to add/finalize ptrs in packet

9 years agoglave: Simplify codegen for trace packet sizing
Tobin Ehlis [Tue, 10 Mar 2015 17:04:17 +0000 (11:04 -0600)]
glave: Simplify codegen for trace packet sizing

9 years agoglave-generate: Replace asserts with proper error detection and error logging.
Peter Lohrmann [Tue, 10 Mar 2015 22:30:36 +0000 (15:30 -0700)]
glave-generate: Replace asserts with proper error detection and error logging.

* On Linux debug builds, the asserts cause the debugger to abort, but the code wasn't handling the error case safely anyway, so even a release build would likely crash.
* These situations were being hit if trying to load a trace file from an earlier header version, but are likely to be conditions we'll see when new developers start to use the API.
* With these changes, the error is properly reported and error return values propogated so that the UI detects the invalid file and reports an error to the user.
* The new glv_LogError(..) messages get printed to the console, but are not yet passed to the UI. This will be done as part of a larger change sometime in the future.

9 years agoglave: Fix createRenderpass replay restore of remapped FB
Jon Ashburn [Mon, 9 Mar 2015 17:33:40 +0000 (11:33 -0600)]
glave: Fix createRenderpass replay restore of remapped FB

9 years agoWin/C11: Use _align_malloc() on Windows, align_alloc() elsewhere.
Ian Elliott [Fri, 6 Mar 2015 21:34:47 +0000 (14:34 -0700)]
Win/C11: Use _align_malloc() on Windows, align_alloc() elsewhere.

9 years agolayers: Improve PresentableImage memory handling in mem/objecttracker
Mark Lobodzinski [Thu, 5 Mar 2015 18:39:33 +0000 (12:39 -0600)]
layers: Improve PresentableImage memory handling in mem/objecttracker

Add handling to eliminate meaningless error reporting for the
xglWsiX11CreatePresentableImage memory resources.

9 years agoWin: Fix warnings for parameter of getLayerOptionEnum()
Ian Elliott [Fri, 6 Mar 2015 20:50:05 +0000 (13:50 -0700)]
Win: Fix warnings for parameter of getLayerOptionEnum()

9 years agoWin: Fix a compiler warning in "icd/common"
Ian Elliott [Fri, 6 Mar 2015 20:49:44 +0000 (13:49 -0700)]
Win: Fix a compiler warning in "icd/common"

9 years agoUpdate xgl_helper to handle all of the dynamic arrays
Tobin Ehlis [Fri, 6 Mar 2015 17:38:25 +0000 (10:38 -0700)]
Update xgl_helper to handle all of the dynamic arrays

9 years agoglave: Remove unnecessary dot dump.
Jeremy Hayes [Fri, 6 Mar 2015 19:58:13 +0000 (12:58 -0700)]
glave: Remove unnecessary dot dump.

9 years agoWin/glvdebug: Update the BUILD.md dependencies.
Ian Elliott [Fri, 6 Mar 2015 18:37:07 +0000 (11:37 -0700)]
Win/glvdebug: Update the BUILD.md dependencies.

Update the BUILD.md dependencies in order to build Glave debugger/GUI on
Windows.

9 years agonulldrv: build it on Linux
Chia-I Wu [Thu, 5 Mar 2015 21:22:56 +0000 (14:22 -0700)]
nulldrv: build it on Linux

It compiles!

9 years agonulldrv: fix gcc errors/warnings
Chia-I Wu [Thu, 5 Mar 2015 21:26:54 +0000 (14:26 -0700)]
nulldrv: fix gcc errors/warnings

The only functional change should be that _aligned_malloc() is replaced by
malloc().  It does not seem to matter.

9 years agoicd: remove stale function declarations
Chia-I Wu [Wed, 4 Mar 2015 18:19:59 +0000 (11:19 -0700)]
icd: remove stale function declarations

Remove declarations of

  icdDbgRegisterMsgCallback()
  icdDbgUnregisterMsgCallback()
  icdDbgSetGlobalOption()

9 years agoicd: remove unused icd-alloc.[ch]
Chia-I Wu [Sun, 22 Feb 2015 06:41:03 +0000 (14:41 +0800)]
icd: remove unused icd-alloc.[ch]

9 years agonulldrv: remove icd-alloc.h dependency
Chia-I Wu [Sun, 22 Feb 2015 06:40:25 +0000 (14:40 +0800)]
nulldrv: remove icd-alloc.h dependency

9 years agoicd: add support for per-instance DRM enumeration
Chia-I Wu [Fri, 20 Feb 2015 20:41:57 +0000 (13:41 -0700)]
icd: add support for per-instance DRM enumeration

Add icd_instance to DRM enumeration functions, and use it for memory
allocation or logging.

9 years agoicd: add generic icd_instance
Chia-I Wu [Sat, 21 Feb 2015 06:00:17 +0000 (14:00 +0800)]
icd: add generic icd_instance

It provides memory allocation and logging support.

9 years agoWin: Fix compilation errors.
Ian Elliott [Thu, 5 Mar 2015 19:28:53 +0000 (12:28 -0700)]
Win: Fix compilation errors.

9 years agolayers: Fix Windows build issue
Courtney Goeltzenleuchter [Wed, 4 Mar 2015 22:47:34 +0000 (15:47 -0700)]
layers: Fix Windows build issue

9 years agoobject-tracker: Do not track GPU object
Courtney Goeltzenleuchter [Wed, 4 Mar 2015 18:21:23 +0000 (11:21 -0700)]
object-tracker: Do not track GPU object

The GPU object is not something that is created by the app
and thus object tracker layer does not have to track it.

9 years agolayers: allocate enough space for pointer sprintf
Mike Stroyan [Tue, 3 Mar 2015 23:54:24 +0000 (16:54 -0700)]
layers: allocate enough space for pointer sprintf

9 years agomemTracker: Use local GetProcAddr rather than auto generated one
Jon Ashburn [Mon, 2 Mar 2015 23:51:38 +0000 (16:51 -0700)]
memTracker: Use local GetProcAddr rather than auto generated one

Clean up pass through  functions.  Generated GetProcAddr  requires drawState
to implement all entrypoints so don't use this generated GPA.

9 years agodrawState: Use local GetProcAddr rather than auto generated one
Jon Ashburn [Mon, 2 Mar 2015 18:32:24 +0000 (11:32 -0700)]
drawState: Use local GetProcAddr rather than auto generated one

Clean up pass through  functions.  Generated GetProcAddr  requires drawState
to implement all entrypoints so don't use this generated GPA.

9 years agolayers: if no settings file or call overrides make callback override loging
Jon Ashburn [Tue, 3 Mar 2015 22:07:15 +0000 (15:07 -0700)]
layers: if no settings file or call overrides make callback override loging

Default debugAction in layers is to log based on variable init. Make the
overrides work as follows:
1) app calls xglRegisterMsgCallback()
2) settings file
3) Glave (or app) calls to setlayerOption()

9 years agolayers: Correctly set last bound PSO in DrawState layer
Tobin Ehlis [Tue, 3 Mar 2015 20:58:42 +0000 (13:58 -0700)]
layers: Correctly set last bound PSO in DrawState layer

9 years agoWin: Cannot use the "dot" functionality yet on Windows.
Ian Elliott [Tue, 3 Mar 2015 16:50:57 +0000 (09:50 -0700)]
Win: Cannot use the "dot" functionality yet on Windows.

9 years agolayers: Made mem_tracker thread-safe
Mark Lobodzinski [Tue, 3 Mar 2015 02:23:52 +0000 (20:23 -0600)]
layers: Made mem_tracker thread-safe

Brought up to par with DrawState and ObjectTracker.

9 years agoTurn on ability to trace on Windows with NVIDIA driver.
Ian Elliott [Mon, 2 Mar 2015 21:05:18 +0000 (14:05 -0700)]
Turn on ability to trace on Windows with NVIDIA driver.

I can now trace the "tri" and "cube" demos.  Two changes were needed:

1) Must link the programs against XGL.dll instead of XGL.lib (the "XGL" library
   instead of "XGLstatic").

2) The glv_MessageStream_SetupHostSocket() function needed to "create" the
   lock/critical section that's used in the Glave interconnect code.

9 years agoAdd NOMINMAX and VC_EXTRALEAN to some windows files
Piers Daniell [Sun, 1 Mar 2015 16:32:56 +0000 (09:32 -0700)]
Add NOMINMAX and VC_EXTRALEAN to some windows files

This avoids these headers leaking conflicting Windows symbols to
non-Windows code.

9 years agoWin/glave: Remove new compiler warnings on Windows.
Ian Elliott [Fri, 27 Feb 2015 18:10:59 +0000 (11:10 -0700)]
Win/glave: Remove new compiler warnings on Windows.

Compiling the glvtrace_xgl64.dll library on Windows (see prior commit) resulted
in new warnings, some of which seemed serious (e.g. using "sizeof(void)", which
is 1 on Linux, with GCC, but is 0 on Windows).

9 years agoWin/glave: Compile/link the glvtrace_xgl64.dll library on Windows.
Ian Elliott [Fri, 27 Feb 2015 00:01:30 +0000 (17:01 -0700)]
Win/glave: Compile/link the glvtrace_xgl64.dll library on Windows.

9 years agoLinux: Must use "__linux__" instead of "PLATFORM_LINUX".
Ian Elliott [Thu, 26 Feb 2015 21:34:52 +0000 (14:34 -0700)]
Linux: Must use "__linux__" instead of "PLATFORM_LINUX".

There are some places (e.g. glave) where PLATFORM_LINUX is #define'd, but
normally we need to rely on "__linux__", which is #define'd by the compiler
(i.e. we can rely on it being there).

9 years agodemos/cube: use a single layout
Chia-I Wu [Mon, 23 Feb 2015 17:41:08 +0000 (10:41 -0700)]
demos/cube: use a single layout

Conflicts:
demos/cube.c

9 years agoGet the trace player to work with Windows
Piers Daniell [Tue, 24 Feb 2015 20:58:47 +0000 (13:58 -0700)]
Get the trace player to work with Windows

This change modifies many of the generators to use "#if
defined(PLATFORM_LINUX) || defined(XCB_NVIDIA)" to choose between using
XCB or WIN32 native.

9 years agoxcb: Deal with case of getenv() returning NULL.
Ian Elliott [Fri, 20 Feb 2015 21:12:18 +0000 (14:12 -0700)]
xcb: Deal with case of getenv() returning NULL.

At least on Windows, getenv() returns NULL when the environment variable is not
found.  This causes a problem inside of "xcb_nvidia.cpp" when a C++ std::string
is assigned the return value of getenv().

9 years agoModify xcb_nvidia/nulldrv to also support nulldrv.
Ian Elliott [Thu, 19 Feb 2015 21:26:19 +0000 (14:26 -0700)]
Modify xcb_nvidia/nulldrv to also support nulldrv.

This allows LunarG and others without the NVIDIA XGL driver to use the nulldrv
on Windows.

9 years agoUpdate tri and cube with stage
Piers Daniell [Mon, 23 Feb 2015 23:23:13 +0000 (16:23 -0700)]
Update tri and cube with stage

These changes were cherry-picked from nvidia-dev-20150218 and
KhronosGroup/GDC-stable.