Vulkan: Build a yarn::Scheduler and pass it down to the vk::Queue.

Nothing is actually scheduled, but is a first step towards using yarn.

As yarn is now actually used by SwiftShader, drop the BUILD_YARN build
flags, as failing to build yarn would result in linker errors.

Bug: b/139142453
Change-Id: Ibd9a69f72a248f58a62bb41eeb196c4647876e82
Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/35153
Tested-by: Ben Clayton <bclayton@google.com>
Reviewed-by: Chris Forbes <chrisforbes@google.com>
Reviewed-by: Nicolas Capens <nicolascapens@google.com>
Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
diff --git a/src/Vulkan/VkPipeline.cpp b/src/Vulkan/VkPipeline.cpp
index 31c0ebf..0efde4c 100644
--- a/src/Vulkan/VkPipeline.cpp
+++ b/src/Vulkan/VkPipeline.cpp
@@ -22,6 +22,8 @@
 #include "Pipeline/ComputeProgram.hpp"
 #include "Pipeline/SpirvShader.hpp"
 
+#include "Yarn/Trace.hpp"
+
 #include "spirv-tools/optimizer.hpp"
 
 #include <iostream>
@@ -257,6 +259,8 @@
 
 std::shared_ptr<sw::ComputeProgram> createProgram(const vk::PipelineCache::ComputeProgramKey& key)
 {
+	YARN_SCOPED_EVENT("createProgram");
+
 	vk::DescriptorSet::Bindings descriptorSets;  // FIXME(b/129523279): Delay code generation until invoke time.
 	// TODO(b/119409619): use allocator.
 	auto program = std::make_shared<sw::ComputeProgram>(key.getShader(), key.getLayout(), descriptorSets);