From 1124c3f1b629d3fa0d31dea8601aadd72a3339e0 Mon Sep 17 00:00:00 2001 From: Gert Wollny Date: Thu, 7 May 2020 00:01:11 +0200 Subject: [PATCH] r600/sfn: Don't reorder outputs by location This was wrong, if anything it should be sorted by device_location, and NIR usually provides this. Signed-off-by: Gert Wollny Reviewed-by: Reviewed-by: Dave Airlie Part-of: --- .../drivers/r600/sfn/sfn_shader_vertex.cpp | 1 - .../drivers/r600/sfn/sfn_vertexstageexport.cpp | 15 --------------- .../drivers/r600/sfn/sfn_vertexstageexport.h | 1 - 3 files changed, 17 deletions(-) diff --git a/src/gallium/drivers/r600/sfn/sfn_shader_vertex.cpp b/src/gallium/drivers/r600/sfn/sfn_shader_vertex.cpp index 2447a07d5c3..3c6e1f01dad 100644 --- a/src/gallium/drivers/r600/sfn/sfn_shader_vertex.cpp +++ b/src/gallium/drivers/r600/sfn/sfn_shader_vertex.cpp @@ -120,7 +120,6 @@ bool VertexShaderFromNir::do_allocate_reserved_registers() void VertexShaderFromNir::emit_shader_start() { - m_export_processor->setup_paramn_map(); } bool VertexShaderFromNir::scan_sysvalue_access(nir_instr *instr) diff --git a/src/gallium/drivers/r600/sfn/sfn_vertexstageexport.cpp b/src/gallium/drivers/r600/sfn/sfn_vertexstageexport.cpp index 061097359ba..bcaa5f405f6 100644 --- a/src/gallium/drivers/r600/sfn/sfn_vertexstageexport.cpp +++ b/src/gallium/drivers/r600/sfn/sfn_vertexstageexport.cpp @@ -33,21 +33,6 @@ VertexStageExportForFS::VertexStageExportForFS(VertexStage& proc, { } -void VertexStageExportBase::setup_paramn_map() -{ - priority_queue, std::greater> q; - for (auto a: m_param_map) { - q.push(a.first); - } - - int next_param = 0; - while (!q.empty()) { - int loc = q.top(); - q.pop(); - m_param_map[loc] = next_param++; - } -} - bool VertexStageExportBase::do_process_outputs(nir_variable *output) { if (output->data.location == VARYING_SLOT_COL0 || diff --git a/src/gallium/drivers/r600/sfn/sfn_vertexstageexport.h b/src/gallium/drivers/r600/sfn/sfn_vertexstageexport.h index a48f9d34153..3740a325f14 100644 --- a/src/gallium/drivers/r600/sfn/sfn_vertexstageexport.h +++ b/src/gallium/drivers/r600/sfn/sfn_vertexstageexport.h @@ -17,7 +17,6 @@ class VertexStageExportBase public: VertexStageExportBase(VertexStage& proc); virtual ~VertexStageExportBase(); - void setup_paramn_map(); virtual bool store_deref(const nir_variable *out_var, nir_intrinsic_instr* instr) = 0; virtual void finalize_exports() = 0; virtual bool do_process_outputs(nir_variable *output); -- 2.30.2